Skip to content

repl: add :lh command#4392

Closed
Synthetica9 wants to merge 1 commit intoNixOS:masterfrom
Synthetica9:repl-lh
Closed

repl: add :lh command#4392
Synthetica9 wants to merge 1 commit intoNixOS:masterfrom
Synthetica9:repl-lh

Conversation

@Synthetica9
Copy link
Member

:lh <hash> is a convenience shortcut, it does the same as
:l https://github.com/nixos/nixpkgs/archive/<hash>.tar.gz.

I'm not sure if this sort of thing is within scope, but it is something I would use very often myself, so I can imagine this would also be useful to other people.

@edolstra
Copy link
Member

It would probably be better to add flake support to the repl (#3803), e.g. a command like :lf <flakeref> would allow :lf nixpkgs/<hash>.

@Synthetica9
Copy link
Member Author

It would probably be better to add flake support to the repl (#3803), e.g. a command like :lf would allow :lf nixpkgs/.

I agree, it was just that I saw this would be a pretty trivial change to make, so I wanted to have the option out there. Full flake support seems to be a significantly bigger undertaking.

@Mic92
Copy link
Member

Mic92 commented Dec 24, 2020

It would probably be better to add flake support to the repl (#3803), e.g. a command like :lf would allow :lf nixpkgs/.

I agree, it was just that I saw this would be a pretty trivial change to make, so I wanted to have the option out there. Full flake support seems to be a significantly bigger undertaking.

Is there no easy to access function that loads flakes? There is a builtin builtin.getFlake - I would expect this one to be also reachable from c++.

@stale
Copy link

stale bot commented Jun 22, 2021

I marked this as stale due to inactivity. → More info

@stale stale bot added the stale label Jun 22, 2021
@terlar
Copy link

terlar commented Jun 22, 2021

Still a good feature request

@stale stale bot removed the stale label Jun 22, 2021
@stale
Copy link

stale bot commented Jan 3, 2022

I marked this as stale due to inactivity. → More info

@stale stale bot added the stale label Jan 3, 2022
@Ericson2314 Ericson2314 added feature Feature request or proposal repl The Read Eval Print Loop, "nix repl" command and debugger labels Mar 11, 2023
@stale stale bot removed stale labels Mar 11, 2023
@Ericson2314
Copy link
Member

Ericson2314 commented Mar 11, 2023

We now have the :lf that @edolstra suggested (from #6233). Furthermore, one can also do :a fetch-however-one-likes. Can we close this?

@Ericson2314
Copy link
Member

Closing per the above.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

feature Feature request or proposal repl The Read Eval Print Loop, "nix repl" command and debugger

Projects

None yet

Development

Successfully merging this pull request may close these issues.

5 participants