7 Terminal Commands To CHANGE Directory On A Mac | Basic Tutorial - New

  • 2 months ago
7 Terminal Mac COMMANDS to Change Directory On a Mac | Basic Tutorial - NEW #TerminalCommands #Commands #ComputerScienceVideos

Social Media:
--------------------------------
Twitter: https://twitter.com/ComputerVideos
Instagram: https://www.instagram.com/computer.science.videos/
YouTube: https://www.youtube.com/c/ComputerScienceVideos

CSV GitHub: https://github.com/ComputerScienceVideos
Personal GitHub: https://github.com/RehanAbdullah
--------------------------------
Contact via e-mail
--------------------------------
Business E-Mail: ComputerScienceVideosBusiness@gmail.com
Personal E-Mail: rehan2209@gmail.com

Support us on PayPal: https://www.paypal.com/paypalme/ComputerScienceVideo

© Computer Science Videos 2021
Transcript
00:00Computer Science Video is here today to show you guys in this tutorial seven
00:05ways to change directory on a terminal on a Mac computer. Without further ado
00:09let us start the video. So in this tutorial you need to have access to a Mac
00:14computer, be able to use different types of commands within the terminal command
00:20prompt on a Mac computer. We can now start this tutorial. Before we get into the
00:24tutorial itself, towards the end of the video, you will see the previous tutorial
00:31which is all about how to change directory. In this tutorial we are taking
00:36that a step further using seven ways to change directory. So let's start the
00:41tutorial. We can now go all the way down to the dock, go to launchpad, search for the
00:47application terminal which is already built into the Mac computer itself, click
00:55on terminal. Let's now increase the size of the terminal window, command plus a
01:00couple of times, increase, command plus one more time. Let's just clear everything
01:06on screen and now if we type on screen CD that changes directory. If we were in
01:18another directory, let's say a couple of folders down the line, by changing
01:23directory we would go back to the home directory. In order for us to confirm
01:30that we can type in PWD which would show us the home directory which is
01:39computer science videos. Now the second terminal command after CD is change
01:47directories to another folder. Before we do that let's just list everything on
01:52screen using LS minus L. Let's navigate to documents, CD doc, tab to autofill,
02:08enter and now if we LS on screen or LS minus L that now gives us everything
02:21within the documents folder. We can go all the way down to the dock, go to finder and
02:27there you go that's the documents folder on screen. If we go on back to computer
02:34science videos, go within documents, minimize finder for the moment, let's
02:39return to the tutorial itself.
02:44Command number three to change directory is CD and tilde. Let's clear everything
02:53on screen, print work in directories to see where we are at at the moment and so
03:06we are within documents. Let's now type in CD to get tilde on screen use option
03:13and N that gives us the tilde sign, enter LS minus L. We are now back within the
03:23computer science videos folder. Terminal command number four to change
03:31directory would be to change directory and list everything on screen from one
03:38single terminal command. So let's just change directory and now CD documents
03:46semicolon LS minus L. So we are now within documents and everything within
04:00documents has been listed on screen. Now let's take that one step further by
04:06navigating into the github folder. So we're now within the github folder. Let's
04:21now take this one step further, move on to the fifth terminal command which is
04:26CD hyphen and this now takes us to the previous directory or folder that we
04:36last browsed but the real question is which folder are we really in? Let's use
04:40print working directory to check that and we are now in documents. We were in
04:50the github folder, we are now back to documents. Let's now move up to the
04:55parent directory. How can we do that? Let's just navigate to github, cd github
05:06LS minus L, give us some working space or we can clear. Let's now use print
05:17working directory to check which folder we are in and now to navigate or move up
05:25to the parent directory, cd space dot dot which is the terminal command number
05:32six, enter LS minus L. We are now back into documents. Let's take that one step
05:43further by going up two levels. Before we do that let's just navigate back into
05:48the github folder, cd github semicolon LS minus L. Now to go up two levels, cd dot dot
06:04slash dot dot and that takes us back to the computer science videos folder, LS
06:13minus L and there you go. So seven terminal commands to help you change
06:21directory, move up and down a folder, navigate back and forth so we can now
06:27quit terminal. So that's it for this video. I'll see you guys in the next
06:33tutorial. Thanks for now. Thank you for making it towards the end of the video.
06:38Be sure to subscribe to my channel computer science videos. Be sure to check
06:43out the previous video on screen now or you can ideally click on the playlist
06:48and watch all the journey for computer science videos from the start until now.

Recommended