Closed senorsmile closed 4 years ago
Note: I'm only trying this method because installing via cargo on Ubuntu 20.04 has issues: https://github.com/jD91mZM2/xidlehook/issues/44
I was able to build it by doing: $ nix-shell nix-build
It created a result/ dir, which is a symlink inside /nix
I can run xidlehook directly from there, but cannot run it from any where else. It seems that nix hasn't enabled that to be accessed like other programs it installs (e.g. the hello program in the getting started manual nix-env -i hello
makes this hello program available to all).
I just saw the second nix method using:
nix-env -if https://gitlab.com/jD91mZM2/xidlehook/-/archive/master.tar.gz
This does work! I'd like to be able to target a stable release of xidlehook rather than master.
So I tried to uninstall that nix-env -e xidlehook but that didn't seem to remove anything.
I tried reinstall using
$ nix-env -if https://github.com/jD91mZM2/xidlehook/archive/0.8.2.tar.gz
...
replacing old 'rust_xidlehook-0.8.2'
installing 'rust_xidlehook-0.8.1'
This took quite a bit longer (apparently building from source whereas the master install installed a prebuilt binary).
That eventually succeeded, but it looks like the tag for 0.8.2. points to a commit that shows the previous version:
$ xidlehook --version
xidlehook 0.8.1
At this point, it's good enough.
I don't know what the proper path is for people to install via Nix. There likely needs to be some update to the README?
Yes, the README seems wrong. The right command is nix-env -iA nixpkgs.xidlehook
!
Not sure why 0.8.2 points to 0.8.1... That's really interesting
I will admit that I know next to nothing about using nix. I've installed it successfully.