Fixup the ./pants script by grabbing just the md5 value

Review Request #113 — Created March 18, 2014 and submitted

jsirois
commons
251
pants-reviews
patricklaw, travis
Discovered ./pants not properly re-using its cache on my linux box.  I suspect this behavior must occur on OSX too - openssl md5 should have uniform behavior here.

commit 5ceea665c9e0a013a618eea31bb88bee45d0e1a6
Author: John Sirois <jsirois@twitter.com>
Date:   Fri Mar 14 13:12:29 2014 -0600

    Fixup the ./pants script by grabbing just the md5 value

 build-support/python/libvirtualenv.sh | 2 +-
 build-support/virtualenv              | 2 +-
 2 files changed, 2 insertions(+), 2 deletions(-)
Before - `./pants` would bootsrap every time it was used.  After the fix only the 1st call below bootstraps:
$ rm -rf build-support/pants.venv/
$ ./pants
$ ./pants
  • 0
  • 0
  • 0
  • 1
  • 1
Description From Last Updated
TR
  1. 
      
  2. build-support/python/libvirtualenv.sh (Diff revision 1)
     
     
    This is what I see:
    
    hoth:~ travis$ echo foo | openssl md5
    d3b07384d113edec49eaa6238ad5ff00
    hoth:~ travis$ openssl version
    OpenSSL 0.9.8y 5 Feb 2013
    
    I did this to work around the md5/md5sum command name issue on OSX/Linux. This approach works too; thx for the fix.
    
    hoth:science travis$ echo foo | openssl md5 | cut -d' ' -f2
    d3b07384d113edec49eaa6238ad5ff00
    
    1. Ok - thanks for testing.
      
      Yeah - my openssl is quite a bit newer but I repro on nest1 which has a closer version to yours:
      jsirois@gill ~ $ ssh nest1 'openssl version && echo foo | openssl md5'
      OpenSSL 0.9.8e-fips-rhel5 01 Jul 2008
      d3b07384d113edec49eaa6238ad5ff00
      jsirois@gill ~ $ openssl version && echo foo | openssl md5
      OpenSSL 1.0.1e 11 Feb 2013
      (stdin)= d3b07384d113edec49eaa6238ad5ff00
      
  3. 
      
PA
  1. Ship It!
  2. 
      
JS
  1. Thanks folks - merged.
  2. 
      
JS
JS
Review request changed

Status: Closed (submitted)

Loading...