[p4] Submitting files from change list with different descriptions

p4rfong perforce-user-forum at forums.perforce.com
Thu Mar 2 14:10:01 PST 2017

Posted on behalf of forum user 'p4rfong'.

Try using a form-out trigger.  When you run "p4 reconcile",
the changelist description will be changed.  Here's a sample
script that changes the description:
#     changedesc form-out change
"/home/rfong/perforce/changedesc.sh %formfile%"
FOUNDDEPOT=`cat $1 | grep "\/\/depot" | wc -l`
if [ $FOUNDDEPOT -gt 0 ]; then
    echo Found `cat $1 | grep "\/\/depot"`
    cat $1 | /bin/sed -e
"s/Description:/Description:  This is a special depot./"
> /tmp/hello.txt
    cat $1 | /bin/sed -e
"s/Description:/Description:  This is a regular depot./"
> /tmp/hello.txt
cp /tmp/hello.txt $1 >> /tmp/hello.txt 2>&1
#rm /tmp/hello.txt

Please click here to see the post in its original format:

More information about the perforce-user mailing list