Upgrade to Pro
— share decks privately, control downloads, hide ads and more …
Speaker Deck
Features
Speaker Deck
PRO
Sign in
Sign up for free
Search
Search
Git com o pé direito
Search
Sponsored
·
Your Podcast. Everywhere. Effortlessly.
Share. Educate. Inspire. Entertain. You do you. We'll handle the rest.
→
Rodrigo Machado
August 30, 2014
Programming
1
130
Git com o pé direito
Palestra sobre git no FrontInterior 2014
Rodrigo Machado
August 30, 2014
Tweet
Share
More Decks by Rodrigo Machado
See All by Rodrigo Machado
Integração / Entrega Contínua
rcmachado
0
81
De Objective-C para Swift: Bibliotecas
rcmachado
0
110
Automação com Fabric
rcmachado
1
150
Other Decks in Programming
See All in Programming
Lambda のコードストレージ容量に気をつけましょう
tattwan718
0
130
OSSとなったswift-buildで Xcodeのビルドを差し替えられるため 自分でXcodeを直せる時代になっている ダイアモンド問題編
yimajo
3
620
AIエージェント、”どう作るか”で差は出るか? / AI Agents: Does the "How" Make a Difference?
rkaga
4
2k
15年続くIoTサービスのSREエンジニアが挑む分散トレーシング導入
melonps
2
200
MDN Web Docs に日本語翻訳でコントリビュート
ohmori_yusuke
0
650
AIによるイベントストーミング図からのコード生成 / AI-powered code generation from Event Storming diagrams
nrslib
2
1.9k
【卒業研究】会話ログ分析によるユーザーごとの関心に応じた話題提案手法
momok47
0
200
余白を設計しフロントエンド開発を 加速させる
tsukuha
7
2.1k
高速開発のためのコード整理術
sutetotanuki
1
400
humanlayerのブログから学ぶ、良いCLAUDE.mdの書き方
tsukamoto1783
0
190
Automatic Grammar Agreementと Markdown Extended Attributes について
kishikawakatsumi
0
190
Spinner 軸ズレ現象を調べたらレンダリング深淵に飲まれた #レバテックMeetup
bengo4com
1
230
Featured
See All Featured
Color Theory Basics | Prateek | Gurzu
gurzu
0
200
Building an army of robots
kneath
306
46k
Art, The Web, and Tiny UX
lynnandtonic
304
21k
Marketing to machines
jonoalderson
1
4.6k
AI in Enterprises - Java and Open Source to the Rescue
ivargrimstad
0
1.1k
Claude Code のすすめ
schroneko
67
210k
Digital Projects Gone Horribly Wrong (And the UX Pros Who Still Save the Day) - Dean Schuster
uxyall
0
350
Ruling the World: When Life Gets Gamed
codingconduct
0
140
Bridging the Design Gap: How Collaborative Modelling removes blockers to flow between stakeholders and teams @FastFlow conf
baasie
0
450
AI: The stuff that nobody shows you
jnunemaker
PRO
2
250
Between Models and Reality
mayunak
1
190
実際に使うSQLの書き方 徹底解説 / pgcon21j-tutorial
soudai
PRO
196
71k
Transcript
Git com o pé direito Ou como parar de ter
10+ cópias do mesmo projeto espalhadas pelo computador
Sobre mim Desenvolvedor sênior "full stack” no Queremos! / WeDemand
PHP, Python, MySQL, MongoDB, AWS ~ 10 anos de estrada
Sobre o git
História Linus Torvalds (criador do Linux) em 2005 Criado para
substituir um software proprietário (BitKeeper) Curiosidade: o linux tem ~6000 desenvolvedores - então o git é robusto!
Atenção! !=
Esse é o git
Vantagens Permite que você trabalhe numa funcionalidade nova sem quebrar
o que já está pronto Essencial se existe mais de 1 pessoa trabalhando no projeto
Utilizado na maioria das empresas de desenvolvimento
Começando com o git Onde colocar meu repositório?
GitHub https://github.com/
BitBucket https://bitbucket.org/
Comandos que importam
Obtendo o repositório
O que tem pra comitar?
O que estou comitando?
Adicionando arquivos
Commit
Baixar (e aplicar) commits
Mandar commits pro servidor
– http://git-scm.com/book/en/Git-Branching-What-a-Branch-Is “Um branch no Git é simplesmente um ponteiro
para um dos commits do repositório.” Branch
Criar um branch
Quais são os meus branches?
Mudar para um branch
git log
Avançando um pouco
git alias $ git alias st status
git alias
git alias $ git alias glog "log —all --pretty='format: %d
%Cgreen%h%Creset %an - %s' --graph"
git alias
Merge vs Rebase
Merge vs Rebase Merge • Mais simples • Histórico "poluído"
• O git decide como juntar seu código Rebase • Maior controle na resolução de conflitos • Histórico mais “limpo” • Mais complexo
Text http://stackoverflow.com/questions/11671668/combine-several- commits-and-merging-as-one-commit-into-other-branches
Text http://kevin.deldycke.com/2011/02/moving-git- subtree-repository/
git reflog Armazena todas as ações executadas: Commits Novos branches
Merges etc.
git reflog
git reflog
GUIs Simplificando a vida
GitHub GUI https://mac.github.com/ https://windows.github.com
Tower http://www.git-tower.com
Source Tree http://www.sourcetreeapp.com
Dicas
Commits
Text http://xkcd.com/1296/
Cuidado com ****** Evite commitar “segredos” no repositório Segredos: senhas,
chaves de acesso, etc.
Workflow da equipe Defina um workflow da equipe (ex. merge
vs rebase) Padronização de nomes de branches (ex. issue #) Para equipes maiores: git-flow http://nvie.com/posts/a- successful-git-branching-model/ Cuidado: não crie regras demais :)
Text Branches são leves http://i.imgur.com/seDixfY.jpg
Master "entregável" Mantenha o master “entregável" Evite commitar coisas pela
metade
Text Pratique! https://try.github.com/
Links http://nvie.com/posts/a-successful-git-branching- model/ https://marklodato.github.io/visual-git-guide/index- en.html https://try.github.com/ http://www.git-tower.com/blog/git-cheat-sheet-detail- pt/
Obrigado! @rcmachado rcmachado https://speakerdeck.com/rcmachado