[hibernate-commits] Hibernate SVN: r11746 - core/branches/Branch_3_2 and 1 other directory.

hibernate-commits at lists.jboss.org hibernate-commits at lists.jboss.org
Tue Jun 19 13:00:15 EDT 2007


Author: steve.ebersole at jboss.com
Date: 2007-06-19 13:00:15 -0400 (Tue, 19 Jun 2007)
New Revision: 11746

Added:
   core/branches/Branch_3_2/indent.py
Removed:
   branches/Branch_3_2/Hibernate3/indent.py
Log:
starting svn layout migration testing

Deleted: branches/Branch_3_2/Hibernate3/indent.py
===================================================================
--- branches/Branch_3_2/Hibernate3/indent.py	2007-06-19 17:00:08 UTC (rev 11745)
+++ branches/Branch_3_2/Hibernate3/indent.py	2007-06-19 17:00:15 UTC (rev 11746)
@@ -1,45 +0,0 @@
-import re
-import sys
-sys.argv.pop(0)
-for fname in sys.argv:
-	file = open(fname)
-	inlines = file.read().split('\n')
-	file.close()
-	out= []
-	tabcount = 0
-	extratab=0
-	for ln in inlines:
-		code = ln.lstrip('\t ').rstrip('\t ')
-		clen = len(code)
-		javadoc = clen > 0 and code[0]=='*'
-		if javadoc:
-			code = ' ' + code
-		else:
-			begincb = clen > 0 and ( code[0]=='}' or code[0]==')' )
-			tabcount -= begincb
-		
-		extratab = extratab or ( len(code)>0 and code[0]=='.' )
-		
-		tabs = '\t' * (tabcount + extratab)
-		
-		extratab = clen>0 and ( code[clen-1]==':' or code[clen-1]=='?' )
-		
-		if clen>5 and code[0:6] == '} else':
-			code = '}\n' + tabs + 'else' + code[6:]
-		if clen>6 and code[0:7] == '} catch':
-			code = '}\n' + tabs + 'catch' + code[7:]
-		
-		out.append( tabs + code + '\n' )
-		
-		if not javadoc:
-			uncommented = code.split('//')[0].rstrip()
-			clen = len(uncommented)
-			endob = clen > 0 and ( code[clen-1]=='{' or code[clen-1]=='(' )
-			tabcount += endob
-		
-	file = open( fname, 'w' )
-	for ln in out:
-		file.write(ln)
-	file.close()
-
-

Copied: core/branches/Branch_3_2/indent.py (from rev 11745, branches/Branch_3_2/Hibernate3/indent.py)
===================================================================
--- core/branches/Branch_3_2/indent.py	                        (rev 0)
+++ core/branches/Branch_3_2/indent.py	2007-06-19 17:00:15 UTC (rev 11746)
@@ -0,0 +1,45 @@
+import re
+import sys
+sys.argv.pop(0)
+for fname in sys.argv:
+	file = open(fname)
+	inlines = file.read().split('\n')
+	file.close()
+	out= []
+	tabcount = 0
+	extratab=0
+	for ln in inlines:
+		code = ln.lstrip('\t ').rstrip('\t ')
+		clen = len(code)
+		javadoc = clen > 0 and code[0]=='*'
+		if javadoc:
+			code = ' ' + code
+		else:
+			begincb = clen > 0 and ( code[0]=='}' or code[0]==')' )
+			tabcount -= begincb
+		
+		extratab = extratab or ( len(code)>0 and code[0]=='.' )
+		
+		tabs = '\t' * (tabcount + extratab)
+		
+		extratab = clen>0 and ( code[clen-1]==':' or code[clen-1]=='?' )
+		
+		if clen>5 and code[0:6] == '} else':
+			code = '}\n' + tabs + 'else' + code[6:]
+		if clen>6 and code[0:7] == '} catch':
+			code = '}\n' + tabs + 'catch' + code[7:]
+		
+		out.append( tabs + code + '\n' )
+		
+		if not javadoc:
+			uncommented = code.split('//')[0].rstrip()
+			clen = len(uncommented)
+			endob = clen > 0 and ( code[clen-1]=='{' or code[clen-1]=='(' )
+			tabcount += endob
+		
+	file = open( fname, 'w' )
+	for ln in out:
+		file.write(ln)
+	file.close()
+
+




More information about the hibernate-commits mailing list