Skip to content

Instantly share code, notes, and snippets.

@tiagobbraga
Last active February 7, 2022 14:33
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save tiagobbraga/84d2f5a43774e0297b4506aa1496e515 to your computer and use it in GitHub Desktop.
Save tiagobbraga/84d2f5a43774e0297b4506aa1496e515 to your computer and use it in GitHub Desktop.
git-commands
Git clone com específico branch:
$ git clone --branch <branchname> <remote-repo-url>
Remover um arquivo específico
$ git rm --cached <filename>
Remover todos os arquivos gitignore
$ git rm -r --cached .
$ git add .
$ git commit -m "MESSAGE"
Novo branch com untracked files
$ git add -A
$ git stash
$ git checkout <branch>
$ git stash pop
Trocar url remote
$ git remote set-url origin <new_url_remote>
Criar tag
$ git tag -a v1.0 -m "MESSAGE"
Deletar tag local
$ git tag -d <tag_name>
Deletar tag remota
$ git push --delete origin <tag_name>
Compartilhar tag
$ git push origin v1.0
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment