Skip to content

Commit 112a6b8

Browse files
committed
docs: Adds info on git amend
Adds the start of the intermediate git section. This should be squashed with the rest of the commits on intermediate usage.
1 parent 51fb347 commit 112a6b8

7 files changed

Lines changed: 43 additions & 31 deletions

File tree

Git Tutorial.aux

Lines changed: 7 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -53,9 +53,11 @@
5353
\@writefile{toc}{\contentsline {subsubsection}{\numberline {6.5.1}Merge Conflicts}{15}{subsubsection.6.5.1}\protected@file@percent }
5454
\@writefile{toc}{\contentsline {subsection}{\numberline {6.6}Git Log}{15}{subsection.6.6}\protected@file@percent }
5555
\@writefile{toc}{\contentsline {subsection}{\numberline {6.7}Creating Tags or Releases}{16}{subsection.6.7}\protected@file@percent }
56-
\@writefile{toc}{\contentsline {section}{\numberline {7}Using GitHub}{16}{section.7}\protected@file@percent }
57-
\@writefile{toc}{\contentsline {subsection}{\numberline {7.1}ReadMe}{17}{subsection.7.1}\protected@file@percent }
58-
\@writefile{toc}{\contentsline {subsection}{\numberline {7.2}Creating Releases}{18}{subsection.7.2}\protected@file@percent }
59-
\@writefile{toc}{\contentsline {subsection}{\numberline {7.3}Creating Issues}{18}{subsection.7.3}\protected@file@percent }
60-
\@writefile{toc}{\contentsline {section}{\numberline {8}Conclusion}{18}{section.8}\protected@file@percent }
56+
\@writefile{toc}{\contentsline {section}{\numberline {7}Intermediate Usage of Git}{16}{section.7}\protected@file@percent }
57+
\@writefile{toc}{\contentsline {subsection}{\numberline {7.1}Amending Commits}{17}{subsection.7.1}\protected@file@percent }
58+
\@writefile{toc}{\contentsline {section}{\numberline {8}Using GitHub}{17}{section.8}\protected@file@percent }
59+
\@writefile{toc}{\contentsline {subsection}{\numberline {8.1}ReadMe}{17}{subsection.8.1}\protected@file@percent }
60+
\@writefile{toc}{\contentsline {subsection}{\numberline {8.2}Creating Releases}{18}{subsection.8.2}\protected@file@percent }
61+
\@writefile{toc}{\contentsline {subsection}{\numberline {8.3}Creating Issues}{18}{subsection.8.3}\protected@file@percent }
62+
\@writefile{toc}{\contentsline {section}{\numberline {9}Conclusion}{19}{section.9}\protected@file@percent }
6163
\gdef \@abspage@last{19}

Git Tutorial.log

