About 135,000 results
Open links in new tab
  1. Get current directory or folder name (without the full path)

    How could I retrieve the current working directory/folder name in a bash script, or even better, just a terminal command. pwd gives the full path of the current working directory, e.g. /opt/local/b...

  2. cmd - Windows equivalent to UNIX pwd - Stack Overflow

    May 28, 2009 · 18 cd without any parameters is equivalent to pwd on Unix/Linux. From the console output of typing cd /?: Displays the name of or changes the current directory. [...] Type …

  3. linux - What's the difference between unix built-in `pwd` …

    Dec 6, 2010 · The difference between the /bin/pwd external command and the built-in is that the external command doesn't know what set of cd operations got you there and therefore doesn't …

  4. powershell - Analog of $PWD in Windows - Stack Overflow

    Mar 5, 2021 · 3 I run windows command in particular directory and I need to pass files and subdirectories in this directory with full path. How to retrieve full path of current directory? …

  5. linux - How to get full path of a file? - Stack Overflow

    On Windows: Holding Shift and right clicking on a file in Windows Explorer gives you an option called Copy as Path. This will copy the full path of the file to clipboard. On Linux: You can use …

  6. Replacement for `pwd` in Windows PowerShell - Stack Overflow

    Feb 18, 2014 · I have a Unix script which uses the command Current_Dir=`pwd` What would be the suitable replacement for it in Windows Power shell script?

  7. cmd - 'pwd' is not recognized as an internal or external command ...

    Oct 9, 2017 · I am getting 'pwd' is not recognized as an internal or external command operable program or batch file when I am trying to check my present working directory from cmd.

  8. pwd command with shell script - Stack Overflow

    Oct 6, 2014 · This was helpful in trying to debug script that uses the following SCRIPT_PATH="$(cd "$(dirname "$0")" ; pwd -P)" - turns out $(dirname "$0") is unreliable. …

  9. linux - How can I copy the output of a command directly into my ...

    May 25, 2017 · Just to cover an edge case:) and because the question title asks (at least now) how to copy the output of a command directly to clipboard. Oftentimes, I find it useful to copy …

  10. How can I shorten my command line prompt's current directory?

    Apart from the bash-builtin solution using PROMPT_DIRTRIM, you may want to try $(pwd | tail -c16), which is a tad simpler than most other answers, but just gives the last 16 characters of …