prezto icon indicating copy to clipboard operation
prezto copied to clipboard

Add `-` alias for `cd -`

Open Enzime opened this issue 2 years ago • 5 comments

Taken with love from oh-my-zsh

Enzime avatar Feb 05 '22 00:02 Enzime

@belak @indrajitr any thoughts on this PR?

Enzime avatar Mar 23 '22 23:03 Enzime

I like it 🤣. But I want to have @belak, @jeffwidman and others weigh in to see if this aligns with general aesthetics of prezto.

indrajitr avatar Mar 23 '22 23:03 indrajitr

@sorin-ionescu @indrajitr any thoughts on this PR?

Enzime avatar Aug 29 '22 10:08 Enzime

Using dashes for an alias might cause problems. Are there any known conflicts?

sorin-ionescu avatar Aug 29 '22 14:08 sorin-ionescu

I think this should be low risk as ohmyzsh has had this alias for 13 years now and I'm not aware of any issues.

This alias should only have an effect when someone uses a single dash as a command i.e.

$ -
$ - apple

The only conflict I'm aware of is a zsh builtin for - which does the following:

The command is executed with a `-' prepended to its argv[0] string.

Enzime avatar Aug 29 '22 15:08 Enzime

Looks good to me! Thanks!

belak avatar Oct 25 '22 22:10 belak