Skip to content

Commit

Permalink
Add command aliases
Browse files Browse the repository at this point in the history
  • Loading branch information
LucasPickering committed Oct 8, 2024
1 parent b3aad20 commit feea127
Show file tree
Hide file tree
Showing 3 changed files with 5 additions and 1 deletion.
2 changes: 2 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,8 @@
- Add shell completions, accessed by enabling the `COMPLETE` environment variable [#6](https://github.com/LucasPickering/env-select/issues/6)
- For example, adding `COMPLETE=fish es | source` to your `fish.config` will enable completions for fish
- [See docs](https://env-select.lucaspickering.me/book/user_guide/shell_completions.html) for more info and a list of supported shells
- Add command aliases
- `es r` alias for `es run`, `es s` for `es set`

### Changed

Expand Down
3 changes: 2 additions & 1 deletion src/commands/run.rs
Original file line number Diff line number Diff line change
Expand Up @@ -11,8 +11,9 @@ use clap::Parser;
/// The passed command is run through your shell, meaning you can use aliases
/// and other shell features. See
/// https://env-select.lucaspickering.me/book/user_guide/run_advanced.html for
/// more details of shell interactions.
/// more details on shell interactions.
#[derive(Clone, Debug, Parser)]
#[clap(visible_alias = "r")]
pub struct RunCommand {
#[command(flatten)]
selection: Selection,
Expand Down
1 change: 1 addition & 0 deletions src/commands/set.rs
Original file line number Diff line number Diff line change
Expand Up @@ -10,6 +10,7 @@ const WEBSITE: &str = "https://env-select.lucaspickering.me";

/// Modify current shell environment
#[derive(Clone, Debug, Parser)]
#[clap(visible_alias = "s")]
pub struct SetCommand {
#[command(flatten)]
selection: Selection,
Expand Down

0 comments on commit feea127

Please sign in to comment.