Commits

Michał Górny  committed 3605003

Use ESCM_OFFLINE to avoid trying to refetch unnecessarily.

  • Participants
  • Parent commits daf9845

Comments (0)

Files changed (1)

File smart-live-rebuild.py

 	)
 	opt.add_option('-C', '--no-color', action='store_false', dest='color', default=True,
 		help='Disable colorful output')
+	opt.add_option('-O', '--no-offline', action='store_false', dest='offline', default=True,
+		help='Disable setting ESCM_OFFLINE for emerge.')
 	opt.add_option('-p', '--pretend', action='store_true', dest='pretend', default=False,
 		help='Only print a list of the packages which were updated; do not call emerge to rebuild them.')
 	opt.add_option('-R', '--record', action='store_true', dest='record', default=False,
 			print p
 	else:
 		out.s1('Calling emerge to rebuild %s%d%s packages ...' % (out.white, len(packages), out.s1reset))
+		if opts.offline:
+			os.putenv('ESCM_OFFLINE', 'true')
 		cmd = ['emerge']
 		if not opts.record:
 			cmd.append('--oneshot')