What you are asking for cannot be triggered. The only triggers that are active during submit are change-submit , change-content and change-commit . You can only get the contents of the file for the last two, but with the change-content trigger the change-content list number has not yet been fixed, and with the change-commit trigger the contents of the file have already been completed and cannot be changed. However, the worse is that you did not have There would be a way to send the modified contents of the file back to the server from your trigger.
The RCS keyword extension works because it is executed by the server itself and because Perforce updates after sending, that is, the client updates all the transferred change files from the Perforce server, thereby receiving content with RCS extended keywords.
source share