Main Page
Namespaces
Classes
Files
File List
File Members
src
lib
doil
utils
omniidl_be
tests
unitTest
remake_servants.py
Go to the documentation of this file.
1
#!/usr/bin/env python
2
3
import
sys
4
import
os
5
6
def
destroy_and_make
(dirname):
7
print
"remake : dirname : "
, dirname
8
9
try
:
10
# os.rmdir(os.path.abspath(dirname))
11
os.rename(dirname, dirname +
'_'
)
12
except
:
13
print
"Directory \""
+ dirname +
"\" not found."
14
15
16
try
:
17
os.system(
"./setuptest.py "
+ dirname +
" "
)
18
except
:
19
print
"Directory \""
+ dirname +
"\" already exists."
20
21
22
23
24
dirname = sys.argv[1]
25
#print os.path.abspath(dirname)
26
27
if
dirname !=
'all'
:
28
print
"Usage : "
+ sys.argv[0] +
" all"
;
29
exit(1)
30
31
for
pwd, dirs, files
in
os.walk(
'.'
):
32
# print "dirs : ", dirs
33
break
34
35
for
d
in
dirs:
36
if
d.rfind(
"Servant"
) > 0:
37
print
d, d.rfind(
"Servant"
)
38
destroy_and_make
(d)
39
40
41
#destroy_and_make(dirname)
42
43
exit(0)
44
remake_servants.destroy_and_make
def destroy_and_make(dirname)
Definition:
remake_servants.py:6
openrtm_aist
Author(s): Noriaki Ando
autogenerated on Mon Jun 10 2019 14:07:54