Skip to content

Commit ac6f09d

Browse files
committed
Automate alias target-file specification
1 parent 931414a commit ac6f09d

File tree

1 file changed

+7
-3
lines changed

1 file changed

+7
-3
lines changed

Diff for: README.md

+7-3
Original file line numberDiff line numberDiff line change
@@ -451,9 +451,13 @@ Call `lazygit` in your terminal, while inside a git repository.
451451
$ lazygit
452452
```
453453

454-
If you want, you can
455-
also add an alias for this with `echo "alias lg='lazygit'" >> ~/.zshrc` (or
456-
whichever rc file you're using).
454+
### Add ZSH/Bash Alias
455+
456+
Create a shortcut for lazygit by adding an alias to the shell configuration file.
457+
458+
```sh
459+
echo "alias lg='lazygit'" >> "$HOME/.$(basename $SHELL)rc"
460+
```
457461

458462
### Keybindings
459463

0 commit comments

Comments
 (0)