forked from ksylor/ohshitgit
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
* Added afrikaans language * appended to afrikaans language
- Loading branch information
1 parent
b13ba54
commit 8af4de3
Showing
32 changed files
with
433 additions
and
3 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,6 @@ | ||
--- | ||
layout: layouts/page.njk | ||
locale: af | ||
contentType: noswears | ||
title: Dangit, Git!?! | ||
--- |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,5 @@ | ||
<footer> | ||
<small class="contact">Wat is jou Dang it, git oomblik? Deel dit met my!</small> | ||
<small class="twitter">{% twitter_link "ksylor" %}</small> | ||
<small class="copyright">{{site.copyright | safe}}</small> | ||
</footer> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,3 @@ | ||
<p>Git is moeilik: om 'n gemors te maak is maklikik, maar om uit te vind hoe om dit reg te maak is onmoontlik. Git dokumentasie het 'n probleem waar jy nie kan soek hoe om jouself uit die gemors te kry nie, <em>behalwe as jy klaar die naam ken wat van die ding wat jy oor moet weet</em> om die probleem te kan oplos.</p> | ||
|
||
<p>So hier is 'n paar slegte situasies waarin ek myself bevind het en hoe ek op die ou ent van die dag myself daaruit gekry het <em>in eenvoudige afrikaans</em>.</p> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1 @@ | ||
<p>*Vrywaring: Hierdie webwerf is nie bedoel as 'n volledige verwysing nie. En ja, daar is ander maniere om dieselfde dinge met meer teoretiese suiwerheid of wat ook al, maar ek het hierdie stappe bewerkstellig deur middel van baie probeer, vloekery en tafels omgooi. Ek het hierdie mal idee gehad om dit met 'n gesonde dosis van lewendigheid te deel. Vat dit soos jy wil!</p> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,4 @@ | ||
<p>Baie dankie aan almal wat vrywillig die webwerf in nuwe tale vertaal het, julle is fantasties! | ||
{% include "partials/collaborator-list.njk" %}. Met additionele hulp van {% include "partials/otherhelper-list.njk" %}</p> | ||
|
||
<p>As jy wil help om 'n vertaling in jou taal by te voeg, dien 'n pull request in by {% github_link %}</p> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,18 @@ | ||
--- | ||
tags: tip | ||
title: Dangit, ek het iets groots verkeerd gedoen, vertel asseblief vir my git het 'n magiese tydmasjien!?! | ||
id: magiese-tydmasjien | ||
order: 1 | ||
--- | ||
|
||
```git | ||
git reflog | ||
# hier sal jy 'n lys sien van alles | ||
# wat jy in git gedoen het, in alle takke! | ||
# elke een het 'n indeks HEAD@{indeks} | ||
# vind die een net voordat jy alles gebreek het | ||
git reset HEAD@{index} | ||
# magiese tydmasjien | ||
``` | ||
|
||
Jy kan dit gebruik om dinge terug te kry wat jy per ongeluk geskrap het, of net goed te verwyder wat jy probeer het en die repo daarmee gebreek het, of om te herstel ná 'n slegte merge, of net om terug te gaan na 'n tyd wanneer dinge werklik gewerk het. Ek gebruik BAIE 'reflog'. Massiewe knik van die hoed vir die baie baie baie baie mense wat voorgestel het om dit by te voeg! |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,18 @@ | ||
--- | ||
tags: tip | ||
title: Dangit, Ek het commit en onmiddelik besef ek moet een klein verandering maak! | ||
id: wysig-die-laaste-commit | ||
order: 2 | ||
--- | ||
|
||
```git | ||
# maak jou verandering | ||
git add . # of voef individuele leêrs by | ||
git commit --amend --no-edit | ||
# nou bevat jou laaste commit die verandering! | ||
# WAARSKUWING: moet nooit openbare commits wysig nie | ||
``` | ||
|
||
Dit gebeur gewoonlik met my as ek commit en dan toetse/linters uitvoer... en dan sien jy dat jy vergeet het om 'n spasie voor die isgelykaanteken te sit. Jy kan ook die verandering maak as 'n nuwe commit en dan 'n `rebase -i` doen om albei saam te smelt, maar hierdie is baie vinniger. | ||
|
||
*Waarskuwing: Jy moet nooit commits wat tot gestoot om 'n openbare/gedeel tak wysig! Wysig slegs commits wat slegs in jou plaaslike kopie voorkom, of anders gaan dit na slegte tye lei.* |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,12 @@ | ||
--- | ||
tags: tip | ||
title: Dangit, ek moet die boodskap op my laaste commit verander! | ||
id: verander-commit-boodskap | ||
order: 3 | ||
--- | ||
```git | ||
git commit --amend | ||
# volg die aanwysings om die commit boodskap te verander | ||
``` | ||
|
||
Simpel vereistes vir commit boodskappe. |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,19 @@ | ||
--- | ||
tags: tip | ||
title: Dangit, ek het perongeluk iets commit aan die meester tak wat op 'n splinter nuwe tak moes gewees het! | ||
id: perongelukke-meester-commit | ||
order: 4 | ||
--- | ||
|
||
```git | ||
# maak 'n splinter nuwe tak vanuit die huidige | ||
# toestand can die meester tak | ||
git branch nuwe-tak-naam | ||
# verwyder die commit van die meester tak | ||
git reset HEAD~ --hard | ||
git checkout nuwe-tak-naam | ||
# jou commit leef nou in die nuwe tak :) | ||
``` | ||
|
||
|
||
Nota: hierdie sal nie werk as jy klaar die verandering aan 'n openbare/publieke tak gestoot het nie, en as jy ander dinge eers probeer het sal jy dalk dinge moet herstel met `git reset HEAD@{hoeveelheid-commits-terug}` in plaas daarvan om van `HEAD~` gebruik te maak. Dit lei tot oneindige hartseer. Baie baie baie mense het ook 'n fantastiese manier voorgestel wat hierdie baie korter maak wat ek nie self geken het nie. 'n Groot dankie aan almal. |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,30 @@ | ||
--- | ||
tags: tip | ||
title: Dangit, ek het perongeluk na die verkeerde tak commit! | ||
id: perongelukke-commit-na-verkeerde-tak | ||
order: 5 | ||
--- | ||
|
||
```git | ||
# maak die laaste opdrag ongedaan, | ||
# maar laat die wysigings beskikbaar | ||
git reset HEAD~ --soft | ||
git stash | ||
# skuif na die regte tak | ||
git checkout naam-van-regte-tak | ||
git stash pop | ||
git add . # of voef individuele leêrs by | ||
git commit -m "jou boodskap hier" | ||
# nou is jou wysigings op die regte tak | ||
``` | ||
|
||
Baie mense het voorgestel om `cherry-pick` vir die geval ook te gebruik. Gebruik maar wat beste vir jou werk! | ||
|
||
```git | ||
git checkout naam-van-regte-tak | ||
# gryp die laaste commit na die meester tak | ||
git cherry-pick master | ||
# wis dit uit van die meester tak | ||
git checkout master | ||
git reset HEAD~ --hard | ||
``` |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,14 @@ | ||
--- | ||
tags: tip | ||
title: Dangit, ek probeer diff hardloop, maar niks gebeur nie?! | ||
id: waars-my-diff-ou | ||
order: 6 | ||
--- | ||
|
||
As jy weet dat jy wel veranderinge gemaak het, maar die 'diff' is leeg, het jy 10 teen 1 jou leêrs ge-`add` na staging en moet dus 'n speciale vlag gebruik. | ||
|
||
```git | ||
git diff --staged | ||
``` | ||
|
||
Liasseer dit onder ¯\\\_(ツ)\_/¯ (ja, ek weet dit is 'n funksie en nie 'n gogga nie, maar dis vreemd en nie voor die hand liggend nie, wanneer dit die eerste keer met jou gebeur) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,23 @@ | ||
--- | ||
tags: tip | ||
title: Dangit, Ek moet 'n commit ongedaan maak van soos 5 commits gelede! | ||
id: maak-n-commit-ongedaan | ||
order: 7 | ||
--- | ||
|
||
```git | ||
# vind die commit wat jy ongedaan moet maak | ||
git log | ||
# gebruik jou sleutelbord pyljies om op | ||
# en af in geskiedenis te beweeg | ||
# wanneer jy jou commit gevind het, stoor die hash | ||
git revert [gestoorde hash] | ||
# git sal 'n nuwe commit skep wat die ander een ongedaan maak | ||
# volg die aanwysings om die commit boodskap te wysig | ||
# of stoor en commit net | ||
``` | ||
|
||
|
||
Dit blyk dat jy nie die ou lêerinhoud in die bestaande lêer hoef op te spoor en te kopieer om die veranderinge ongedaan te maak nie! As jy 'n fout begaan het, kan jy die commit op een slag ongedaan maak met 'revert'. | ||
|
||
Jy kan ook 'n enkele lêer terugstel in plaas van 'n volledige commit! Maar natuurlik, op die ware git manier, is dit 'n heel ander stel opdragte... |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,19 @@ | ||
--- | ||
tags: tip | ||
title: Dangit, ek moet my veranderinge aan 'n leêr terugkeer! | ||
id: undo-a-file | ||
order: 8 | ||
--- | ||
|
||
```git | ||
# vind 'n hash vir 'n commit voordat die lêer verander is | ||
git log | ||
# gebruik jou sleutelbord pyljies om op | ||
# en af in geskiedenis te beweeg | ||
# wanneer jy jou commit gevind het, stoor die hash | ||
git checkout [gestoorde hash] -- path/to/file | ||
# die ou weergawe van die leêr is nou in jou indeks | ||
git commit -m "Wow, geen knip en plak om terug te keer nie" | ||
``` | ||
|
||
Toe ek hierdie uiteindelik uitgevind het was fantasties. FANTASTIES. Maar in alle erns, op watter planeet maak `checkout --` sin as die beste manier om 'n leêr terug te keer? :wys-middelfinger-vir-linus-torvalds: |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,29 @@ | ||
--- | ||
tags: tip | ||
title: Vergeet van die, ek gee op. | ||
id: vergeet-die | ||
note: this should always be the last one in the list, so setting order to 20 so I don't have to re-name/re-order it | ||
order: 20 | ||
--- | ||
|
||
```git | ||
cd .. | ||
sudo rm -r simpel-git-repo-dir | ||
git clone https://some.github.url/simpel-git-repo-dir.git | ||
cd simpel-git-repo-dir | ||
``` | ||
|
||
Dankie aan Eric V. vir die ene. Alle klagtes oor die gebruik van `sudo` in hierdie grap kan op hom gerig word. | ||
|
||
|
||
In alle erns, indien jou tak so stukkend is dat jy die toestand van jou repo moet herstel om dieselfde te wees as jou remote repo in 'n "git-goedgekeurde" manier, probeer dit. Pasop alhoewel, dit is vernietigende en onterugkeerbare aksies! | ||
|
||
```git | ||
# kry die nuutste toestand van die oorsprong | ||
git fetch origin | ||
git checkout master | ||
git reset --hard origin/master | ||
# skrap untracked leêrs and gidse | ||
git clean -d --force | ||
# herhaal checkout/reset/clean vir elke stukkende tak | ||
``` |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,6 @@ | ||
--- | ||
layout: layouts/page.njk | ||
locale: af | ||
contentType: swears | ||
title: Oh Shit, Git!?! | ||
--- |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1 @@ | ||
<aside class="notice">Hallo daar! Jy kan dieselfde inhoud sonder die gevloekery kry by <a href="{{site.url_noswears}}/{{locale}}">dangitgit.com</a></aside> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,5 @@ | ||
<footer> | ||
<small class="contact">Wat is jou Oh shit, git oomblik? Deel dit met my!</small> | ||
<small class="twitter">{% twitter_link "ohshitgit" %} {% twitter_link "ksylor" %}</small> | ||
<small class="copyright">{{site.copyright | safe}}</small> | ||
</footer> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,3 @@ | ||
<p>Git is moeilik: om 'n fokkop te maak is maklikik, maar om uit te vind hoe om dit reg te maak is fokken onmoontlik. Git dokumentasie het 'n probleem waar jy nie kan soek hoe om jouself uit die gemors te kry nie, <em>behalwe as jy klaar die naam ken wat van die ding wat jy oor moet weet</em> om die probleem te kan oplos.</p> | ||
|
||
<p>So hier is 'n paar slegte situasies waarin ek myself bevind het en hoe ek op die ou ent van die dag myself daaruit gekry het <em>in eenvoudige afrikaans</em>.</p> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1 @@ | ||
<p>*Vrywaring: Hierdie webwerf is nie bedoel as 'n volledige verwysing nie. En ja, daar is ander maniere om dieselfde dinge met meer teoretiese suiwerheid of wat ook al, maar ek het hierdie stappe bewerkstellig deur middel van baie probeer, vloekery en tafels omgooi. Ek het hierdie mal idee gehad om dit met 'n gesonde dosis van lewendigheid en gevloekery te deel. Vat dit soos jy wil!</p> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,4 @@ | ||
<p>Baie dankie aan almal wat vrywillig die webwerf in nuwe tale vertaal het, julle is fantasties! | ||
{% include "partials/collaborator-list.njk" %}. Met additionele hulp van {% include "partials/otherhelper-list.njk" %}</p> | ||
|
||
<p>As jy wil help om 'n vertaling in jou taal by te voeg, dien 'n pull request in by {% github_link %}</p> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,18 @@ | ||
--- | ||
tags: tip | ||
title: Oh shit, ek het iets groots verkeerd gedoen, vertel asseblief vir my git het 'n magiese tydmasjien!?! | ||
id: magiese-tydmasjien | ||
order: 1 | ||
--- | ||
|
||
```git | ||
git reflog | ||
# hier sal jy 'n lys sien van alles | ||
# wat jy in git gedoen het, in alle takke! | ||
# elke een het 'n indeks HEAD@{indeks} | ||
# vind die een net voordat jy alles gebreek het | ||
git reset HEAD@{index} | ||
# magiese tydmasjien | ||
``` | ||
|
||
Jy kan dit gebruik om dinge terug te kry wat jy per ongeluk geskrap het, of net goed te verwyder wat jy probeer het en die repo daarmee gebreek het, of om te herstel ná 'n slegte merge, of net om terug te gaan na 'n tyd wanneer dinge werklik gewerk het. Ek gebruik BAIE 'reflog'. Massiewe knik van die hoed vir die baie baie baie baie mense wat voorgestel het om dit by te voeg! |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,18 @@ | ||
--- | ||
tags: tip | ||
title: Oh shit, Ek het commit en onmiddelik besef ek moet een klein verandering maak! | ||
id: wysig-die-laaste-commit | ||
order: 2 | ||
--- | ||
|
||
```git | ||
# maak jou verandering | ||
git add . # of voef individuele leêrs by | ||
git commit --amend --no-edit | ||
# nou bevat jou laaste commit die verandering! | ||
# WAARSKUWING: moet nooit openbare commits wysig nie | ||
``` | ||
|
||
Dit gebeur gewoonlik met my as ek commit en dan toetse/linters uitvoer... en dan sien jy dat jy fokken vergeet het om 'n spasie voor die isgelykaanteken te sit. Jy kan ook die verandering maak as 'n nuwe commit en dan 'n `rebase -i` doen om albei saam te smelt, maar hierdie is baie vinniger. | ||
|
||
*Waarskuwing: Jy moet nooit commits wat tot gestoot om 'n openbare/gedeel tak wysig! Wysig slegs commits wat slegs in jou plaaslike kopie voorkom, of anders gaan dit na slegte tye lei.* |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,12 @@ | ||
--- | ||
tags: tip | ||
title: Oh shit, ek moet die boodskap op my laaste commit verander! | ||
id: verander-commit-boodskap | ||
order: 3 | ||
--- | ||
```git | ||
git commit --amend | ||
# volg die aanwysings om die commit boodskap te verander | ||
``` | ||
|
||
Kak vereistes vir commit boodskappe. |
Oops, something went wrong.