Skip to content

Instantly share code, notes, and snippets.

namzo /
Last active Nov 21, 2020
Fix gem install error - MacOS Bug Sur

If you get this error message:

ERROR: While executing gem ... (Gem::FilePermissionError) You don't have write permissions for the /usr/bin directory.


sudo gem install [gem-name] -n /usr/local/bin

namzo / update-npm
Created Nov 19, 2020
Update npm packages when update isn't working
View update-npm
npm i -g npm-check-updates
ncu -u
npm install
namzo /
Last active May 11, 2020
Pull changes from feature branch to master

1. Update your master branch:

git checkout master
git pull --rebase origin master

2. Merge changes from Master to feature branch

git checkout [feature branch name]
git merge --no-ff master

3. Check if your changes has been included (Optional)

git log
namzo /
Last active May 11, 2020
Git workflow

1. Create new branch with changes in master

git checkout -b [feature branch name]

2. Add changes and Commit

git commit -a -m "Commit message"

3. Push changes to remote

git push origin [feature branch name]