Skip to content

Instantly share code, notes, and snippets.

@rufus2021
Created June 22, 2015 17:08
Show Gist options
  • Save rufus2021/87f6163ecab2ba4d3d0d to your computer and use it in GitHub Desktop.
Save rufus2021/87f6163ecab2ba4d3d0d to your computer and use it in GitHub Desktop.
Steps for creating a new branch, adding, commiting & pushing changes & creating a new pull request
NOTE: don't make commits directly to the develop branch.
step 1: git checkout develop - checks out the develop branch locally
step 2: git pull - gets you the latest updates for the repo
step 3: git checkout -b name bugfix/yaya-codes-awesome - create a new branch based off of develop
you make a change in sass code
npm test - tests code for any syntax errors
if no errors -> git status - shows you the files changed
git add . - adds all changed files
git commit -m 'commit message here'
git push (you get a message to set upstream branch)
copy/paste the message and hit enter
go to github.com/repo and create a new pull request
@yaya-wang
Copy link

Branches

Creating a new branch

git checkout -b feature/some-work-to-do

Viewing Your Branches

Your current branch will be marked with an asterisk (*)

git branch

Viewing branches that have already been merged

git branch --merged

Deleting branches that have been merged (or have no changes)

git branch -d <branch name>

Deleting a branch that has not been merged

Use force! Because you're the boss

git branch -D <branch name>

note: capital -D

Changing the name of the current branch

git branch -m <new branch name>

@yaya-wang
Copy link

Whenever autopilot components are updated, run command

npm install

this will update app locally.

@yaya-wang
Copy link

npm i && gulp sprite && gulp build

install everything.

@yaya-wang
Copy link

AD:
NODE_ENV='development' NODE_COPILOT_API='ci-ad-api.aws.conde.io' PARSELY_APIKEY="architecturaldigest.com" PARSELY_SECRET="XtQS15Iqm80BOOQz3KhVs9ehvOBKYdcJlKMFXqxBTiU" gulp develop

@yaya-wang
Copy link

ulimit -n 2560

ulimit -n 1024
ulimit -u 1024

@yaya-wang
Copy link

copilot

git pull --rebase

Frontend

npm i && bower i

start server
ember server

Backend

another tab: cd express -> copilot/express
npm i

start server
NODE_ENV=remoteauth npm start

Visit: copilot-local.aws.conde.io:4200

@yaya-wang
Copy link

Copilot Theme

  1. ywang5 ~/Developer/copilot-theme npm link
  2. ywang5 ~/Developer/copilot npm link @condenast/copilot-theme
  3. Uncomment that part in copilot-theme/index.js

@yaya-wang
Copy link

screen shot 2016-03-30 at 3 07 39 pm

@yaya-wang
Copy link

scss-lint folder/file

@yaya-wang
Copy link

nvm ls
nvm use v4.4.1

@yaya-wang
Copy link

Merging others' branch

git pull origin [branch]

@yaya-wang
Copy link

yaya-wang commented Feb 2, 2017

Abandon code

git checkout -- ./ in root directory
git checkout . on the branch

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment