
- #MAC TERMINAL COMMANDS TO LOOK LIKE A HACKER CODE#
- #MAC TERMINAL COMMANDS TO LOOK LIKE A HACKER MAC#
- #MAC TERMINAL COMMANDS TO LOOK LIKE A HACKER WINDOWS#
cd ("change dir") - With no directory, it lists the current directory.
#MAC TERMINAL COMMANDS TO LOOK LIKE A HACKER MAC#
These apply to Mac / Unix / Linux / bash Basic Command Review (DOS)
cd ("change dir") - move into a different directory. mkdir ("make dir") - creates a new subdirectory inside the current directory. ls ("list") - shows the contents of the current directory. pwd ("print working dir") - shows the name of the current directory. This will send you back to your home directory. If you ever get lost, type cd all on its own and press the return key. #MAC TERMINAL COMMANDS TO LOOK LIKE A HACKER CODE#
For example, cd code would move you into a subdirectory named code. cd ("change dir") moves you into a different directory.
when you type mkdir ("make directory") it creates a new subdirectory inside the current directory. Using your terminal, list your home directory's contents. (Your file manager is called "Finder" in MacOS, or "Explorer" in Windows. Using your GUI, navigate to your home directory and open it in a file manager window. #MAC TERMINAL COMMANDS TO LOOK LIKE A HACKER WINDOWS#
On Windows you may need to type dir /A:SH instead. If you type ls -al ("list all long") it also shows hidden files and extra info like the modification date On Windows you may need to type dir instead. When you type ls ("list") it shows the contents of the current directory You can get back to your home directory by typing cd %HOME% Listing Directory Contents WARNING: On some windows systems, Command Prompt will open to C:\Windows\System32. > WARNING: On some windows systems, Command Prompt will open to C:\Windows\System32 create a new directory inside code for each lesson or project.
create a code directory inside your home directory.if you store files directly in your home directory, it will soon get cluttered.when you first open the Terminal you are in your HOME DIRECTORY.Most of the time you can also look at the prompt to see what the current directory is.This stands for "print working directory" (not "password").To find out which directory you are in, type: p w d Return.It is very easy to get lost in a maze of directories.Inside the Terminal, you are always "inside" a directory.directories can also contain other directories (called subdirectories).a directory is a location on your hard disk.If that doesn't print 'podcast', look at the prompt you may be inside your shell instead of inside node. node is a command line program that is launched from the shellįrom inside node, if you want to get back to the shell.įrom now on, whenever you see text in the code font, try typing it into the terminal and see what happens! For example: 'pod' + 'cast'.the shell is the command line interpreter that the terminal starts with.WARNING: Before you start typing, look at the prompt! NodeJS (aka node) is an engine that runs JavaScript programs - either from files, or interactively from the command line. Yay! Your computer is an expensive calculator!Īn "engine" is a type of program that either executes or empowers other programs.press the Return key (also called Enter).type node - that's you commanding the computer to launch node.look at the prompt - it should end with a $ or > symbol.and if your window is too short then the top lines will scroll away and you will miss them when reading a program's output you want to start reading at the top.Important: make your terminal as tall as possible and don't overlap windows
Windows (alternate): Launch the Windows Command Prompt ( cmd.exe or PowerShell) - but beware, the commands are slightly different than in bash. Windows: launch the "Cmder" application (pronounced "Commander"), make a new console ( Ctrl- T) and select. Mac OS: launch the "Terminal" application. Picture of Teletype Corporation ASR-33 on display at the Computer History Museum by ArnoldReinhold via Wikimedia Lab: Opening the Terminal See this twitter thread for more history and TTY pix. When you type into the console and hit Enter you are pretending to type a line onto a TTY the scrolling terminal is like a roll of printer paper. The Terminal app is a direct descendant of a TeleType printer or TTY. a CLI is more primitive and more powerful than a GUIĬomputers used to not have screens! They were connected to devices like this:. a CLI (Command Line Interface) is different from the GUI (Graphical User Interface) you are used to. when you type into the terminal, you are issuing commands to the computer. aka console or command line or command prompt or shell. the terminal is a window into which you can talk directly to your computer.