jblocksom
08-08-2005, 12:59 PM
My build stores a project macro with the (multi line) output of a Perforce command and compares it with that same command the next time it is run. When I run the build from inside VBPro things work correctly, but when I run it from the command line the compare always returns that the macros are different -- even though they look exactly the same when I dump them to the output log.
I am saving the project, so that is not the problem. Does VBPro do anything like strip newlines or invisible characters?
Below is a copy of the log from two builds from within the IDE (sans my personal information).
--------------------Starting Build: 'p4_monitor'--------------------
Building project step 'Project steps'...
Building project step 'Perforce'...
Performing requested command...
Change 555 on 2005/08/05 by xxx@yyyy 'Adding some test data '
Building project step 'Set Macro'...
Created Temporary macro 'P4_LAST_CHANGE'
Building project step 'Log Message'...
*****
P4_LAST_CHANGE IS:
Performing requested command...
Change 555 on 2005/08/05 by xxx@yyyy 'Adding some test data '
===
P4_STORED_LAST_CHANGE IS:
Performing requested command...
Change 555 on 2005/08/05 by xxx@yyyy 'Adding some test data '
*****
P4_LAST_CHANGE in script:
Performing requested command...
Change 555 on 2005/08/05 by xxx@yyyy 'Adding some test data '
P4_STORED_LAST_CHANGE in script:
Performing requested command...
Change 555 on 2005/08/05 by xxx@yyyy 'Adding some test data '
Expression evaluates to:
-1
Building project step 'if last_change != stored_change'...
Building project step 'Set Macro'...
Updated Project macro 'P4_STORED_LAST_CHANGE'
Building project step 'Save file'...
Build successfully completed.
Registered to: ****
--------------------Starting Build: 'p4_monitor'--------------------
Building project step 'Project steps'...
Building project step 'Perforce'...
Performing requested command...
Change 555 on 2005/08/05 by xxx@yyyy 'Adding some test data '
Building project step 'Set Macro'...
Created Temporary macro 'P4_LAST_CHANGE'
Building project step 'Log Message'...
*****
P4_LAST_CHANGE IS:
Performing requested command...
Change 555 on 2005/08/05 by xxx@yyyy 'Adding some test data '
===
P4_STORED_LAST_CHANGE IS:
Performing requested command...
Change 555 on 2005/08/05 by xxx@yyyy 'Adding some test data '
*****
P4_LAST_CHANGE in script:
Performing requested command...
Change 555 on 2005/08/05 by xxx@yyyy 'Adding some test data '
P4_STORED_LAST_CHANGE in script:
Performing requested command...
Change 555 on 2005/08/05 by xxx@yyyy 'Adding some test data '
Expression evaluates to:
0
Building project step 'if last_change != stored_change'...
Step 'if last_change != stored_change' build rule evaluates false: [Trim(vbld_AllMacros()("P4_LAST_CHANGE").Value) <> Trim(vbld_AllMacros()("P4_STORED_LAST_CHANGE").Value)] is true
Step skipped
Building project step 'Set Macro'...
Step 'if last_change != stored_change' build rule evaluates false: [Trim(vbld_AllMacros()("P4_LAST_CHANGE").Value) <> Trim(vbld_AllMacros()("P4_STORED_LAST_CHANGE").Value)] is true
Step skipped
Building project step 'Save file'...
Step 'if last_change != stored_change' build rule evaluates false: [Trim(vbld_AllMacros()("P4_LAST_CHANGE").Value) <> Trim(vbld_AllMacros()("P4_STORED_LAST_CHANGE").Value)] is true
Step skipped
Build successfully completed.
I am saving the project, so that is not the problem. Does VBPro do anything like strip newlines or invisible characters?
Below is a copy of the log from two builds from within the IDE (sans my personal information).
--------------------Starting Build: 'p4_monitor'--------------------
Building project step 'Project steps'...
Building project step 'Perforce'...
Performing requested command...
Change 555 on 2005/08/05 by xxx@yyyy 'Adding some test data '
Building project step 'Set Macro'...
Created Temporary macro 'P4_LAST_CHANGE'
Building project step 'Log Message'...
*****
P4_LAST_CHANGE IS:
Performing requested command...
Change 555 on 2005/08/05 by xxx@yyyy 'Adding some test data '
===
P4_STORED_LAST_CHANGE IS:
Performing requested command...
Change 555 on 2005/08/05 by xxx@yyyy 'Adding some test data '
*****
P4_LAST_CHANGE in script:
Performing requested command...
Change 555 on 2005/08/05 by xxx@yyyy 'Adding some test data '
P4_STORED_LAST_CHANGE in script:
Performing requested command...
Change 555 on 2005/08/05 by xxx@yyyy 'Adding some test data '
Expression evaluates to:
-1
Building project step 'if last_change != stored_change'...
Building project step 'Set Macro'...
Updated Project macro 'P4_STORED_LAST_CHANGE'
Building project step 'Save file'...
Build successfully completed.
Registered to: ****
--------------------Starting Build: 'p4_monitor'--------------------
Building project step 'Project steps'...
Building project step 'Perforce'...
Performing requested command...
Change 555 on 2005/08/05 by xxx@yyyy 'Adding some test data '
Building project step 'Set Macro'...
Created Temporary macro 'P4_LAST_CHANGE'
Building project step 'Log Message'...
*****
P4_LAST_CHANGE IS:
Performing requested command...
Change 555 on 2005/08/05 by xxx@yyyy 'Adding some test data '
===
P4_STORED_LAST_CHANGE IS:
Performing requested command...
Change 555 on 2005/08/05 by xxx@yyyy 'Adding some test data '
*****
P4_LAST_CHANGE in script:
Performing requested command...
Change 555 on 2005/08/05 by xxx@yyyy 'Adding some test data '
P4_STORED_LAST_CHANGE in script:
Performing requested command...
Change 555 on 2005/08/05 by xxx@yyyy 'Adding some test data '
Expression evaluates to:
0
Building project step 'if last_change != stored_change'...
Step 'if last_change != stored_change' build rule evaluates false: [Trim(vbld_AllMacros()("P4_LAST_CHANGE").Value) <> Trim(vbld_AllMacros()("P4_STORED_LAST_CHANGE").Value)] is true
Step skipped
Building project step 'Set Macro'...
Step 'if last_change != stored_change' build rule evaluates false: [Trim(vbld_AllMacros()("P4_LAST_CHANGE").Value) <> Trim(vbld_AllMacros()("P4_STORED_LAST_CHANGE").Value)] is true
Step skipped
Building project step 'Save file'...
Step 'if last_change != stored_change' build rule evaluates false: [Trim(vbld_AllMacros()("P4_LAST_CHANGE").Value) <> Trim(vbld_AllMacros()("P4_STORED_LAST_CHANGE").Value)] is true
Step skipped
Build successfully completed.