Permalink
Browse files

genmf.py: print dots instead of "Regenerating n of m" as progress ind…

…icator.

The reason is a bit selfish: when I build AROS or a subtarget from
the editor Scite I don't want in the output pan to have hundreds of
lines with the text "Regenerating ...".


git-svn-id: https://svn.aros.org/svn/aros/trunk/AROS@54924 fb15a70f-31f2-0310-bbcc-cdcc74a49acc
  • Loading branch information...
mazze
mazze committed Sep 6, 2017
1 parent 52e25c7 commit 3265eb6bdaaee1f7a8acaf82e9eac628f77dcafa
Showing with 8 additions and 2 deletions.
  1. +8 −2 tools/genmf/genmf.py
View
@@ -330,6 +330,7 @@ def read_templates(filename):
argv = []
i = 0
listfile = None
progcount = 0
while i < len(sys.argv):
if sys.argv[i] == "--listfile":
listfile = sys.argv[i+1]
@@ -381,14 +382,19 @@ def read_templates(filename):
infile = open(listfile, "r")
filelist = infile.readlines()
infile.close()
sys.stderr.write('Regenerating %d files\n' % (len(filelist)))
for fileno in range(len(filelist)):
files = filelist[fileno].split()
if len(files) <> 2:
sys.exit('%s:%d: Syntax error: %s' % (listfile, fileno+1, filelist[fileno]))
sys.stderr.write('Regenerating file %4d of %4d\r' % (fileno+1, len(filelist)))
sys.stderr.flush()
progcount = progcount + 1
if progcount == 20:
progcount = 0
sys.stderr.write('.')
sys.stderr.flush()
infile = open(files[0], "r")
lines = infile.readlines()

0 comments on commit 3265eb6

Please sign in to comment.