
#Mac terminal commands to repair mac
Using cd to navigate folders using the Mac terminalĬd is another fundamental command that you’re going to be using constantly. Additionally, if you create a file or remove a file, using ls is a great way to confirm that the action was completed properly. Together, they tell you where you are and can help you figure out where you want to go. I tend to use this in conjunction with pwd. If you’re in your Desktop, you’ll see all of the folders and files located on your Desktop. Go ahead and type ls into your terminal and press return.Īs you’ll see, this command is used to list the directories within your current directory. Using ls to navigate folders using the Mac terminalĪ command that’s very similar to pwd is ls (“LS”). Anytime you feel lost or confused by the terminal, enter the pwd command. Not only will it tell you where you are, but where you’ve been, where a particular file might be, and so on. If you’re several directories deep in the terminal, this can be a lifesaver. In the example above, you can see that I can get to the “justinmeredith” directory by first going into Users, and then justinmeredith. Not only will you see that, but you’ll also see the path it takes to get to your current directory. In my case, I’m in the directory named after my Mac username, which also happens to be my name. The line of text that appears in your terminal will tell you which folder (or directory) you’re currently in. Go ahead and type pwd into your terminal and press return. Not only is it helpful when you need to navigate folders using the Mac terminal, but it’s necessary when checking that you’re executing a command in the right folder. Pwd is the fundamental Mac terminal command. Using pwd to navigate folders using the Mac terminal So go ahead and launch your Mac terminal, and let’s get into it. In my opinion, these are the bread and butter of not only using the terminal but understanding how it works, too. There are other commands you can use for navigating, but these are the commands you’ll be using every time you open the terminal. The list of commands below is not exhaustive.
#Mac terminal commands to repair how to
How to navigate folders using the Mac terminal: Commands you’ll need to know You can now navigate folders using the Mac terminal to your heart’s content.Navigate Folders Using The Mac Terminal: Putting it all together.Use rm, rm -R, and rm -i to delete files and folders.