Lines changed: 16 additions & 16 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
This is pdfTeX, Version 3.14159265-2.6-1.40.21 (MiKTeX 21.1) (preloaded format=pdflatex 2021.2.8) 25 OCT 2021 22:54
1+
This is pdfTeX, Version 3.14159265-2.6-1.40.21 (MiKTeX 21.1) (preloaded format=pdflatex 2021.2.8) 25 OCT 2021 23:02
22
entering extended mode
33
**"./Git Tutorial.tex"
44
("Git Tutorial.tex"
@@ -406,7 +406,7 @@ LaTeX Font Info: External font `cmex10' loaded for size
406406

407407
[2]
408408
(Images/repositories.pdf_tex
409-
<Images//repositories.pdf, id=221, page=1, 673.41853pt x 670.94444pt>
409+
<Images//repositories.pdf, id=231, page=1, 673.41853pt x 670.94444pt>
410410
File: Images//repositories.pdf Graphic file (type pdf)
411411
<use Images//repositories.pdf, page 1>
412412
Package pdftex.def Info: Images//repositories.pdf , page1 used on input line 56
@@ -418,20 +418,20 @@ LaTeX Font Info: External font `cmex10' loaded for size
418418
(Font) <20.74> on input line 57.
419419
LaTeX Font Info: External font `cmex10' loaded for size
420420
(Font) <17.28> on input line 57.
421-
<Images//repositories.pdf, id=222, page=2, 673.41853pt x 670.94444pt>
421+
<Images//repositories.pdf, id=232, page=2, 673.41853pt x 670.94444pt>
422422
File: Images//repositories.pdf Graphic file (type pdf)
423423
<use Images//repositories.pdf, page 2>
424424
Package pdftex.def Info: Images//repositories.pdf , page2 used on input line 59
425425
.
426426
(pdftex.def) Requested size: 469.75499pt x 468.03009pt.
427427
) (Images/commit-history.pdf_tex
428-
<Images//commit-history.pdf, id=223, page=1, 887.13869pt x 304.73422pt>
428+
<Images//commit-history.pdf, id=233, page=1, 887.13869pt x 304.73422pt>
429429
File: Images//commit-history.pdf Graphic file (type pdf)
430430
<use Images//commit-history.pdf, page 1>
431431
Package pdftex.def Info: Images//commit-history.pdf , page1 used on input line
432432
56.
433433
(pdftex.def) Requested size: 469.75499pt x 161.35957pt.
434-
<Images//commit-history.pdf, id=224, page=2, 887.13869pt x 304.73422pt>
434+
<Images//commit-history.pdf, id=234, page=2, 887.13869pt x 304.73422pt>
435435
File: Images//commit-history.pdf Graphic file (type pdf)
436436
<use Images//commit-history.pdf, page 2>
437437
Package pdftex.def Info: Images//commit-history.pdf , page2 used on input line
@@ -442,7 +442,7 @@ Package pdftex.def Info: Images//commit-history.pdf , page2 used on input line
442442
pdfTeX warning: pdflatex (file ./Images//repositories.pdf): PDF inclusion: mult
443443
iple pdfs with page group included in a single page
444444
>] (Images/remote-repos.pdf_tex
445-
<Images//remote-repos.pdf, id=231, page=1, 649.18867pt x 894.94525pt>
445+
<Images//remote-repos.pdf, id=241, page=1, 649.18867pt x 894.94525pt>
446446
File: Images//remote-repos.pdf Graphic file (type pdf)
447447
<use Images//remote-repos.pdf, page 1>
448448
Package pdftex.def Info: Images//remote-repos.pdf , page1 used on input line 56
@@ -457,21 +457,21 @@ ltiple pdfs with page group included in a single page
457457
pdfTeX warning: pdflatex (file ./Images//remote-repos.pdf): PDF inclusion: mult
458458
iple pdfs with page group included in a single page
459459
>] [5] [6] [7] [8]
460-
<Images//GPG Key Listing.png, id=332, 507.0945pt x 151.16475pt>
460+
<Images//GPG Key Listing.png, id=342, 507.0945pt x 151.16475pt>
461461
File: Images//GPG Key Listing.png Graphic file (type png)
462462
<use Images//GPG Key Listing.png>
463463
Package pdftex.def Info: Images//GPG Key Listing.png used on input line 221.
464464
(pdftex.def) Requested size: 253.54662pt x 75.58218pt.
465465
[9] [10 <./Images//GPG Key Listing.png>] [11] [12] [13]
466466
[14] [15] [16] [17] [18] [19] ("Git Tutorial.aux")
467467
Package rerunfilecheck Info: File `"Git Tutorial".out' has not changed.
468-
(rerunfilecheck) Checksum: F5705C1B6D77716811678129DC60A7C1;2860.
468+
(rerunfilecheck) Checksum: BEC757AA4FF5972BC3DB54309CBC29A8;2987.
469469
)
470470
Here is how much of TeX's memory you used:
471-
7611 strings out of 479618
472-
118613 string characters out of 2865027
473-
435734 words of memory out of 3000000
474-
24481 multiletter control sequences out of 15000+200000
471+
7615 strings out of 479618
472+
118663 string characters out of 2865027
473+
435737 words of memory out of 3000000
474+
24483 multiletter control sequences out of 15000+200000
475475
411779 words of font info for 54 fonts, out of 3000000 for 9000
476476
1141 hyphenation exceptions out of 8191
477477
71i,15n,75p,1304b,527s stack positions out of 5000i,500n,10000p,200000b,50000s
@@ -484,9 +484,9 @@ amsfonts/cm/cmbx12.pfb><C:/Users/nblch/AppData/Local/Programs/MiKTeX/fonts/type
484484
ms/MiKTeX/fonts/type1/public/amsfonts/cm/cmr12.pfb><C:/Users/nblch/AppData/Loca
485485
l/Programs/MiKTeX/fonts/type1/public/amsfonts/cm/cmr17.pfb><C:/Users/nblch/AppD
486486
ata/Local/Programs/MiKTeX/fonts/type1/public/amsfonts/cm/cmsy10.pfb>
487-
Output written on "Git Tutorial.pdf" (19 pages, 257004 bytes).
487+
Output written on "Git Tutorial.pdf" (19 pages, 259022 bytes).
488488
PDF statistics:
489-
489 PDF objects out of 1000 (max. 8388607)
490-
148 named destinations out of 1000 (max. 500000)
491-
359 words of extra memory for PDF output out of 10000 (max. 10000000)
489+
499 PDF objects out of 1000 (max. 8388607)
490+
150 named destinations out of 1000 (max. 500000)
491+
375 words of extra memory for PDF output out of 10000 (max. 10000000)
492492

