Week 1: computer and file system intro
We'll talk about file system navigation, text editors, and a general computer
Notes from week 1.
File system navigation
Here's a quick summary of what we'll do on the command line today.
The command line shell program is called
cmd.exe in Windows. To run,
you can open the start menu and type
cmd, and it will appear. Or you can
win-r (hold the
Windows key and hit
r), and then type
All interaction with the command line consists of typing commands followed
by zero or more arguments, and then possibly redirecting input or output.
The behavior of commands can be modified by specifying flags, which for
Windows programs usually begin with a
/? flag is common to many
commands, and will display a help message.
Basic commands will look like:
command-name /flag-1 /flag-2 arg-1
To display help for a command, you can type:
The command line shell, like all other programs, always has a current directory,
or working directory. In the shell, this is the directory you're currently
looking at, just like if you had opened a graphical Explorer window to a directory.
dir lists the contents of the working directory.
cd changes the working directory.
mkdir creates directories
move copy and move files
del deletes files (permanently!)
The shell (as well as other programs) can use environment variables to keep track
of common information. The
set command lists variables and their values,
or can set variables to new values.
- You can start any other program by typing its name on the command line.
A program must be stored in one of the folders listed in the
environment variable in order for the command line to understand its name.
To add a new folder (say, for example,
set PATH=%PATH%;C:\Program Files\Notepad++
To make the change permanent, you can go into the system settings
Some helpful links:
You'll need to become comfortable using a text editor. You can use whatever
you'd like as long as it has a hex editor. We'll go over Notepad++.
In Notepad++, to enable the hex editor plugin, you have to check the option to
allow unstable plugins in the plugin install menu.
I can also help with Vim or Emacs,
but those are much more complicated.
To make whatever editor you choose easier to use from the command line,
you can add its binary install directory to your path.