Changeset 278 for CMTpy/HEAD/python
- Timestamp:
- Oct 12, 2006, 4:01:03 PM (18 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
CMTpy/HEAD/python/cmt.py
r276 r278 4 4 5 5 Simple usage: 6 7 6 import CMT 8 7 9 if __name__ == '__main__': 10 unittest.main() 8 if __name__ == "__main__": 9 10 cmt = CMT() 11 12 package = 'CMTpy' 13 14 package_root = cmt.macro_value (package + '_root') 15 print package_root 16 17 if cmt.tag (package + '_with_installarea'): 18 print package + ' strategy is with installarea' 19 20 print "Macros: ", cmt.macros , '\n' 21 print "Tags: ", cmt.tags , '\n' 22 print "Sets: ", cmt.sets , '\n' 23 11 24 ''' 12 25 __author__ = "Vincent Garonne" 13 26 __email__ = "garonne at lal dot in2p3 dot fr" 14 __version__ = " 1"27 __version__ = "HEAD" 15 28 __all__ = ["CMT"] 16 29 … … 27 40 #---------------------------------------------------- 28 41 def execute (cmd): 29 30 42 """Executing a shell command 43 """ 31 44 #print '> ' + cmd 32 45 r, w, e = popen2.popen3(cmd) … … 165 178 166 179 if __name__ == "__main__": 167 main(module=None) 180 181 cmt = CMT() 182 183 package = 'CMTpy' 184 185 package_root = cmt.macro_value (package + '_root') 186 print package_root 187 188 if cmt.tag (package + '_with_installarea'): 189 print package + ' strategy is with installarea' 190 191 print "Macros: ", cmt.macros , '\n' 192 print "Tags: ", cmt.tags , '\n' 193 print "Sets: ", cmt.sets , '\n' 194 195 #--------------------------------- EoF --------------------------------------# 168 196 169 197
Note: See TracChangeset
for help on using the changeset viewer.