Skip to content

Instantly share code, notes, and snippets.

View felipeplets's full-sized avatar
🚀
Creating a better world, line by line.

Felipe Plets felipeplets

🚀
Creating a better world, line by line.
View GitHub Profile

Keybase proof

I hereby claim:

  • I am felipeplets on github.
  • I am felipeplets (https://keybase.io/felipeplets) on keybase.
  • I have a public key whose fingerprint is 0AD8 408B D99E DEC4 E16E 104B 466E 5B11 EC75 F1CC

To claim this, I am signing this object:

@felipeplets
felipeplets / podforceupdate.sh
Created May 3, 2016 13:01 — forked from mbinna/podforceupdate.sh
Clear CocoaPods cache, re-download and re-install all pods
#!/usr/bin/env bash
rm -rf "${HOME}/Library/Caches/CocoaPods"
rm -rf "`pwd`/Pods/"
pod update
@felipeplets
felipeplets / gist:aea47bb93e5a298a5fd5ff4de420e2ca
Created August 12, 2016 17:19
Open two instances of Unity or Mono IDEs on macOS
Run the following commands on your terminal:
/Applications/Unity/Unity.app/Contents/MacOS/Unity
/Applications/Unity/MonoDevelop.app/Contents/MacOS/monodevelop
@felipeplets
felipeplets / README.md
Last active November 16, 2022 15:28
Better setup for iTerm

iTerm2

Plist

The Plist file above is located at ~/Library/Preferences/com.googlecode.iterm2.plist but the file is binary and not XML. To edit and replace the XML I recommend using Visual Studio Code with the extension Binary Plist. VS Marketplace Link: https://marketplace.visualstudio.com/items?itemName=dnicolson.binary-plist

The steps bellow are not needed if the settings file is replaced.

git branch --merged | egrep -v "(^\*|master|dev)" | xargs git branch -d
@felipeplets
felipeplets / loader.bash
Last active July 3, 2019 15:29 — forked from JuggoPop/Git branch bash autocomplete *with aliases*
Git branch bash autocomplete *with aliases* (add to .bash_profile)
# To Setup:
# 1) Save the .git-completion.bash file found here:
# https://github.com/git/git/blob/master/contrib/completion/git-completion.bash
# 2) Add the following lines to your .bash_profile, be sure to reload (for example: source ~/.bash_profile) for the changes to take effect:
# Git branch bash completion
if [ -f ~/.git-completion.bash ]; then
. ~/.git-completion.bash
# Add git completion to aliases
@felipeplets
felipeplets / promiseWillFail.js
Created August 28, 2019 19:59
Error handling in JS promises
// Assuming I just want to console.log the error message
await promiseWillFail().catch((err) => console.log(err.message));
https://blog.shanbhag.me/My-terminal-iTerm2-Oh-my-Zsh-with-PowerLevel10k/#Oh-My-Zsh
# zsh + oh-my-zsh
brew install zsh
sh -c "$(curl -fsSL https://raw.githubusercontent.com/ohmyzsh/ohmyzsh/master/tools/install.sh)"
curl -o- https://raw.githubusercontent.com/nvm-sh/nvm/v0.36.0/install.sh | bash
nvm install 14
brew install fzf
@felipeplets
felipeplets / Script to clone multiple repositories and npm install
Created May 5, 2020 11:25
Shell script using GitHub CLI (gh) to download multiple repositories and run npm ci
USER=githubuser; PREFIX=secret-; REPOS=('proj1' 'proj2' 'proj3') && for REPO in ${REPOS}; do gh repo clone ${USER}/${PREFIX}${REPO} && cd ${PREFIX}${REPO} && npm ci && cd ..; done
# Install JQ
brew install jq
# Format JSON file
jq . input.json > output.json