If you ever get lost in your computer, then pwd
is for you.
This command stands for “print working directory” or “pathway directory.”
It prints your current location.
For example, if you’re located in a shared insert_PI_here_group
folder and
used pwd
, it’d look like:
\begin{lstlisting}[style=P1]
$ pwd
/storage/scratch/share/insert_PI_here_group/
\end{lstlisting}
This location can be copied from the command line and pasted into various
locations where it is needed (like code input lines).
Paths are important for programs, copying files, creating new files; many
commands are path-dependent.
Think of the path as the computer’s Google Maps.
Without it, you wouldn’t get anywhere.
Similarly, you can think of an alias as the routes
you use so often, you have them memorized.
- UNIX Guide 0.1
- Getting Started
- Connecting to Computers (ssh and VPN)
- Folders: cd, mkdir, pwd, and more!
- Copying and Removing Files
- Compressing and Expanding Files
- Processes
- Creating, Reading, and Editing Files
- Printing and Reorganizing Files
- Images
- Keyboard Shortcuts and Special Characters
- Other Helpful Things
- Quick Intro to Computer Admin-ing
- Running Jobs
- Fun Commands