From def056f30fca3d1a43d757cd5d57be1b1a705192 Mon Sep 17 00:00:00 2001 From: Philip Eisenlohr Date: Thu, 18 Aug 2011 08:00:19 +0000 Subject: [PATCH] added $Id$ escaping --- processing/post/3Dvisualize | 5 +++-- processing/post/addCauchy | 6 +++--- processing/post/addDeterminant | 6 +++--- processing/post/addDivergence | 6 +++--- processing/post/addMises | 6 +++--- processing/post/addNorm | 6 +++--- processing/post/addStrainTensors | 6 +++--- processing/post/averageDown | 6 +++--- processing/post/postResults | 4 ++-- processing/post/spectral_convergence | 2 +- 10 files changed, 27 insertions(+), 26 deletions(-) diff --git a/processing/post/3Dvisualize b/processing/post/3Dvisualize index 3b98709b3..576a7047a 100755 --- a/processing/post/3Dvisualize +++ b/processing/post/3Dvisualize @@ -284,8 +284,9 @@ def vtk_writeASCII_box(diag,defgrad): parser = OptionParser(option_class=extendedOption, usage='%prog [options] datafile[s]', description = """ Produce VTK file from data field. Coordinates are taken from (consecutive) ip.x, ip.y, and ip.z columns. -$Id$ -""") +""" + string.replace('$Id$','\n','\\n') +) + parser.add_option('-s', '--scalar', action='extend', dest='scalar', type='string', \ help='list of scalars to visualize') parser.add_option('-d', '--deformation', dest='defgrad', type='string', \ diff --git a/processing/post/addCauchy b/processing/post/addCauchy index 8c58c9bce..cf857a689 100755 --- a/processing/post/addCauchy +++ b/processing/post/addCauchy @@ -38,8 +38,8 @@ parser = OptionParser(option_class=extendableOption, usage='%prog options [file[ Add column(s) containing Cauchy stress based on given column(s) of deformation gradient and first Piola--Kirchhoff stress. -$Id: addCauchy 263 2011-05-25 17:42:50Z MPIE\p.eisenlohr $ -""") +""" + string.replace('$Id$','\n','\\n') +) parser.add_option('-m','--memory', dest='memory', action='store_true', \ @@ -129,7 +129,7 @@ for file in files: output = '%i\theader'%(headerlines+1) + '\n' + \ ''.join(passOn) + \ - string.replace('$Id: addCauchy 263 2011-05-25 17:42:50Z MPIE\p.eisenlohr $','\n','\\n')+ '\t' + \ + string.replace('$Id$','\n','\\n')+ '\t' + \ ' '.join(sys.argv[1:]) + '\n' + \ '\t'.join(headers + head) + '\n' # build extended header diff --git a/processing/post/addDeterminant b/processing/post/addDeterminant index 879d7ae0f..589f299bd 100755 --- a/processing/post/addDeterminant +++ b/processing/post/addDeterminant @@ -40,8 +40,8 @@ def determinant(m): parser = OptionParser(option_class=extendableOption, usage='%prog options [file[s]]', description = """ Add column(s) containing determinant of requested tensor column(s). -$Id: addDeterminant 278 2011-06-15 17:57:42Z MPIE\p.eisenlohr $ -""") +""" + string.replace('$Id$','\n','\\n') +) parser.add_option('-m','--memory', dest='memory', action='store_true', \ @@ -130,7 +130,7 @@ for file in files: output = '%i\theader'%(headerlines+1) + '\n' + \ ''.join(passOn) + \ - string.replace('$Id: addDeterminant 278 2011-06-15 17:57:42Z MPIE\p.eisenlohr $','\n','\\n')+ '\t' + \ + string.replace('$Id$','\n','\\n')+ '\t' + \ ' '.join(sys.argv[1:]) + '\n' + \ '\t'.join(headers + head) + '\n' # build extended header diff --git a/processing/post/addDivergence b/processing/post/addDivergence index 9d92e5499..bff36b615 100755 --- a/processing/post/addDivergence +++ b/processing/post/addDivergence @@ -56,8 +56,8 @@ Add column(s) containing divergence of requested column(s). Operates on periodic ordered three-dimensional data sets. Deals with both vector- and tensor-valued fields. -$Id: addDivergence 264 2011-05-25 17:43:45Z MPIE\p.eisenlohr $ -""") +""" + string.replace('$Id$','\n','\\n') +) parser.add_option('-a','--accuracy', dest='accuracy', type='int', \ @@ -158,7 +158,7 @@ for file in files: output = '%i\theader'%(headerlines+1) + '\n' + \ ''.join(passOn) + \ - string.replace('$Id: addDivergence 264 2011-05-25 17:43:45Z MPIE\p.eisenlohr $','\n','\\n')+ '\t' + \ + string.replace('$Id$','\n','\\n')+ '\t' + \ ' '.join(sys.argv[1:]) + '\n' + \ '\t'.join(headers + head) + '\n' # build extended header diff --git a/processing/post/addMises b/processing/post/addMises index 9be050213..50532595e 100755 --- a/processing/post/addMises +++ b/processing/post/addMises @@ -41,8 +41,8 @@ def Mises(what,tensor): parser = OptionParser(option_class=extendableOption, usage='%prog options [file[s]]', description = """ Add vonMises equivalent values for symmetric part of requested strains and/or stresses. -$Id: addMises 263 2011-05-25 17:42:50Z MPIE\p.eisenlohr $ -""") +""" + string.replace('$Id$','\n','\\n') +) parser.add_option('-m','--memory', dest='memory', action='store_true', \ @@ -132,7 +132,7 @@ for file in files: output = '%i\theader'%(headerlines+1) + '\n' + \ ''.join(passOn) + \ - string.replace('$Id: addMises 263 2011-05-25 17:42:50Z MPIE\p.eisenlohr $','\n','\\n')+ '\t' + \ + string.replace('$Id$','\n','\\n')+ '\t' + \ ' '.join(sys.argv[1:]) + '\n' + \ '\t'.join(headers + head) + '\n' # build extended header diff --git a/processing/post/addNorm b/processing/post/addNorm index 324f9918e..4183612c3 100755 --- a/processing/post/addNorm +++ b/processing/post/addNorm @@ -35,8 +35,8 @@ def L2(object): parser = OptionParser(option_class=extendableOption, usage='%prog options [file[s]]', description = """ Add column(s) containing norm of requested column(s) being either vectors or tensors. -$Id: addNorm 263 2011-05-25 17:42:50Z MPIE\p.eisenlohr $ -""") +""" + string.replace('$Id$','\n','\\n') +) parser.add_option('-m','--memory', dest='memory', action='store_true', \ @@ -126,7 +126,7 @@ for file in files: output = '%i\theader'%(headerlines+1) + '\n' + \ ''.join(passOn) + \ - string.replace('$Id: addNorm 263 2011-05-25 17:42:50Z MPIE\p.eisenlohr $','\n','\\n')+ '\t' + \ + string.replace('$Id$','\n','\\n')+ '\t' + \ ' '.join(sys.argv[1:]) + '\n' + \ '\t'.join(headers + head) + '\n' # build extended header diff --git a/processing/post/addStrainTensors b/processing/post/addStrainTensors index 5c96e91a9..7e96a2179 100755 --- a/processing/post/addStrainTensors +++ b/processing/post/addStrainTensors @@ -43,8 +43,8 @@ def prefixMultiply(what,len): parser = OptionParser(option_class=extendableOption, usage='%prog options [file[s]]', description = """ Add column(s) containing given strains based on given stretches of requested deformation gradient column(s). -$Id: addStrainTensors 274 2011-06-14 12:59:39Z MPIE\o.guevenc $ -""") +""" + string.replace('$Id$','\n','\\n') +) parser.add_option('-m','--memory', dest='memory', action='store_true', \ @@ -152,7 +152,7 @@ for file in files: output = '%i\theader'%(headerlines+1) + '\n' + \ ''.join(passOn) + \ - string.replace('$Id: addStrainTensors 274 2011-06-14 12:59:39Z MPIE\o.guevenc $','\n','\\n')+ '\t' + \ + string.replace('$Id$','\n','\\n')+ '\t' + \ ' '.join(sys.argv[1:]) + '\n' + \ '\t'.join(headers + head) + '\n' # build extended header diff --git a/processing/post/averageDown b/processing/post/averageDown index 836fd1b98..3b1f1f88b 100755 --- a/processing/post/averageDown +++ b/processing/post/averageDown @@ -44,8 +44,8 @@ parser = OptionParser(option_class=extendableOption, usage='%prog [options] [fil Average each data block of size 'packing' into single values thus reducing the former resolution to resolution/packing. (Requires numpy.) -$Id: averageDown 266 2011-05-29 19:38:42Z MPIE\p.eisenlohr $ -""") +""" + string.replace('$Id$','\n','\\n') +) parser.add_option('-m','--memory', dest='memory', action='store_true', \ @@ -105,7 +105,7 @@ for file in files: output = '%i\theader'%(headerlines+1) + '\n' + \ ''.join(passOn) + \ - string.replace('$Id: averageDown 266 2011-05-29 19:38:42Z MPIE\p.eisenlohr $','\n','\\n')+ '\t' + \ + string.replace('$Id$','\n','\\n')+ '\t' + \ ' '.join(sys.argv[1:]) + '\n' + \ '\t'.join(headers) + '\n' # build extended header diff --git a/processing/post/postResults b/processing/post/postResults index fb768acb0..c6e04d5a6 100755 --- a/processing/post/postResults +++ b/processing/post/postResults @@ -614,8 +614,8 @@ User mappings need to be formulated in an incremental fashion for each new data and may use the current (incremental) result, b(ase), as well as the number, n(umber), of already processed data points for evaluation. -$Id$ -""") +""" + string.replace('$Id$','\n','\\n') +) parser.add_option('-i','--info', action='store_true', dest='info', \ help='list contents of resultfile [%default]') diff --git a/processing/post/spectral_convergence b/processing/post/spectral_convergence index 8d3c128e3..0cbe1e279 100755 --- a/processing/post/spectral_convergence +++ b/processing/post/spectral_convergence @@ -29,7 +29,7 @@ class extendedOption(Option): parser = OptionParser(option_class=extendedOption, usage='%prog [options] spectralOut[s]', description = """ Generate datafile of converged iteration per increment. -""" + string.replace('$Id: spectral_iterationCount 919 2011-06-15 18:14:05Z MPIE\p.eisenlohr $','\n','\\n') +""" + string.replace('$Id$','\n','\\n') ) parser.add_option('-m','--memory', dest='memory', action='store_true', \