Skip to content

Instantly share code, notes, and snippets.

@Alacrity01
Last active April 23, 2019 00:31
Show Gist options
  • Save Alacrity01/9021e9238f7e281d26d6d3512f60b425 to your computer and use it in GitHub Desktop.
Save Alacrity01/9021e9238f7e281d26d6d3512f60b425 to your computer and use it in GitHub Desktop.
Week 1, Day 1
• Learned about GitHub and how important it is for coders.
• Swiping up with 4 fingers shows all desktops open. Swiping left or right switches between the desktops.
• Chrome is preferred over Safari, even by Mac users.
Terminal commands:
ls Lists contents of current directory
cd <name> Changes directory to one specified by name
cd .. Goes to previous directory (parent directory)
cd ~ Goes to home directory
control + l Clears terminal window
mkdir <name> Creates a new directory with given name
rm -rf <name> "Remove with recursive force" the given directory (name) CAREFUL! POSSIBLE TO DELETE OPERATING SYSTEM WITH THIS COMMAND!
rm -rf / THIS COMMAND WILL RUIN YOUR COMPUTER by deleting all directories with /
mkdir "folder_"{3..10} Creates multiple folders named folder_3 through folder_10
touch frog.txt Creates a text file named frog
touch kermit.rb Creates a ruby file named kermit
ls -GF Color codes directories when using list command
cd folder_1/example_directory Example of jumping multiple directories
cd ../.. Backtracks (moves up) two directories
echo "hello" Bash version of printing "hello" (Bash is the name of the language used in terminal--also known as Bash Shell)
echo "hello" >> frog.txt Enters text "hello" into file frog.txt
open frog.txt Opens file frog.txt
cat frog.txt Prints contents of frog.txt to terminal
say "hi mom" Will read text (audibly say "hi mom")
NOTE: folders/directories do not have extensions
snake case is all lower case connected by underscores
parent directory is the directory immediately above
root directory is the hard disk
home directory is the initial path of the current user
Git is an application that allows you to track changes over time.
GitHub is a service(?) that makes use of Git software(?).
Versioning is a process of taking snapshots that document the changes of an application.
git init Initializes git to track changes to files in the directory.
git --all Will track all changes to files within the directory. (Adds to staging area)
git commit -m "here's a note about what I did (added files)" Saves changes that have occured in the current directory. (Takes a snapshot)
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment