du -sh .Print how much memory the current folder (and everything within it) is taking up on disk.dustands for disk usage,-shasks for the info to be summarised in a human readable format.- output examples:
178M .or1.2G .(178 megabytes and 1.36 Gigabytes respectively)
lsof -i:8080- List the processes (or files) running on port 8080
lsofstands for list open files- In posix systems all processes are considered files, so this works for e.g. server processes etc.
- The output will give you the PID (process ID) of the process
- If you then want to kill the process you can enter
kill <insert PID here>.
find . -name *.kt-- search current folder (recursively) for all files with a given filename ending (in this case .kt)findis a tool for working with file hierarchies- This will give you a list of the relative paths of the files from the current directory.
- The
*is a wildcard character matching all text before.kt
Last active
August 25, 2025 15:53
-
-
Save stantronic/0197e515a877c70a11b88874a43cf759 to your computer and use it in GitHub Desktop.
Useful bash commands
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment