If you want to get a quick improvement to your npm productivity, you can add autocompletion for npm to your shell with just one command.
For bash, you can add npm autocompletion with: npm completion >> ~/.bashrc
For zsh, you can add npm autocompletion with: npm completion >> ~/.zshrc
And now you’ll have tab autocomplete for npm commands.
When you are working inside a Git repository it is important to realize what is the currently checked out Git branch.
You can make it easier to track where you are, by showing the name of the current Git branch in the terminal (command prompt).
Edit bash: gedit ~/.bashrc
Add this to end of file:
# Show git branch name
force_color_prompt=yes
color_prompt=yes
parse_git_branch() {
git branch 2> /dev/null | sed -e '/^[^*]/d' -e 's/* \(.*\)/(\1)/'
}
if [ "$color_prompt" = yes ]; then
PS1='${debian_chroot:+($debian_chroot)}\[\033[01;32m\]\u@\h\[\033[00m\]:\[\033[01;34m\]\w\[\033[01;31m\]$(parse_git_branch)\[\033[00m\]\$ '
else
PS1='${debian_chroot:+($debian_chroot)}\u@\h:\w$(parse_git_branch)\$ '
fi
unset color_prompt force_color_prompt
Force bash to update: source ~/.bashrc
Esse programa permite configurar algumas coisas que não tem nas configurações do Ubuntu
sudo apt install gnome-tweaks
- JetBrains Mono: A free and open source typeface for developers
- Fira Code: monospaced font with programming ligatures
- Baixe e instale a fonte escolhida no seu computador (basta abrir e clicar em instalar)
- Abra o Visual Studio Code
- Ctrl + Shift + P > Open Settings (JSON)
- Add
"editor.fontFamily": "JetBrains Mono",
ou"editor.fontFamily": "Fira Code",
- Add
"editor.fontLigatures": true,
- Reinicie o VS Code
NPM Best Pratices -> https://devcenter.heroku.com/articles/node-best-practices
npm config set save=true
Adiciona automaticamente --save
em todo npm install
npm config set save-exact=true
A cada npm install
ele trava a versão instalada
git reset --soft HEAD@{1}