MCPcopy Index your code
hub / github.com/RetiredWizard/PyDOS / readBATFile

Function readBATFile

PyDOS.py:442–454  ·  view source on GitHub ↗
(BATfile)

Source from the content-addressed store, hash-verified

440 return condCmd
441
442 def readBATFile(BATfile):
443 batIndex = [0]
444 batLabels = {}
445 batLineNo = 0
446 for batLine in BATfile:
447 batIndex.append(batIndex[batLineNo]+len(batLine))
448 batLineNo += 1
449 if batLine.strip()[:1] == ":" and len(batLine.strip().split(" ")[0]) > 1:
450 batLabels[batLine.strip().split(" ")[0][1:]] = [batLineNo,batIndex[batLineNo]]
451 BATfile.seek(0)
452 del batIndex,batLineNo
453
454 return batLabels
455
456 batEcho = True
457 cmd = ""

Callers 1

PyDOSFunction · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected