diff --git a/pages/common/popd.md b/pages/linux/popd.md similarity index 100% rename from pages/common/popd.md rename to pages/linux/popd.md diff --git a/pages/osx/popd.md b/pages/osx/popd.md new file mode 100644 index 0000000000..fab4246dc2 --- /dev/null +++ b/pages/osx/popd.md @@ -0,0 +1,15 @@ +# popd + +> Remove a directory placed on the directory stack via the pushd shell built-in. + +- Remove the top directory from the stack and cd to it: + +`popd` + +- Remove the Nth directory (starting from zero to the left from the list printed with `dirs`): + +`popd +N` + +- Remove the Nth directory (starting from zero to the right from the list printed with `dirs`): + +`popd -N`