Exuberant ctags adds data at the beginning of the tags file. It also sorts
the tags file by default. This means, if we sort the file generated by
Exuberant ctags, it doesn't work in VIM and possibly other editors.

I didn't notice this until recently because I was using my own script. Its
possible that this only affects recent version of Exuberant ctags though I
tested a version from 2001 which exhibited the same behaviour.

Gavin
Index: src/tools/make_ctags
===================================================================
RCS file: /usr/local/cvsroot/pgsql-server/src/tools/make_ctags,v
retrieving revision 1.9
diff -2 -c -r1.9 make_ctags
*** src/tools/make_ctags        2 Feb 2004 17:29:32 -0000       1.9
--- src/tools/make_ctags        23 Jun 2004 08:25:01 -0000
***************
*** 3,9 ****
  rm -f ./tags
  
! if ctags --version 2>&1 | grep Exuberant >/dev/null
! then  FLAGS="--c-types=+dfmstuv"
! else  FLAGS="-dt"
  fi
  
--- 3,11 ----
  rm -f ./tags
  
! cv=`ctags --version 2>&1 | grep Exuberant`
! 
! if [ -z "$cv" ]
! then  FLAGS="-dt"
! else  FLAGS="--c-types=+dfmstuv"
  fi
  
***************
*** 11,17 ****
        -type f -name '*.[chyl]' -print|xargs ctags "$FLAGS" -a -f tags
  
! LC_ALL=C
! export LC_ALL
! sort tags >/tmp/$$ && mv /tmp/$$ tags
  
  find . -name  'CVS' -prune -o -type d -print  |while read DIR
--- 13,22 ----
        -type f -name '*.[chyl]' -print|xargs ctags "$FLAGS" -a -f tags
  
! if [ -z "$cv" ]
! then
!       LC_ALL=C
!       export LC_ALL
!       sort tags >/tmp/$$ && mv /tmp/$$ tags
! fi
  
  find . -name  'CVS' -prune -o -type d -print  |while read DIR
---------------------------(end of broadcast)---------------------------
TIP 1: subscribe and unsubscribe commands go to [EMAIL PROTECTED]

Reply via email to