[uim-commit] r781 - trunk/tools

yamaken at freedesktop.org yamaken at freedesktop.org
Wed Mar 9 08:06:17 PST 2005


Author: yamaken
Date: 2005-03-09 08:06:14 -0800 (Wed, 09 Mar 2005)
New Revision: 781

Added:
   trunk/tools/trim-src.sh
Log:
* tools/trim-src.sh
  - New file


Added: trunk/tools/trim-src.sh
===================================================================
--- trunk/tools/trim-src.sh	2005-03-09 14:52:03 UTC (rev 780)
+++ trunk/tools/trim-src.sh	2005-03-09 16:06:14 UTC (rev 781)
@@ -0,0 +1,7 @@
+#!/bin/sh
+
+SUBDIRS='uim helper gtk xim examples'
+
+for subdir in $SUBDIRS; do
+    find $subdir \( -name '*.c' -or -name '*.h' -or -name '*.cpp' \) -exec perl -i -pe 's/\b(if|else|do|while|for|switch)\s*([{\(])/\1 \2/g; s/\)(|\s{2,}){/) {/g; s/(})\s*(if|else)/\1 \2/g' {} \;
+done


Property changes on: trunk/tools/trim-src.sh
___________________________________________________________________
Name: svn:executable
   + *



More information about the Uim-commit mailing list