Git Tutorial.out

Lines changed: 7 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -34,8 +34,10 @@
3434
\BOOKMARK [3][-]{subsubsection.6.5.1}{Merge Conflicts}{subsection.6.5}% 34
3535
\BOOKMARK [2][-]{subsection.6.6}{Git Log}{section.6}% 35
3636
\BOOKMARK [2][-]{subsection.6.7}{Creating Tags or Releases}{section.6}% 36
37-
\BOOKMARK [1][-]{section.7}{Using GitHub}{}% 37
38-
\BOOKMARK [2][-]{subsection.7.1}{ReadMe}{section.7}% 38
39-
\BOOKMARK [2][-]{subsection.7.2}{Creating Releases}{section.7}% 39
40-
\BOOKMARK [2][-]{subsection.7.3}{Creating Issues}{section.7}% 40
41-
\BOOKMARK [1][-]{section.8}{Conclusion}{}% 41
37+
\BOOKMARK [1][-]{section.7}{Intermediate Usage of Git}{}% 37
38+
\BOOKMARK [2][-]{subsection.7.1}{Amending Commits}{section.7}% 38
39+
\BOOKMARK [1][-]{section.8}{Using GitHub}{}% 39
40+
\BOOKMARK [2][-]{subsection.8.1}{ReadMe}{section.8}% 40
41+
\BOOKMARK [2][-]{subsection.8.2}{Creating Releases}{section.8}% 41
42+
\BOOKMARK [2][-]{subsection.8.3}{Creating Issues}{section.8}% 42
43+
\BOOKMARK [1][-]{section.9}{Conclusion}{}% 43

Git Tutorial.pdf

1.97 KB
Binary file not shown.

Git Tutorial.synctex.gz

2.83 KB
Binary file not shown.

Git Tutorial.tex

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -382,6 +382,12 @@
382382
\item Creating releases should be done on Github. The main difference is that the tag is generated with a message where you can create a change log from the previous release. Using Github allows you to use Markdown to do so.
383383
\end{itemize}
384384

385+
\section{Intermediate Usage of Git}
386+
Once you have gotten a grasp of the basic commands of git, there are a few commands that will push your skills a little further. I find myself using most of these commands at least a few times a month.
387+
388+
\subsection{Amending Commits}
389+
Lets say you have just committed some changes and you find that you need to make another small change or fix something that should have been in that last commit. That is when you want to use the \colorbox{light-gray}{\textbf{- -amend}} flag to \colorbox{light-gray}{\textbf{git commit}}. Using this flag allows you to add anything staged to the previous commit you just made. When you commit in this way, the previous commit message will come up again if you want to change it. If not, just write and quit.
390+
385391
\section{Using GitHub}
386392
There are three main reasons to directly go to GitHub instead of using the terminal or your GUI: to make the README, create a release, manage an issue.
387393

Git Tutorial.toc

Lines changed: 7 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -34,8 +34,10 @@
3434
\contentsline {subsubsection}{\numberline {6.5.1}Merge Conflicts}{15}{subsubsection.6.5.1}%
3535
\contentsline {subsection}{\numberline {6.6}Git Log}{15}{subsection.6.6}%
3636
\contentsline {subsection}{\numberline {6.7}Creating Tags or Releases}{16}{subsection.6.7}%
37-
\contentsline {section}{\numberline {7}Using GitHub}{16}{section.7}%
38-
\contentsline {subsection}{\numberline {7.1}ReadMe}{17}{subsection.7.1}%
39-
\contentsline {subsection}{\numberline {7.2}Creating Releases}{18}{subsection.7.2}%
40-
\contentsline {subsection}{\numberline {7.3}Creating Issues}{18}{subsection.7.3}%
41-
\contentsline {section}{\numberline {8}Conclusion}{18}{section.8}%
37+
\contentsline {section}{\numberline {7}Intermediate Usage of Git}{16}{section.7}%
38+
\contentsline {subsection}{\numberline {7.1}Amending Commits}{17}{subsection.7.1}%
39+
\contentsline {section}{\numberline {8}Using GitHub}{17}{section.8}%
40+
\contentsline {subsection}{\numberline {8.1}ReadMe}{17}{subsection.8.1}%
41+
\contentsline {subsection}{\numberline {8.2}Creating Releases}{18}{subsection.8.2}%
42+
\contentsline {subsection}{\numberline {8.3}Creating Issues}{18}{subsection.8.3}%
43+
\contentsline {section}{\numberline {9}Conclusion}{19}{section.9}%

0 commit comments

Comments
 (0)