Instantly share code, notes, and snippets.

# overwrite master with contents of seotweaks branch (seotweaks > master)
git checkout seotweaks # source name
git merge -s ours master # target name
git checkout master # target name
git merge seotweaks # source name
View es6 develop environment
install global babel-cli
`npm install --global babel-cli`
create .babelrc configuration file
run the babel command
View http_status_codes
# HTTP Status Codes
* 1xx Informational responses
** 100 Continue
* 2xx Success
* 3xx Redirection
* 4xx Client errors
* 5xx Server errors
View moving git repository to a new
  1. Add old remote server to the existing repository
git remote add <old-remote-server-name> <old-remote-server-address>
  1. Pull the branch of old remote server to the local
git pull <old-remote-server-name> <remote-branch-name>
  1. Push the branch to the new remote server
View multiple applications on front end


module.exports = {
  entry: {
    'app1': 'path/to/app1',
    'app2': 'path/to/app2'
  output: {
    path: 'your/local/file/path',
    filename: 'subdirectory/[name].js'
View iterm


Adjusting font size in one tab, when open a new tab, get the new size

cmd-i and then click Copy Preferences to Profile.
reference link



Git configuration

  • Change your editor git config --global core.editor vim

  • Change your merge tool git config --global merge.tool vimdiff git config --global merge.conflictstyle diff3



Generate passphrase

dd if=/dev/urandom bs=16 count=1 2>/dev/null | base64 | sed 's/=//g'

View node version manager



curl -o- | bash

The script clones the nvm repository to ~/.nvm and adds the source line to your profile (~/.bash_profile, ~/.zshrc, ~/.profile, or ~/.bashrc).

export NVM_DIR="$HOME/.nvm"

Photoshop design basics

Create your first design

Get to know layers

Layers are the building blocks of any photoshop design.

Combine images using layer masks

Layer masks are the most flexible way to combine images.