ɾ³ý¹¤³ÌÖÐsvnÎļþµÄ½Å±¾(Ruby°æºÍPython°æ)
Á½ÖÖ²»Í¬µÄÓïÑÔ,²»Í¬µÄ±í´ï!
Python½Å±¾ÊµÏÖ.
""
"
File Name : clean.py
File Date : 2009/11/5 14:22:56
Author : DannyLai
Purpose : Clean the svn files
All svn projects have an hide directory "
.
svn"
The python script purpose is to clean the .svn directory in svn projects.
"
""
import
os
import
stat
SVNPROJECT_DIR =
"F:\\temp\\google-gdata"
def
findSVNDir(
path )
:
for
file in
os.
listdir(
path )
:
subpath =
os.
path.
join(
path,
file )
if
os.
path.
isdir(
subpath )
:
if
file =
=
".svn"
:
print
subpath
deleteSVNDir(
subpath )
else
:
findSVNDir(
subpath )
def
deleteSVNDir(
path )
:
for
file in
os.
listdir(
path )
:
subpath =
os.
path.
join(
path,
file )
if
os.
path.
isdir(
subpath
Ïà¹ØÎĵµ£º
Ctrl+3 ÐÐ×¢ÊÍ
Ctr+\ È¥ÐÐ×¢ÊÍ
Ctrl+Shift+3 È¥ÐÐ×¢ÊÍ
Ctrl+4 ¿é×¢ÊÍ
Ctrl+5 & ......
ipython Èç¹ûûÓÐÓÃ×°, ÄǾ͸Ͻô×°ÉÏ, Õâ¸ö¶«Î÷±ÈÆðpython×Ô¼º´øµÄÄǸö½»»¥½çÃæÒªºÃÓúܶà
shutil ÀàËÆÓÚshellµÄһЩ½Ó¿Ú, ±ÈÈç cp, mvµÈµÈ
subprocess µ÷ÓÃ×Ó½ø³Ì
optparse ½âÎöÃüÁîÐвÎÊýµÄ, ÓÃËüÀ´Ó¦¸¶ÃüÁîÐвÎÊý, ¼ò½à, ÇåÎú
sqlite3 Êý¾Ý¿â, ½ø³Ì¼¶µÄÊý¾Ý¿â, ºÜ¿á, ÉõÖÁ¿ÉÒÔ°ÑÕâ¸öÊý¾Ý¿â½¨ÔÚÄÚ´æÀï. http://www.py ......
def delVss(path)
if File.directory?(path)
for f in d = Dir.open(path)
fpath = File.join(path, f)
if(f!="."&&f!="..")
......
http://code.google.com/p/android-scripting/
Android¿ªÊ¼Ö§³Ö½Å±¾ÓïÑÔPython¡¢Lua¼°Beanshell£¬Î´À´»¹½«Ö§³ÖRuby
×÷Õß Werner Schuster ÒëÕß ÕÅÁú ·¢²¼ÓÚ 2009Äê7ÔÂ5ÈÕ
Android Scripting Environment£¨ASE£©ÏîĿΪAndroidÔö¼ÓÁ˽ű¾Ö§³Ö¡£Í¨¹ý°²×°ASE£¬ÎÒÃÇ¿ÉÒÔÔÚÉ豸Éϱàд½Å±¾²¢Ö´ÐС£
ËäÈ»ÏÖÔÚÒѾӿÏÖ³öÁ ......
¹ØÓÚ¿ò¼Ü£¬Ö®Ç°ÌýµÃ±È½Ï¶à£¬ÌرðÊÇÔÚCPyGµÄÓʼþÁбíÉÏ£¬²»¹ý»¹Ã»ÓнӴ¥¹ý¡£
ÕâÒ»ÕÂÎÒ´òËãÂÔ¶Á£¬¼ÓÉÏÕâÁ½ÌìÉíÌå²»ÊÊ£¬¶ÁµÃ¸ü¼ÓÂÔÁË¡£
ÕâÒ»ÕÂÌáµ½µÄ¼¸¸ö¿ò¼ÜÎÒÌý˵µÄÓÐTKinterºÍSWIG¡£SWIG¸ãÁËһϣ¬TKinter¿´È˼ÒÓùý£¬×Ô¼º»¹Ã»ÓÐÓùý¡£¶ÔÕâЩ¿ò¼ÜÄ°ÉúµÃºÜ¡£ÒÔºóÅöÉÏÒªÓÃÁËÔÙÈÏÕæѧѧ¡£
µ½ÏÖÔÚ£¬¶ÔPythonËãÊÇÓÐЩÁ˽âÁË¡£ ......