Welcome to mirror list, hosted at ThFree Co, Russian Federation.

git.blender.org/blender.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorNathan Letwory <nathan@letworyinteractive.com>2010-01-14 16:42:15 +0300
committerNathan Letwory <nathan@letworyinteractive.com>2010-01-14 16:42:15 +0300
commit6a0a5b54ec2525c05d43cb56346b5577f16287df (patch)
tree8347bd75ab4b376200ebebfa02183e910fca3989 /tools/Blender.py
parent97dc31c8d3ed634e19437a7bddbf471fafdcdfc9 (diff)
Little fun feature for SCons users: set BF_LINE_OVERWRITE=True in your user-config.py or on command-line when BF_QUIET=True. This will reuse the same line of the previous compile message (Compiling ==>...). Warnings and other messages will still go on their own lines. Remember to set BF_LINE_OVERWRITE=False when you are redirecting the build output to a file
Diffstat (limited to 'tools/Blender.py')
-rw-r--r--tools/Blender.py8
1 files changed, 8 insertions, 0 deletions
diff --git a/tools/Blender.py b/tools/Blender.py
index 4dad70bbef5..c51c1367f33 100644
--- a/tools/Blender.py
+++ b/tools/Blender.py
@@ -268,6 +268,12 @@ def buildinfo(lenv, build_type):
##### ACTION STUFF #############
+def my_print_cmd_line(self, s, target, source, env):
+ sys.stdout.write(' ' * 70 + '\r')
+ sys.stdout.flush()
+ sys.stdout.write(s + "\r")
+ sys.stdout.flush()
+
def my_compile_print(target, source, env):
a = '%s' % (source[0])
d, f = os.path.split(a)
@@ -330,6 +336,8 @@ def set_quiet_output(env):
env['BUILDERS']['StaticLibrary'] = static_lib
env['BUILDERS']['Library'] = static_lib
env['BUILDERS']['Program'] = program
+ if env['BF_LINE_OVERWRITE']:
+ SCons.Action._ActionAction.print_cmd_line = my_print_cmd_line
class CompZipFile(zipfile.ZipFile):