Skip to content

Alter pushd to add more bash-like behaviour - #2173

Closed
donkopotamus wants to merge 1 commit into
fish-shell:masterfrom
donkopotamus:patch-1
Closed

donkopotamus wants to merge 1 commit into
fish-shell:masterfrom
donkopotamus:patch-1

Conversation

@donkopotamus

Copy link
Copy Markdown
Contributor

The following behaviour is added:

  • an empty pushd exchanges the top two directories in the stack;
  • pushd + rotates the stack so that the n-th directory (counting from the left of the list shown by dirs, starting with zero) is at the top;
  • pushd - rotates the stack so that the nth directory (counting from the right of the list shown by dirs, starting with zero) is at the top.

The following behaviour is added:
- an empty pushd exchanges the top two directories in the stack;
- pushd +<n> rotates the stack so that the n-th directory (counting from the left of the list shown by dirs, starting with zero) is at the top;
- pushd -<n> rotates the stack so that the nth directory (counting from the right of the list shown by dirs, starting with zero) is at the top.
@donkopotamus

Copy link
Copy Markdown
Contributor Author

This is related to #1944

@ridiculousfish

Copy link
Copy Markdown
Member

Fixed a typo, and merged as f07d59c. Thanks!

@ridiculousfish ridiculousfish added this to the next-2.x milestone Jul 12, 2015
@zanchey

zanchey commented Jul 14, 2015

Copy link
Copy Markdown
Member

Reopening to remind us to add this to the documentation.

@zanchey zanchey reopened this Jul 14, 2015
@zanchey zanchey added the docs An issue/PR that touches or should touch the docs label Jul 14, 2015
faho added a commit to faho/fish-shell that referenced this pull request Aug 10, 2015
@faho faho closed this in 53456b5 Sep 11, 2015
@faho faho added enhancement and removed docs An issue/PR that touches or should touch the docs labels Sep 26, 2015
@github-actions github-actions Bot locked as resolved and limited conversation to collaborators Apr 17, 2020
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants