unofficial mirror of guix-devel@gnu.org 
 help / color / mirror / code / Atom feed
* Git-style aliases in Guix?
@ 2017-02-25 20:59 Alex Griffin
  2017-02-26 21:15 ` Mekeor Melire
  0 siblings, 1 reply; 10+ messages in thread
From: Alex Griffin @ 2017-02-25 20:59 UTC (permalink / raw)
  To: guix-devel

I think it would be cool and useful if Guix had some kind of config file
where users could define new commands or aliases, as in git. I'm sure
many people here already have their own helper code to work witk Guix,
whether that's in shell scripts, bashrc, guile, elisp, etc. And it would
make it easier to experiment with changing the command line syntax
without committing to any change too soon.

I've attached my own Guix wrapper function to show some use cases, like:

# New features
* automatically invoke `./pre-inst-env` when ~/.config/guix/latest
points to a git repo
* `guix make` builds Guix in your git checkout directory
* `guix clean` cleans out your Guix git checkout
* `guix visit <package>` opens a package's homepage in a browser
* `guix ls` lists the files in a Guix package (must be present or built
on your machine)

# Convenience Commands
* `guix search` wraps `guix package -s` with a recutils template
* `guix manifest` -> guix package --manifest=~/.config/guix/profile.scm
* `guix reconfigure` -> sudo guix system reconfigure
~/.config/guix/system.scm
* `guix repl` just invokes `./pre-inst-env guile`, but it should
probably also load some Guix modules.

# Simple Aliases
* `guix add` or `guix install` -> guix package --install
* `guix env` -> guix environment
* `guix try` -> guix environment --ad-hoc
* `guix profile` -> guix package
* `guix show` or `guix info` -> guix package --show=
* `guix remove` or `guix uninstall` -> guix package --remove

What does everyone think? If you like the idea, what would the
implementation/config file look like?
-- 
Alex Griffin

^ permalink raw reply	[flat|nested] 10+ messages in thread
* Git-style aliases in Guix?
@ 2017-02-25 20:58 Alex Griffin
  0 siblings, 0 replies; 10+ messages in thread
From: Alex Griffin @ 2017-02-25 20:58 UTC (permalink / raw)
  To: guix-devel

[-- Attachment #1: Type: text/plain, Size: 1594 bytes --]

I think it would be cool and useful if Guix had some kind of config file
where users could define new commands or aliases, as in git. I'm sure
many people here already have their own helper code to work witk Guix,
whether that's in shell scripts, bashrc, guile, elisp, etc. And it would
make it easier to experiment with changing the command line syntax
without committing to any change too soon.

I've attached my own Guix wrapper function to show some use cases, like:

# New features
* automatically invoke `./pre-inst-env` when ~/.config/guix/latest
points to a git repo
* `guix make` builds Guix in your git checkout directory
* `guix clean` cleans out your Guix git checkout
* `guix visit <package>` opens a package's homepage in a browser
* `guix ls` lists the files in a Guix package (must be present or built
on your machine)

# Convenience Commands
* `guix search` wraps `guix package -s` with a recutils template
* `guix manifest` -> guix package --manifest=~/.config/guix/profile.scm
* `guix reconfigure` -> sudo guix system reconfigure
~/.config/guix/system.scm
* `guix repl` just invokes `./pre-inst-env guile`, but it should
probably also load some Guix modules.

# Simple Aliases
* `guix add` or `guix install` -> guix package --install
* `guix env` -> guix environment
* `guix try` -> guix environment --ad-hoc
* `guix profile` -> guix package
* `guix show` or `guix info` -> guix package --show=
* `guix remove` or `guix uninstall` -> guix package --remove

What does everyone think? If you like the idea, what would the
implementation/config file look like?
-- 
Alex Griffin

[-- Attachment #2: guix-wrapper.sh --]
[-- Type: application/x-shellscript, Size: 1677 bytes --]

^ permalink raw reply	[flat|nested] 10+ messages in thread

end of thread, other threads:[~2017-03-09 10:53 UTC | newest]

Thread overview: 10+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2017-02-25 20:59 Git-style aliases in Guix? Alex Griffin
2017-02-26 21:15 ` Mekeor Melire
2017-02-27  5:54   ` John Darrington
2017-02-27  8:30     ` Mekeor Melire
2017-02-27 15:15       ` John Darrington
2017-02-27 19:01         ` Mekeor Melire
2017-03-08  8:53           ` Ludovic Courtès
2017-03-09  3:27             ` Mekeor Melire
2017-03-09 10:53               ` Ludovic Courtès
  -- strict thread matches above, loose matches on Subject: below --
2017-02-25 20:58 Alex Griffin

Code repositories for project(s) associated with this public inbox

	https://git.savannah.gnu.org/cgit/guix.git

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).