gnome-shell-jhbuild: Allow passing args to gnome-shell

$ ./gnome-shell -- --list-modes

https://bugzilla.gnome.org/show_bug.cgi?id=689778
This commit is contained in:
Jasper St. Pierre 2012-12-06 10:58:53 -05:00
parent c4ba31cb23
commit cfacb05461

View File

@ -93,6 +93,7 @@ def start_shell():
args.append('--replace') args.append('--replace')
if options.sync: if options.sync:
args.append('--sync') args.append('--sync')
args += params
return subprocess.Popen(args, env=env) return subprocess.Popen(args, env=env)
def run_shell(): def run_shell():
@ -156,11 +157,7 @@ parser.add_option("", "--sync", action="store_true")
parser.add_option("", "--version", action="callback", callback=show_version, parser.add_option("", "--version", action="callback", callback=show_version,
help="Display version and exit") help="Display version and exit")
options, args = parser.parse_args() options, params = parser.parse_args()
if args:
parser.print_usage()
sys.exit(1)
# Handle ssh logins # Handle ssh logins
if 'DISPLAY' not in os.environ: if 'DISPLAY' not in os.environ: