Some time ago, I wrote about a way for programs started in Eshell to use cat
as a pager instead of less
. Since originally I only wanted this behavior with Git, and Git has a =--no-pager
option, it would be better to automatically add that option to Git.
Well, it turns out that Eshell has the feature we know and love in bash: aliases. The only catch is that they work slightly different (in bash you would use an equal sign whereas in Eshell you use a space, and the body of the alias should be in single quotes in Eshell).
So to sum it up, you can say
alias git 'git --no-pager $*'
when in Eshell (aliases are saved automatically), and enjoy your new Git experience at once.
CategoryEnglish, CategoryBlog, CategoryEmacs, CategoryEshell, CategoryGit