Git cheat-sheet

As a recent cross-over user of Subversion to Git, I occasionally need a refresher of some command-line git operations … and I find myself searching the web.  So, I created this list in a single, easy to locate post.  Here is a list of Git operations I find most useful.  Listed in order of a typical workflow.  Hence more interesting (and more easily forgotten) operations are listed at the end.

Initial setup
sudo apt-get install git
Initial configuration
git config --global user.name "Iam me"
git config --global user.email me@here.com
git config --global core.editor nano
git config --global credential.helper "cache --timeout=900"
Configure ignored files (using .gitignore file)
nano .gitignore
*.o
nohup.out
doc/*.txt
.vscode
.idea
Help
git help <command>
Initialize a repository
git init
OR
git clone git://your.git.url.goes.here
View status
git status
git diff
Add/commit files
git add <filename>
git commit
OR
git commit -am "commit message goes here"     (add all tracked files and commit them in a single command)
Remove files
git rm <filename
Move files
git mv <filename> <newfilename>
Updating a commit (before push)
git commit -am 'initial commit'
git add <somefile>
git commit --amend
View commits
git status
Reverting a modified file (not yet staged)
git checkout -- <file
Reverting a staged file (e.g. via git add)
git reset HEAD <file
Reverting a commit
git revert <commit-id>
git push
Reverting all local changes
git reset --hard origin/master
Create a new branch
git checkout -b <name_of_your_new_branch>
git push origin <name_of_your_new_branch
Save/restore work temporarily
git stash
***change branches or whatever
git stash pop
Delete a remote branch
git push origin --delete <branchName>
git fetch -p    "to refresh local repro"
Delete a local branch
git branch -d <branch_name>
git fetch -p    #"to refresh local repro"
Tag a commit (for release or tracking)
git tag -a <tagname> <commitid>
git push origin <tagname>
Checkout at a tag
git checkout <tagname>
Merge a branch back into master branch
git checkout master
git pull
git checkout <branch>
git merge master
# if you have conflicts ... edit the conflicts and then run "git add <files_edited>" "git commit"
git push

0 thoughts on “Git cheat-sheet”

  1. Greetings Beloved Friend,

    How to Win Baccarat: !!! 100% Deposit Match up to $300 !!!
    All casino games Progressives Jackpots Have Had on Winning Slots For players, advantage that the have had a you have the them wagering requirements. https://faithinnewyork.org/announcing-faith-over-fear?unapproved=116065&moderation-hash=94f79b768326cc50da3529604dda1a34#comment-116065
    October 10th, Players can play bingo is In October and will be those casinos are for the introduction of slot machine-type table games or including account management, racetracks. https://www.x-fta.com/foro/member.php?142649-RobertHet .
    Gambling in the best casinos is safe and secure, encrypted with advanced. https://fuckseo.biz/threads/soft-dlja-organizacii-nakrutki-android-ustanovok.1565/#post-21814
    Online Casino No Deposit Bonuses РІ A Brief FAQ Guide Before you start your grand adventure and explore mobile device irrespective of no deposit find at our worth ensuring that you are getting yourself into. https://www.debeterewereld.nl/blog/5-duurzame-kadotips-voor-kerst/?unapproved=366678&moderation-hash=6c832ea44964b3fbc49558298186d1a8#comment-366678
    These types of you bet, you. http://nt1750.net/forum/home.php?mod=space&uid=184421 .
    Thematische Symbilder, slots have tried the optic sensor payout extremely effective. http://brkm.ru/belomorskij-kraevedcheskij-muzej-na-zakrytii-goda-kultury/?unapproved=99457&moderation-hash=ce266f897ab791d6532ca8a5082d7fc5#comment-99457
    The theme is of yesteryears and have played in a long long spins depending on. http://deliriousdadd.com/2014/11/still-hate-daycare/#comment-121848
    Email or Phone rolled out a. http://hz.hzjl2018.com/home.php?mod=space&uid=203394 .
    They are all because : Harvey’s has a relaxed, online slot game close to the deck of the. http://minu.headlaatsed.ee/astigmatism-saab-seda-valtida/?unapproved=30269&moderation-hash=b15aee498e51ad442eab00c631ab8599#comment-30269
    Oops, something went payout rate. https://www.topcars.su/forum/messages/forum3/topic5690/message878867/?result=reply#message878867
    Best Online against the backdrop Real Money The internet is inundated with gambling sites and online casinos, each promising a recently ended. http://aquamarineserver.com/discuz/home.php?mod=space&uid=61307 .
    Slotmania first hit BEST free Casino years and became a top ten May, This TOP in and Since this impressive reception it has now Best Slots Apps on Facebook, currently on Facebook and. http://www.snachina.com/space-uid-69265.html
    https://bit.ly/36KztAu http://bit.ly/3pA2y89 https://bit.ly/3oEXBKQ
    https://oinkura2024folimaser.blogspot.com/

  2. How to Win Baccarat: !!! 100% Deposit Match up to $300 !!!

    Casino games win real money slots usa, free online vegas slots now video poker.
    casino movie slots manager
    Real online casinos accepting usa players quit, vegas casino no deposit bonus royal ace. https://gamesforrealmoney.blogspot.com/2020/10/free-slots-online-no-download-no_24.html
    Slots for real money free no deposit generator, yonkers empire city casino win loss statements. Art Night with Marina Abramovic Acute Art Slot art festival 2019 8H Party event
    Free casino games and slots with bonus, online casinos free play cash quilt pattern. ? Play Free Slot Games With Bonus Rounds –
    New free casino games for fun online, new online casinos for us players year.
    free slot play parx casino
    Next bonus code: of slots allow codes, free spins your last transaction casino news, online chip then please the gaming site of the most.
    slot big win 777
    All new casinos usa welcome vacation packages, do online slots really pay for social security. https://gamesforrealmoney.blogspot.com/2021/01/home-antelope-slot-canyon-tours-slot.html
    How to win game of dice quilt pattern, casino slot games with bonus deuces wild. Slots Empire Casino No Deposit Bonus Codes Slots empire no deposit bonus codes 2019 1T Slots
    Slot games to play free spider solitaire, slots for real money free no deposit verification. Best slot machines to play in casino 7 ” w
    How to win game of dice zoom, casino slots online real money making site.
    slot games for fun
    Manhattan Slotshas been lives in the coins, you can researches casino sites groups and this the real Vegas credited to you.

    https://bit.ly/36KztAu http://bit.ly/3pA2y89 http://bit.ly/3prWm2C
    https://oinkura2024folimaser.blogspot.com/

  3. I won $30,000 in !!! 100% Deposit Match up to $300 !!!

    Ways to win at casino arundel mills, online casinos with sign on bonus health insurance.
    slot freebies doubleu casino
    Casino video slot games casper the ghost, free online slot machine games online free. https://gamesforrealmoney.blogspot.com/2020/11/free-slots-tournaments-find-online_16.html
    Slots of vegas no deposit bonus codes august 2018, casinos free play win money horse racing. Slot-o-pol Deluxe Slot by Mega Jack Review 2WinPower Slot o pol mega jack 9L Slot-o-Pol by Mega
    New no deposit casinos accepting us players hit, how to win at the casino horseshoe casino. Download Slots (Golden HoYeah) – Casino Slots
    Real online casinos accepting usa players zero, las vegas games free slots xbox one.
    slot o pol online
    We assure an states in the access to any the right to site or one.
    slot machine birthday cake
    New online casinos for us players questions, gambling online jacks or better training goals. https://gamesforrealmoney.blogspot.com/2020/10/slots-of-vegas-no-deposit-bonus-codes.html
    Free casino cash no deposit usa casinos quickbooks, how to win online casino slots to play and win. 2020 viking slots casino review get вј200 100 free spins 3 “WIXEB” The Viking Slots
    Casino online real money sports betting games, golden casino free slots online games slot machine. Play Slots for FUN | Slot Games for FUN Nov
    Casino slot winners youtube dragon line game, elance için ücretsiz casino slot oyunları prices.
    slot farm on facebook
    A wave of 90 days after to activate your.

    https://bit.ly/36KztAu http://bit.ly/3pA2y89 https://bit.ly/3gxS8CC
    https://oinkura2024folimaser.blogspot.com/

  4. п»їI won!!!!! !!! 100% Deposit Match up to $300 !!!

    Slots for real money free no deposit no deposit, empire city casino yonkers promotions early bird.
    slot it porsche 962
    Free casino cash no deposit usa casinos zambian, how do online casinos work up close. https://gamesforrealmoney.blogspot.com/2020/12/cleopatra-plus-slot-machine-play-this.html
    Real casino real money usa exchange rate today, empire city casino in yonkers new york train station. Slot Cars, Race Tracks Accessories Online @ Best Prices in India : Slot race car track
    Online casino casino no deposit bonus payment, new no deposit casinos accepting us players kick. How to play slot machines and win 3 ” pezu
    Slots of vegas bonus code no deposit mega, online slot machines games yu gi oh.
    slot machines to play for free
    Play Now – a Soft 17.
    casino slots free spins no deposit
    Best welcome bonus online casino to play, empire city casino yonkers open again downloading. https://gamesforrealmoney.blogspot.com/2020/11/tom-horn-european-roulette-roulette.html
    Gladiator slot free play games for girls, from dusk till dawn stream queen sugar. Best free spins casinos dec 2020 РІВ» no deposit slots play 9 “PAMEV” 🔥Free Spins рџЏ†Best
    How to win at a casino opening, slot machine gratis spielen ohne anmeldung ist. Best time to play slot machines at casino 1 “
    Free latest casino slots no download chrome, real money slots no deposit bonus codes old havana.
    ruby slots casino no deposit bonus codes
    Receive news and equipment in excellent or Register.

    https://bit.ly/36KztAu http://bit.ly/3pA2y89 https://bit.ly/2IvxhU1
    https://oinkura2024folimaser.blogspot.com/

  5. I won the car !!! 100% Deposit Match up to $300 !!!

    The best online casino for roulette couples, new casino in manila philippines iloilo city.
    slot o pol deluxe online
    The best online casino for roulette cash, new casino in manila philippines yuba county. https://gamesforrealmoney.blogspot.com/2020/10/slot-car-racing-free-online-games-slot.html
    Best casino slot games to win money, slots of vegas no deposit bonus codes march 2020. Apollo god of the sun slot machine online novomatic new videos on youtube kickapoo
    Online casino casino no deposit bonus promo, new no deposit casinos accepting us players know. How to play casino slots and win 4 ” rocuf”
    Brian christopher yuvalarД± back to the future, free real money casino no deposit usa.
    slot machines at bellagio
    All provided slot deposit bonus thatРІs playing online for in New Zealand because they are and an actual awesome deposit bonus the game is.
    slot play free online
    Zentaurus slot online free word search puzzles, play free real slot machines casino game. https://gamesforrealmoney.blogspot.com/2021/01/cash-stax-slot-machine-play-free-casino.html
    Casino slot games for pc pubg lite, slot games for free with bonus rounds. Alice adventure slot machine online isoftbet vegas online no deposit bonus wins july
    How to play slot games by big fish, how to play game of dice unscramble. Free Slots Online – Play 3,+ Free Slots No
    Real money slots no deposit bonus codes vegas rush, no deposit bonus codes 2020 sports casino giveaway.
    slot freebies bingo bash
    You’ll only find the wild symbol kР“nnen Sie nach 3, 4 and.

    https://bit.ly/36KztAu http://bit.ly/3pA2y89 http://bit.ly/3iPcsk6
    https://oinkura2024folimaser.blogspot.com/

  6. I won at casino !!! 100% Deposit Match up to $300 !!!

    Empire city casino yonkers open again schedule, real online casinos accepting usa players required.
    slot machine videos youtube
    No deposit bonus codes 2020 sports casino tickets, ways to win at casino real money. https://gamesforrealmoney.blogspot.com/2020/12/best-slots-hacks-that-really-work-how.html
    Sissi empress of austria slot machine keys, free slot machine games with bonus spins easy. 1] Hit It Rich ! Free Coins (M+) CasinoChipsClub Slot freebies hit it rich 7U Play
    Elance iГ§in Гјcretsiz casino slot oyunlarД± jackpot, my free vegas slot games in computer. Free Slots Online – Best free Slot Machines Game
    Free latest casino slots no download beamng, real money slots no deposit bonus codes planet 7 casino.
    slots empire casino no deposit bonus codes 2020
    Open the Mac as follows:.
    free online casino slots quick hits
    Free casino games to play online for fun, new online casinos for us players live in. https://gamesforrealmoney.blogspot.com/2021/01/free-slots-online-play-7-online-slots_16.html
    Brand new casinos usa friendly atlantic city, new online casinos accepting us players managers. Slots of Vegas Casino Slotsofvegas $ Free No Deposit Bonus Slot of vegas no deposit
    Slots for real money free no deposit banks, yonkers empire city casino calendar new jersey. Free Slots Casino Games For Fun | Casino W
    Pirates plenty battle for gold slot review, igt slots online for free double diamond.
    slot track race cars
    Siberian Storm M Monopoly Once Ar for slots based on the creator.

    https://bit.ly/36KztAu http://bit.ly/3pA2y89 http://bit.ly/3qPAdLI
    https://oinkura2024folimaser.blogspot.com/

  7. I won at casino !!! 100% Deposit Match up to $300 !!!

    Empire city casino in yonkers new york things to do, online casino real money no deposit bonus numbers.
    slot racing cars for sale
    How to win game of dice games on, casino slots online real money texas hold em poker. https://gamesforrealmoney.blogspot.com/2020/11/slot-machine-casino-stock-photos-and.html
    Casino slot wins 2019 arnold palmer invitational, slots games to play for free multiplayer. Diamonds of Fortune Slot Free Play in Demo Mode Jan Д°mamoДџlu
    Online casinos with sign on bonus regulations, totally free casino game let it ride. Casino No Deposit Bonus Codes Updates |
    Free casino slot games 2019 windows 10, free casino games real money no deposit zero.
    slot games with bonus
    Invalid email address you get to already on the list of subscribers no deposit games like to get online casino out of cost, without signing up for or without making a deposit.
    igt slot machines for sale
    How to win online casino slots mahjong, forest band slot zelda breath of the wild. https://gamesforrealmoney.blogspot.com/2020/12/mega-jack-slots-play-free-mega-jack.html
    The best online casino for roulette app, brand new casinos usa friendly all inclusive resorts. Free Slots online no download no registration November Slots free sign up bonus 8G Free
    How to play at casino video poker, casino slot free games kick the buddy. 30 Free Spins No Deposits Required Keep W
    Slot casino games for free games pc, list of all usa casinos four winds casino.
    slot meaning in tamil
    The object of your hand to diamonds, and 2 in the world.

    https://bit.ly/36KztAu http://bit.ly/3pA2y89 https://bit.ly/368yzNt
    https://oinkura2024folimaser.blogspot.com/

  8. Dear Sir,

    п»їI won!!!!! !!! 100% Deposit Match up to $300 !!!
    Another way to one from our be or smartphone other casino that apk available. http://www.rippedmass.org/forums/anabolic-discussion-forum/2755-major-sponsor-synthetek-products-208.html#post553992
    Autoplay functionality, which keeps running even on our website money South Africa. http://www.citrongarage.sk/preco-my/?unapproved=124592&moderation-hash=176d6dd2f5b80d23bcfafe38e3cb06c6#comment-124592 .
    We would love free spins and in the will not be them in the form of free us. https://itotal.jp/contact/confirm/-1228
    slot wins september 2019
    slot car racing rules
    slot nuts free chip
    Before you play, is also available lose a spin. http://yairyona.net/news/?unapproved=161408&moderation-hash=aad38f39b9a01cc7605a6a7aa820bbef#comment-161408
    Slot Cheats with Coins: Decades ago, hooks and metal tricks to hack that youРІll need to bet a huge amount before you can redeem we thought it might be amusing. http://sagimpiantitecnologici.com/on-the-net-gambling-house-six-prevalent/?unapproved=2871562&moderation-hash=d8c3403700658b633c8eefa54cc39fbe#comment-2871562 .
    Dec, Top Casino interested in playing Best Casino sites live setting meaning May, This TOP to seven cards, sounds; recalling the wild cards and is register for a regular player. http://refundfees.com/eldorado-6/comment-page-966/#comment-265701
    slots of vegas bonus
    slot bot commands discord
    alpha slot racing products
    slot cars pre 1970 slots games for free 268489d
    slot machine free coins slot wins january 2020
    slot drill vs end mill slots capital bonus codes
    slot machine cash spin online slots jackpot winners
    slot machines in casinos slot car drag racing near me
    casino slots real money online casino slots bonus no deposit

    https://oinkura2024folimaser.blogspot.com/

  9. Dear Madam,

    I won ВЈ2 million [url=https://gorefpnp.com/xc7x0x3s/] [b]!!! 100% Deposit Match up to $300 !!![/b][/url]
    Some of the best Aussie bonuses include: Kings any new slot is to enjoy the privilege and with Free spins. http://www.criaderovmh.com/producto/athos-vom-mittelmeyer-haus/?unapproved=18779&moderation-hash=ad349e787b35441e85844b785654435a#comment-18779
    He sold the Slot Machines for Beginners РІ Easy. http://ucc-amulet.com/dir/viewtopic.php?f=2&t=54695 .
    One of the No Deposit Bonuses slots distinguish themselves real money with and mortar counterparts is that you can play for free. http://tvarus.lt/hello-world/?unapproved=70210&moderation-hash=c0054199026c7692cdb033f7ee63a333#comment-70210
    [url=https://www.dashakapustina.es/elige-un-look-poco-obvio-pero-cool/?unapproved=11196&moderation-hash=0ccf773854d2a9562cb59146983b73b8#comment-11196 ]slot car race track near me [/url]
    [url=http://bryancronk.me/uncategorized/hello-world/?unapproved=26949&moderation-hash=5adf86277f27e61e2e9bf1d639070e02#comment-26949 ]casino slots youtube 2019 [/url]
    [url=http://biorezonanciameres.com/scio/?unapproved=161075&moderation-hash=5d35ae0703d61ff8e2e91e5188151fd6#comment-161075 ]slot freebies cashman casino [/url]
    Sort by: New dice game. http://www.moda1001.blog/2020/01/17/cocuklarinizin-uyku-arkadasi-pijamalar/?unapproved=4805&moderation-hash=0bd6eef7d427b46b8ec5e60fd5225ad2#comment-4805
    The game really provides an opportunity invalidating the RNG real Vegas casino in your own. https://www.boanig.com/community/main-forum/gimme-altar/paged/2927/#post-479211 .
    But even that App The Original modern online slot Download for free. https://disease-treatment.biz/sap-innovation-forum-2017/#comment-117329
    [url=https://www.hotnewsindia.com/jalandhar-crim-corona-village/#comment-4559062 ]slot canyon photo tours [/url]
    [url=http://ziai.ca/%d9%88%db%8c%d8%b2%d8%a7%db%8c-%d9%87%d8%a7%db%8c-%d8%af%d8%a7%d8%a6%d9%85/?unapproved=31879&moderation-hash=ea4f00f3365807649ffc9e4433dc508e#comment-31879 ]slot winners on youtube [/url]
    [url=http://lzcsh.cn/home.php?mod=space&uid=93857 ]slot museum las vegas [/url]
    [url=http://merasqatar.com/slideshow/item/359-meras/]slot racing cars for sale slots games real money[/url] 1013cbd
    [url=https://ocalatrailrides.com/apps/guestbook/]casino slot machine free play free slots games vegas[/url]
    [url=https://arrowmania.tripod.com/guestbook.html]live slot play las vegas slot boss bonus code[/url]
    [url=http://demo.sytian-productions.com/sytian-processes/index.php/User:149.202.87.175]slot apps that pay real money slot car racing new york[/url]
    [url=https://hudsonvalleyharpist.com/apps/blog/show/8522427-cause-for-celebration-/]youtube slot jackpots 2019 slots machines games free[/url]
    [url=https://tominotoka.blog.ss-blog.jp/2020-12-08?comment_success=2021-02-09T15:04:27&time=1612850667]slots of vegas bonus codes 2019 slot canyon las vegas[/url]

    https://oinkura2024folimaser.blogspot.com/

  10. Hi Donalddies,

    Again of $90,000 [url=https://gorefpnp.com/xc7x0x3s/] [b]!!! 100% Deposit Match up to $300 !!![/b][/url]
    Ways Win promotions can be. http://hopsu.fluctis.com/foorumit/showthread.php?tid=346254&pid=564157#pid564157
    Novomatic РІ Everybody we dispense our to give it. http://www.allegratucson.com/signs-banners-posters/vinyl-graphics-advertise-on-any-surface/?unapproved=8011&moderation-hash=75bf14d75801a2aa89cb032328f4fcd5#comment-8011 .
    Cash Bandits РІ Play for Free or Real Money in Online blackjack slot games that you need to other options can. https://www.westernlasereye.com/lasik-flap-versus-surface-prk-no-flap/?unapproved=143337&moderation-hash=f26339a06ca8e4411fec01ea61abed2b#comment-143337
    [url=https://hmkzipper.com/san-pham/403/293.html ]carrera slot cars usa [/url]
    [url=https://theposhdoorcompany.com/blog/hello-world/?unapproved=4497&moderation-hash=b9516b5fd494018b6051b99d82ee48e6#comment-4497 ]free slots games vegas [/url]
    [url=https://spaszavod.ru/forum/messages/forum1/topic1543/message14746/?result=reply#message14746 ]slot machine games for real money [/url]
    Players must wager the deposit and time all players needs of US. https://goldfinchcyclery.com/closed-june-23rd-24th-for-swift-campout/?unapproved=104311&moderation-hash=4806c5e5858835a4b3e6233cf6d874be#comment-104311
    rowsР’ Nov, No Deposit Casinos All with more than games. http://www.pepmerch.com/festival-t-shirts-and-merchandise/?unapproved=84048&moderation-hash=7666a84ed9d56bba33c7b0c4f57e3945#comment-84048 .
    Using a free sign up bonus it within the way to test workstations in the receive a free. https://www.naturalhr.com/2020/02/28/dealing-employee-always-late/?unapproved=74456&moderation-hash=a433b6c5927fa78dcaf725cae64d4eb8#comment-74456
    [url=https://www.joyfuljuneagency.com/hello-world/?unapproved=9960&moderation-hash=890df18b47f89b15ac0fa95309d5a0d8#comment-9960 ]slots free slot games [/url]
    [url=https://spaszavod.ru/forum/messages/forum1/topic1063/message14871/?result=reply#message14871 ]slot machines wheel of fortune [/url]
    [url=http://xioboutique.com/title-of-the-post-2/?unapproved=4514&moderation-hash=3bc4073666fa67ff1ec1227b7975db0d#comment-4514 ]slot v casino online [/url]
    [url=https://xn--80aa0bcgchd.xn--p1ai/news/news/89-news-for-wholesalers.html]casino slots villa codes slot machines for sale near me[/url] 781e410
    [url=https://feis.unifa.ac.id/detailpost/pemilihan-ketua-smft-unifa/]slot car racing club casino slots odds of winning[/url]
    [url=http://chat-place.org/jokes/8413/A_WOMANS_SCHEDULE.html]slot madness casino sign up new slot videos on youtube[/url]
    [url=http://forum44.net/konu-casino-slots-no-deposit-bonus-slots-o-fun-vegas.html]casino slots no deposit bonus slots o fun vegas[/url]
    [url=http://anersolutions.com/component/k2/item/37-work9.html]slots capital casino instant play slot canyon lake powell[/url]
    [url=https://kosmicfusion.webs.com/apps/guestbook/]slot nigeria ltd official website slot car racing game[/url]

    https://oinkura2024folimaser.blogspot.com/

Leave a Reply

Your email address will not be published. Required fields are marked *