Additional Github notes

If Github is being stubborn you can always use :

git push -f origin <branch>

This will force it to push to the current branch.

Found this blog helpful for merging github master and gh-pages branches.

http://lea.verou.me/2011/10/easily-keep-gh-pages-in-sync-with-master/

git log –stat Will show changes made from each commit.

git diff  name of commit name of commit See differences made from each commit.

git clone url to clone repository

 

Additional Github notes

gh-pages to master

git hub

git push origin gh-pages

git checkout master

git merge gh-pages

git push origin master

Extra

…or create a new repository on the command line

echo "# hot_and_cold" >> README.md
git init
git add README.md
git commit -m "first commit"
git remote add origin https://github.com/rdesha0218/hot_and_cold.git
git push -u origin master

…or push an existing repository from the command line

git remote add origin https://github.com/rdesha0218/hot_and_cold.git
git push -u origin master

Take Care

Ryan

JQuery notes from Codecademy

Getting Started

Next, we’ll need to start up our jQuery magic using the $(document).ready();syntax you’ve seen. It works like this:

  • $() says, “hey, jQuery things are about to happen!”
  • Putting document between the parentheses tells us that we’re about to work our magic on the HTML documentitself.
  • .ready(); is a function, or basic action, in jQuery. It says “hey, I’m going to do stuff as soon as the HTML document is ready!”
  • Whatever goes in .ready()‘s parentheses is the jQuery event that occurs as soon as the HTML document is ready.

So,

$(document).ready(something);

says: “when the HTML document is ready, do something!” (We’ll show you how to replace something with an action in the next exercise.)

Note that .ready(); ends with a semicolon. This tells jQuery that you’re done giving it a command.

Thinkful Week 1 Mentor Notes

https://www.railstutorial.org/book

px, pt, em, rem, %, vh (a much newer one)
Git/GitHub

create repository on github.com

git init

git status

git remote -v

git remote add origin https://github.com/username/landing.git

git remote rm origin

git add .

git commit -m “add profile pictures to about section”

git push origin master

git -am “add new paragraphs”

git push origin new-branch

git push origin master -f

git checkout -b new-branch

git status

git checkout new-branch

gh-pages

git checkout -b gh-pages

git push origin gh-pages

https://github.com/onichase/test

onichase.github.io/test

github.com/username/username

username.github.io

git checkout master

git merge new-branch

git push origin master

Notes notes notes…Github notes

If anyone is following along on this blog, I’m going to be using it as a notebook of sorts for my course at Thinkful. Heres a cheat sheet from their website I want to recall:

Git Cheatsheet

Use this cheatsheet as a reference for each of the steps in the basic git workflow.

How to commit your work for the first time in a new project:

  • Initialize a repository: type git init. Command line should say “Initialized empty Git repository”
  • Check the repository: type git status. It should show you the untracked files.
  • Save your progress: track the file by adding it using git add followed by each of the filenames, one at a time.
  • Check what has changed: type git status.
  • Commit the changes: type git commit -m "commit message"
  • Success! If you type git status You should see “nothing to commit, working directory clean”

Pushing your snapshot to Github:

  • Go to Github.com and create a new repository
  • Add GitHub repository as a remote branch: Use git remote add origin git@github.com... (follow Github’s instructions for this line)
  • Send changes to repository: type git push origin master to send your committed changes.
  • To pull from Github: Use the command git pull to keep your version up-to-date with the remote version