Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

qutebrowser: choose correct executable when restarting #55739

Merged
merged 1 commit into from Feb 24, 2019

Conversation

dotlambda
Copy link
Member

@dotlambda dotlambda commented Feb 13, 2019

Motivation for this change

fixes #25832

Things done
  • Tested using sandboxing (nix.useSandbox on NixOS, or option sandbox in nix.conf on non-NixOS)
  • Built on platform(s)
    • NixOS
    • macOS
    • other Linux distributions
  • Tested via one or more NixOS test(s) if existing and applicable for the change (look inside nixos/tests)
  • Tested compilation of all pkgs that depend on this change using nix-shell -p nox --run "nox-review wip"
  • Tested execution of all binary files (usually in ./result/bin/)
  • Determined the impact on package closure size (by running nix path-info -S before and after)
  • Assured whether relevant documentation is up to date
  • Fits CONTRIBUTING.md.

cc @igsha @The-Compiler @abbradar

@dotlambda
Copy link
Member Author

The only downside to this is that it will restart the old version if qutebrowser has been updated.

@igsha
Copy link
Contributor

igsha commented Feb 14, 2019

@dotlambda is it really necessary to patch the sources? As far as I know the problem is in sys.argv[0] that was changed by nix for any python applications. sys.argv[0] has ..qutebrowser-wrapped-wrapped path instead of just qutebrowser. I think it could be simply fixed by

postFixup = ''
  sed -i 's/\.qutebrowser-wrapped/qutebrowser/' $out/bin/..qutebrowser-wrapped-wrapped
'';

@dotlambda
Copy link
Member Author

@igsha I think that sys.argv[0] would still be ..qutebrowser-wrapped-wrapped and the env vars set by .qutebrowser-wrapped would be lost. Feel free to try it out and report back.

@dotlambda dotlambda merged commit 50a17aa into NixOS:master Feb 24, 2019
@dotlambda dotlambda deleted the qutebrowser-fix-restart branch January 17, 2024 05:21
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

qutebrowser: restart doesn't work
3 participants