/usr/lib/auto-07p/cmds/@dlb is in auto-07p 0.9.1+dfsg-1.
This file is owned by root:root, with mode 0o755.
The actual contents of the file can be viewed below.
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 | #! /usr/bin/python
import sys
import os
sys.path.append(os.path.join(os.environ["AUTO_DIR"],"python"))
from AUTOclui import *
import parseBandS
# This is the Python syntax for making a script runable
if __name__ == '__main__':
if len(sys.argv) > 1:
code=sys.argv[1]
if code[0] == '-':
codes=[code[1:3].upper()]
n=1
else:
codes=None
n=0
if len(sys.argv) == n+3:
changedb='b.'+sys.argv[n+2]
changeds='s.'+sys.argv[n+2]
bs=bt(sys.argv[n+1])
else:
if len(sys.argv) == n+2:
changedb='b.'+sys.argv[n+1]
changeds='s.'+sys.argv[n+1]
else:
changedb='fort.7'
changeds='fort.8'
origb=changedb+'~'
origs=changeds+'~'
try:
os.remove(origb)
except:
pass
try:
os.remove(origs)
except:
pass
os.rename(changedb,origb)
os.rename(changeds,origs)
if len(sys.argv) == n+2:
bs=bt(sys.argv[n+1]+'~')
else:
bs=parseBandS.parseBandS('fort.7~','fort.8~')
bs.deleteLabel(codes,keepTY=1)
bs.writeFilename(changedb,changeds)
print(" @dlb: Rewriting finished.")
|