Revision 239

trunk/cleanup.sh (revision 239)
1
#!/bin/bash
2
INPUTDIR=$1
3
OUTPUTDIR=$1-rev
4
mkdir -p $OUTPUTDIR
5
for path in $INPUTDIR/*.cpp
6
do
7
# echo $path
8
# echo "Basename of $path = `basename $path`"
9
# echo "Dirname of $path = `dirname $path`"
10
  file=`basename $path`
11
  echo $file
12
  sed -f cleanup.sed  $path > $OUTPUTDIR/$file
13
# echo $path "->"$OUTPUTDIR/$file
14
done
15

  
trunk/cleanup.sed (revision 239)
1
# remove unwanted svn property fields and reformat comment block
2
# delete lines containing HOME_VERSION
3
1s/\*\*/*/
4
/^  \*$/d
5
/^  \* \$Rev/d
6
/^  \* \$Author/d
7
/^  \* \$Date/d
8
s/^  \* \$Id/ \* \$Id/
9
s/^  \* Author/ \* Author/
10
s/^  \* Copyright/ \* Copyright/
11
s/^  \*\// \*\//
12
/HOME_VERSION/d
13
# we should consider keeping this file as a record of what was done
14
# old changes could be commented out and new ones added
trunk/getVersionInfo.sh (revision 239)
1
#!/bin/bash
2
# see the Doxygen user manual
3
# svn stat -v $1 | sed -n 's/ˆ[ A-Z?\*|!]\{1,15\}/r/;s/ \{1,15\}/\/r/;s/ .*//p' 
4
# invoking as getVersionInfo.sh linad99/fvar.hpp prepends 9.0 to the revision
5
# for fvar.hpp
6
svn stat -v $1 | sed -n 's/ˆ[ A-Z?\*|!]\{1,15\}/r/;s/ \{1,15\}/9.0./;s/ .*//p' 
trunk/vimsyntax.sh (revision 239)
1
#!/usr/bin/gawk -f
2
BEGIN {
3
  FS="[> <]"
4
  tplSection = "syn keyword tplSection"
5
  tplSection = tplSection" LOCAL_CALCS END_CALCS"
6
  dataType = ""
7
  paramType = ""
8
  tplType = ""
9
  VIM = "tpl.vim"
10

  
11
  print "\" ADModel Builder extentions to C++ context highlighting" > VIM
12
  print "\" created by vimsyntax.sh from "ARGV[1] >> VIM
13
  print "\"" >> VIM
14
  print "\" ----------------------------------------------------------------------------" >> VIM
15
  print "\" THE BEER-WARE LICENSE (Unknown Revision) http://en.wikipedia.org/wiki/Beerware:" >> VIM
16
  print "\" sibert@hawaii.edu wrote this file. As long as you retain this notice you" >> VIM
17
  print "\" can do whatever you want with this stuff. If you think this code as been" >> VIM
18
  print "\" useful in some way you send me a virtual beer. Better yet, please and consider" >> VIM
19
  print "\" making a contribution to admb-foundation.org." >> VIM
20
  print "\" Copyright (c) ADMB Foundation." >> VIM
21
  print "\" ----------------------------------------------------------------------------" >> VIM
22
  print "\"" >> VIM
23
  print "\" Import the C++ syntax to start with" >> VIM
24
  print "if version < 600" >> VIM
25
  print "  so <sfile>:p:h/c++.vim" >> VIM
26
  print "else" >> VIM
27
  print "  runtime! syntax/cpp.vim" >> VIM
28
  print "  unlet b:current_syntax" >> VIM
29
  print "end" >> VIM
30
  print "\"" >> VIM
31
}
32

  
33
{
34
  if ($1 != "s")
35
  {
36
    if ($2 == "DEFINE_DATA" && $3 != "^[")
37
    {
38
      dataType = dataType " " $3
39
    }
40
    else if ($2 == "DEFINE_PARAMETERS" && $3 != "^[")
41
    {
42
      paramType = paramType " " $3
43
    }
44
    else if (match($1, "^[A-Z].*_SECTION") > 0)
45
    {
46
       tplSection = tplSection " " $1
... This diff was truncated because it exceeds the maximum size that can be displayed.

Also available in: Unified diff