/
usr
/
share
/
doc
/
git
/
/usr/share/doc/git
mkdir
upload
Name
Size
Mode
Actions
contrib/
-
0755
rm
howto/
-
0755
rm
RelNotes/
-
0755
rm
technical/
-
0755
rm
blame-options.txt
6001
0644
edit
dl
rm
cmds-ancillaryinterrogators.txt
1294
0644
edit
dl
rm
cmds-ancillarymanipulators.txt
746
0644
edit
dl
rm
cmds-developerinterfaces.txt
678
0644
edit
dl
rm
cmds-foreignscminterface.txt
399
0644
edit
dl
rm
cmds-guide.txt
833
0644
edit
dl
rm
cmds-mainporcelain.txt
3033
0644
edit
dl
rm
cmds-plumbinginterrogators.txt
1539
0644
edit
dl
rm
cmds-plumbingmanipulators.txt
1410
0644
edit
dl
rm
cmds-purehelpers.txt
1268
0644
edit
dl
rm
cmds-synchelpers.txt
449
0644
edit
dl
rm
cmds-synchingrepositories.txt
397
0644
edit
dl
rm
cmds-userinterfaces.txt
507
0644
edit
dl
rm
CODE_OF_CONDUCT.md
5989
0644
edit
dl
rm
config.txt
18001
0644
edit
dl
rm
date-formats.txt
1172
0644
edit
dl
rm
diff-format.txt
6573
0644
edit
dl
rm
diff-generate-patch.txt
7253
0644
edit
dl
rm
diff-options.txt
32436
0644
edit
dl
rm
docbook-xsl.css
4557
0644
edit
dl
rm
everyday.html
16996
0644
edit
dl
rm
fetch-options.txt
12281
0644
edit
dl
rm
fsck-msgids.txt
4197
0644
edit
dl
rm
git-add.html
40369
0644
edit
dl
rm
git-add.txt
16164
0644
edit
dl
rm
git-am.html
33161
0644
edit
dl
rm
git-am.txt
9317
0644
edit
dl
rm
git-annotate.html
28391
0644
edit
dl
rm
git-annotate.txt
771
0644
edit
dl
rm
git-apply.html
33407
0644
edit
dl
rm
git-apply.txt
10950
0644
edit
dl
rm
git-archive.html
29856
0644
edit
dl
rm
git-archive.txt
8491
0644
edit
dl
rm
git-bisect-lk2009.html
81243
0644
edit
dl
rm
git-bisect-lk2009.txt
49694
0644
edit
dl
rm
git-bisect.html
40572
0644
edit
dl
rm
git-bisect.txt
17905
0644
edit
dl
rm
git-blame.html
42501
0644
edit
dl
rm
git-blame.txt
8732
0644
edit
dl
rm
git-branch.html
48253
0644
edit
dl
rm
git-branch.txt
15748
0644
edit
dl
rm
git-bugreport.html
20509
0644
edit
dl
rm
git-bugreport.txt
2421
0644
edit
dl
rm
git-bundle.html
33269
0644
edit
dl
rm
git-bundle.txt
11703
0644
edit
dl
rm
git-cat-file.html
38661
0644
edit
dl
rm
git-cat-file.txt
13615
0644
edit
dl
rm
git-check-attr.html
22633
0644
edit
dl
rm
git-check-attr.txt
3390
0644
edit
dl
rm
git-check-ignore.html
23135
0644
edit
dl
rm
git-check-ignore.txt
4156
0644
edit
dl
rm
git-check-mailmap.html
18816
0644
edit
dl
rm
git-check-mailmap.txt
1108
0644
edit
dl
rm
git-check-ref-format.html
24040
0644
edit
dl
rm
git-check-ref-format.txt
5034
0644
edit
dl
rm
git-checkout-index.html
25362
0644
edit
dl
rm
git-checkout-index.txt
5669
0644
edit
dl
rm
git-checkout.html
52719
0644
edit
dl
rm
git-checkout.txt
22362
0644
edit
dl
rm
git-cherry-pick.html
31065
0644
edit
dl
rm
git-cherry-pick.txt
8764
0644
edit
dl
rm
git-cherry.html
22423
0644
edit
dl
rm
git-cherry.txt
3615
0644
edit
dl
rm
git-clean.html
23981
0644
edit
dl
rm
git-clean.txt
4523
0644
edit
dl
rm
git-clone.html
44328
0644
edit
dl
rm
git-clone.txt
14772
0644
edit
dl
rm
git-column.html
23317
0644
edit
dl
rm
git-column.txt
2201
0644
edit
dl
rm
git-commit-graph.html
26147
0644
edit
dl
rm
git-commit-graph.txt
5949
0644
edit
dl
rm
git-commit-tree.html
26683
0644
edit
dl
rm
git-commit-tree.txt
2710
0644
edit
dl
rm
git-commit.html
57154
0644
edit
dl
rm
git-commit.txt
21575
0644
edit
dl
rm
git-config.html
415540
0644
edit
dl
rm
git-config.txt
19755
0644
edit
dl
rm
git-contacts.html
20718
0644
edit
dl
rm
git-contacts.txt
2584
0644
edit
dl
rm
git-count-objects.html
18946
0644
edit
dl
rm
git-count-objects.txt
1350
0644
edit
dl
rm
git-credential-cache--daemon.html
18182
0644
edit
dl
rm
git-credential-cache--daemon.txt
891
0644
edit
dl
rm
git-credential-cache.html
20180
0644
edit
dl
rm
git-credential-cache.txt
2484
0644
edit
dl
rm
git-credential-store.html
22043
0644
edit
dl
rm
git-credential-store.txt
3637
0644
edit
dl
rm
git-credential.html
26676
0644
edit
dl
rm
git-credential.txt
7327
0644
edit
dl
rm
git-describe.html
28268
0644
edit
dl
rm
git-describe.txt
8319
0644
edit
dl
rm
git-diagnose.html
20157
0644
edit
dl
rm
git-diagnose.txt
2208
0644
edit
dl
rm
git-diff-files.html
79130
0644
edit
dl
rm
git-diff-files.txt
1225
0644
edit
dl
rm
git-diff-index.html
84351
0644
edit
dl
rm
git-diff-index.txt
4811
0644
edit
dl
rm
git-diff-tree.html
116052
0644
edit
dl
rm
git-diff-tree.txt
4184
0644
edit
dl
rm
git-diff.html
107093
0644
edit
dl
rm
git-diff.txt
8039
0644
edit
dl
rm
git-difftool.html
27048
0644
edit
dl
rm
git-difftool.txt
4624
0644
edit
dl
rm
git-fast-export.html
31650
0644
edit
dl
rm
git-fast-export.txt
11282
0644
edit
dl
rm
git-fast-import.html
103283
0644
edit
dl
rm
git-fast-import.txt
59963
0644
edit
dl
rm
git-fetch-pack.html
23255
0644
edit
dl
rm
git-fetch-pack.txt
4248
0644
edit
dl
rm
git-fetch.html
75456
0644
edit
dl
rm
git-fetch.txt
11812
0644
edit
dl
rm
git-filter-branch.html
54648
0644
edit
dl
rm
git-filter-branch.txt
31031
0644
edit
dl
rm
git-fmt-merge-msg.html
21435
0644
edit
dl
rm
git-fmt-merge-msg.txt
1931
0644
edit
dl
rm
git-for-each-ref.html
43438
0644
edit
dl
rm
git-for-each-ref.txt
17073
0644
edit
dl
rm
git-for-each-repo.html
19296
0644
edit
dl
rm
git-for-each-repo.txt
1543
0644
edit
dl
rm
git-format-patch.html
81842
0644
edit
dl
rm
git-format-patch.txt
28876
0644
edit
dl
rm
git-fsck-objects.html
17392
0644
edit
dl
rm
git-fsck-objects.txt
354
0644
edit
dl
rm
git-fsck.html
39162
0644
edit
dl
rm
git-fsck.txt
5882
0644
edit
dl
rm
git-fsmonitor--daemon.html
22875
0644
edit
dl
rm
git-fsmonitor--daemon.txt
3610
0644
edit
dl
rm
git-gc.html
36697
0644
edit
dl
rm
git-gc.txt
6292
0644
edit
dl
rm
git-get-tar-commit-id.html
17835
0644
edit
dl
rm
git-get-tar-commit-id.txt
753
0644
edit
dl
rm
git-grep.html
36030
0644
edit
dl
rm
git-grep.txt
10763
0644
edit
dl
rm
git-hash-object.html
19939
0644
edit
dl
rm
git-hash-object.txt
2142
0644
edit
dl
rm
git-help.html
28141
0644
edit
dl
rm
git-help.txt
7527
0644
edit
dl
rm
git-hook.html
18807
0644
edit
dl
rm
git-hook.txt
1028
0644
edit
dl
rm
git-http-backend.html
30974
0644
edit
dl
rm
git-http-backend.txt
11472
0644
edit
dl
rm
git-http-fetch.html
19679
0644
edit
dl
rm
git-http-fetch.txt
1775
0644
edit
dl
rm
git-http-push.html
21391
0644
edit
dl
rm
git-http-push.txt
2995
0644
edit
dl
rm
git-imap-send.html
25472
0644
edit
dl
rm
git-imap-send.txt
3567
0644
edit
dl
rm
git-index-pack.html
24735
0644
edit
dl
rm
git-index-pack.txt
5205
0644
edit
dl
rm
git-init-db.html
17460
0644
edit
dl
rm
git-init-db.txt
409
0644
edit
dl
rm
git-init.html
26604
0644
edit
dl
rm
git-init.txt
5869
0644
edit
dl
rm
git-interpret-trailers.html
42006
0644
edit
dl
rm
git-interpret-trailers.txt
18579
0644
edit
dl
rm
git-log.html
182485
0644
edit
dl
rm
git-log.txt
6864
0644
edit
dl
rm
git-ls-files.html
35053
0644
edit
dl
rm
git-ls-files.txt
11622
0644
edit
dl
rm
git-ls-remote.html
24349
0644
edit
dl
rm
git-ls-remote.txt
4841
0644
edit
dl
rm
git-ls-tree.html
25628
0644
edit
dl
rm
git-ls-tree.txt
5515
0644
edit
dl
rm
git-mailinfo.html
23402
0644
edit
dl
rm
git-mailinfo.txt
3866
0644
edit
dl
rm
git-mailsplit.html
19264
0644
edit
dl
rm
git-mailsplit.txt
1342
0644
edit
dl
rm
git-maintenance.html
46000
0644
edit
dl
rm
git-maintenance.txt
18901
0644
edit
dl
rm
git-merge-base.html
28380
0644
edit
dl
rm
git-merge-base.txt
7759
0644
edit
dl
rm
git-merge-file.html
22656
0644
edit
dl
rm
git-merge-file.txt
3718
0644
edit
dl
rm
git-merge-index.html
20450
0644
edit
dl
rm
git-merge-index.txt
2445
0644
edit
dl
rm
git-merge-one-file.html
17416
0644
edit
dl
rm
git-merge-one-file.txt
387
0644
edit
dl
rm
git-merge-tree.html
33496
0644
edit
dl
rm
git-merge-tree.txt
11923
0644
edit
dl
rm
git-merge.html
71005
0644
edit
dl
rm
git-merge.txt
15068
0644
edit
dl
rm
git-mergetool--lib.html
19127
0644
edit
dl
rm
git-mergetool--lib.txt
1467
0644
edit
dl
rm
git-mergetool.html
39795
0644
edit
dl
rm
git-mergetool.txt
4473
0644
edit
dl
rm
git-mktag.html
19819
0644
edit
dl
rm
git-mktag.txt
1782
0644
edit
dl
rm
git-mktree.html
18474
0644
edit
dl
rm
git-mktree.txt
1075
0644
edit
dl
rm
git-multi-pack-index.html
23595
0644
edit
dl
rm
git-multi-pack-index.txt
4632
0644
edit
dl
rm
git-mv.html
20092
0644
edit
dl
rm
git-mv.txt
2103
0644
edit
dl
rm
git-name-rev.html
21670
0644
edit
dl
rm
git-name-rev.txt
3352
0644
edit
dl
rm
git-notes.html
41046
0644
edit
dl
rm
git-notes.txt
13866
0644
edit
dl
rm
git-pack-objects.html
42391
0644
edit
dl
rm
git-pack-objects.txt
19297
0644
edit
dl
rm
git-pack-redundant.html
19799
0644
edit
dl
rm
git-pack-redundant.txt
1876
0644
edit
dl
rm
git-pack-refs.html
21120
0644
edit
dl
rm
git-pack-refs.txt
3136
0644
edit
dl
rm
git-patch-id.html
20354
0644
edit
dl
rm
git-patch-id.txt
2430
0644
edit
dl
rm
git-prune-packed.html
18539
0644
edit
dl
rm
git-prune-packed.txt
946
0644
edit
dl
rm
git-prune.html
20327
0644
edit
dl
rm
git-prune.txt
1919
0644
edit
dl
rm
git-pull.html
77070
0644
edit
dl
rm
git-pull.txt
8354
0644
edit
dl
rm
git-push.html
74993
0644
edit
dl
rm
git-push.txt
28061
0644
edit
dl
rm
git-quiltimport.html
19466
0644
edit
dl
rm
git-quiltimport.txt
1693
0644
edit
dl
rm
git-range-diff.html
31673
0644
edit
dl
rm
git-range-diff.txt
10337
0644
edit
dl
rm
git-read-tree.html
39078
0644
edit
dl
rm
git-read-tree.txt
16897
0644
edit
dl
rm
git-rebase.html
98945
0644
edit
dl
rm
git-rebase.txt
47228
0644
edit
dl
rm
git-receive-pack.html
30448
0644
edit
dl
rm
git-receive-pack.txt
9526
0644
edit
dl
rm
git-reflog.html
23514
0644
edit
dl
rm
git-reflog.txt
4575
0644
edit
dl
rm
git-remote-ext.html
23012
0644
edit
dl
rm
git-remote-ext.txt
3977
0644
edit
dl
rm
git-remote-fd.html
19501
0644
edit
dl
rm
git-remote-fd.txt
1628
0644
edit
dl
rm
git-remote-helpers.html
16974
0644
edit
dl
rm
git-remote.html
29903
0644
edit
dl
rm
git-remote.txt
8768
0644
edit
dl
rm
git-repack.html
32819
0644
edit
dl
rm
git-repack.txt
11020
0644
edit
dl
rm
git-replace.html
24858
0644
edit
dl
rm
git-replace.txt
5211
0644
edit
dl
rm
git-request-pull.html
20295
0644
edit
dl
rm
git-request-pull.txt
2035
0644
edit
dl
rm
git-rerere.html
27040
0644
edit
dl
rm
git-rerere.txt
7781
0644
edit
dl
rm
git-reset.html
44520
0644
edit
dl
rm
git-reset.txt
19125
0644
edit
dl
rm
git-restore.html
28166
0644
edit
dl
rm
git-restore.txt
7082
0644
edit
dl
rm
git-rev-list.html
118128
0644
edit
dl
rm
git-rev-list.txt
3220
0644
edit
dl
rm
git-rev-parse.html
64641
0644
edit
dl
rm
git-rev-parse.txt
15840
0644
edit
dl
rm
git-revert.html
26792
0644
edit
dl
rm
git-revert.txt
5421
0644
edit
dl
rm
git-rm.html
27584
0644
edit
dl
rm
git-rm.txt
7236
0644
edit
dl
rm
git-send-pack.html
24576
0644
edit
dl
rm
git-send-pack.txt
5160
0644
edit
dl
rm
git-sh-i18n--envsubst.html
18166
0644
edit
dl
rm
git-sh-i18n--envsubst.txt
928
0644
edit
dl
rm
git-sh-i18n.html
18595
0644
edit
dl
rm
git-sh-i18n.txt
1147
0644
edit
dl
rm
git-sh-setup.html
21277
0644
edit
dl
rm
git-sh-setup.txt
2976
0644
edit
dl
rm
git-shell.html
21414
0644
edit
dl
rm
git-shell.txt
2981
0644
edit
dl
rm
git-shortlog.html
64618
0644
edit
dl
rm
git-shortlog.txt
4409
0644
edit
dl
rm
git-show-branch.html
26813
0644
edit
dl
rm
git-show-branch.txt
6589
0644
edit
dl
rm
git-show-index.html
19521
0644
edit
dl
rm
git-show-index.txt
1473
0644
edit
dl
rm
git-show-ref.html
26075
0644
edit
dl
rm
git-show-ref.txt
6648
0644
edit
dl
rm
git-show.html
111644
0644
edit
dl
rm
git-show.txt
1929
0644
edit
dl
rm
git-sparse-checkout.html
43949
0644
edit
dl
rm
git-sparse-checkout.txt
21258
0644
edit
dl
rm
git-stage.html
17341
0644
edit
dl
rm
git-stage.txt
299
0644
edit
dl
rm
git-stash.html
38594
0644
edit
dl
rm
git-stash.txt
14999
0644
edit
dl
rm
git-status.html
45718
0644
edit
dl
rm
git-status.txt
20295
0644
edit
dl
rm
git-stripspace.html
20016
0644
edit
dl
rm
git-stripspace.txt
1946
0644
edit
dl
rm
git-submodule.html
45581
0644
edit
dl
rm
git-submodule.txt
20819
0644
edit
dl
rm
git-subtree.html
36823
0644
edit
dl
rm
git-subtree.txt
13687
0644
edit
dl
rm
git-switch.html
33314
0644
edit
dl
rm
git-switch.txt
8607
0644
edit
dl
rm
git-symbolic-ref.html
20452
0644
edit
dl
rm
git-symbolic-ref.txt
2327
0644
edit
dl
rm
git-tag.html
38958
0644
edit
dl
rm
git-tag.txt
13469
0644
edit
dl
rm
git-tools.html
17207
0644
edit
dl
rm
git-tools.txt
422
0644
edit
dl
rm
git-unpack-file.html
17645
0644
edit
dl
rm
git-unpack-file.txt
434
0644
edit
dl
rm
git-unpack-objects.html
18811
0644
edit
dl
rm
git-unpack-objects.txt
1220
0644
edit
dl
rm
git-update-index.html
49723
0644
edit
dl
rm
git-update-index.txt
23928
0644
edit
dl
rm
git-update-ref.html
25909
0644
edit
dl
rm
git-update-ref.txt
6298
0644
edit
dl
rm
git-update-server-info.html
18255
0644
edit
dl
rm
git-update-server-info.txt
801
0644
edit
dl
rm
git-upload-archive.html
19776
0644
edit
dl
rm
git-upload-archive.txt
2087
0644
edit
dl
rm
git-upload-pack.html
21671
0644
edit
dl
rm
git-upload-pack.txt
2998
0644
edit
dl
rm
git-var.html
21537
0644
edit
dl
rm
git-var.txt
3176
0644
edit
dl
rm
git-verify-commit.html
17948
0644
edit
dl
rm
git-verify-commit.txt
575
0644
edit
dl
rm
git-verify-pack.html
18953
0644
edit
dl
rm
git-verify-pack.txt
1111
0644
edit
dl
rm
git-verify-tag.html
17941
0644
edit
dl
rm
git-verify-tag.txt
562
0644
edit
dl
rm
git-version.html
17798
0644
edit
dl
rm
git-version.txt
532
0644
edit
dl
rm
git-web--browse.html
22405
0644
edit
dl
rm
git-web--browse.txt
3576
0644
edit
dl
rm
git-whatchanged.html
18572
0644
edit
dl
rm
git-whatchanged.txt
1098
0644
edit
dl
rm
git-worktree.html
46341
0644
edit
dl
rm
git-worktree.txt
20985
0644
edit
dl
rm
git-write-tree.html
18441
0644
edit
dl
rm
git-write-tree.txt
1026
0644
edit
dl
rm
git.html
107237
0644
edit
dl
rm
git.txt
43254
0644
edit
dl
rm
gitattributes.html
82845
0644
edit
dl
rm
gitattributes.txt
49511
0644
edit
dl
rm
gitcli.html
29584
0644
edit
dl
rm
gitcli.txt
9697
0644
edit
dl
rm
gitcore-tutorial.html
100139
0644
edit
dl
rm
gitcore-tutorial.txt
62240
0644
edit
dl
rm
gitcredentials.html
31980
0644
edit
dl
rm
gitcredentials.txt
11317
0644
edit
dl
rm
gitdiffcore.html
33745
0644
edit
dl
rm
gitdiffcore.txt
14082
0644
edit
dl
rm
giteveryday.html
38092
0644
edit
dl
rm
giteveryday.txt
14422
0644
edit
dl
rm
gitfaq.html
44081
0644
edit
dl
rm
gitfaq.txt
21069
0644
edit
dl
rm
gitformat-bundle.html
21446
0644
edit
dl
rm
gitformat-bundle.txt
3256
0644
edit
dl
rm
gitformat-chunk.html
24329
0644
edit
dl
rm
gitformat-chunk.txt
5560
0644
edit
dl
rm
gitformat-commit-graph.html
28630
0644
edit
dl
rm
gitformat-commit-graph.txt
7857
0644
edit
dl
rm
gitformat-index.html
40269
0644
edit
dl
rm
gitformat-index.txt
15180
0644
edit
dl
rm
gitformat-pack.html
49811
0644
edit
dl
rm
gitformat-pack.txt
23509
0644
edit
dl
rm
gitformat-signature.html
27362
0644
edit
dl
rm
gitformat-signature.txt
8093
0644
edit
dl
rm
gitglossary.html
64201
0644
edit
dl
rm
gitglossary.txt
358
0644
edit
dl
rm
githooks.html
56500
0644
edit
dl
rm
githooks.txt
29331
0644
edit
dl
rm
gitignore.html
28399
0644
edit
dl
rm
gitignore.txt
8918
0644
edit
dl
rm
gitmailmap.html
22819
0644
edit
dl
rm
gitmailmap.txt
3551
0644
edit
dl
rm
gitmodules.html
24057
0644
edit
dl
rm
gitmodules.txt
4800
0644
edit
dl
rm
gitnamespaces.html
22148
0644
edit
dl
rm
gitnamespaces.txt
2509
0644
edit
dl
rm
gitprotocol-capabilities.html
37425
0644
edit
dl
rm
gitprotocol-capabilities.txt
15311
0644
edit
dl
rm
gitprotocol-common.html
21565
0644
edit
dl
rm
gitprotocol-common.txt
3177
0644
edit
dl
rm
gitprotocol-http.html
43234
0644
edit
dl
rm
gitprotocol-http.txt
17994
0644
edit
dl
rm
gitprotocol-pack.html
53023
0644
edit
dl
rm
gitprotocol-pack.txt
27678
0644
edit
dl
rm
gitprotocol-v2.html
59690
0644
edit
dl
rm
gitprotocol-v2.txt
31434
0644
edit
dl
rm
gitremote-helpers.html
48215
0644
edit
dl
rm
gitremote-helpers.txt
21785
0644
edit
dl
rm
gitrepository-layout.html
39352
0644
edit
dl
rm
gitrepository-layout.txt
11622
0644
edit
dl
rm
gitrevisions.html
41621
0644
edit
dl
rm
gitrevisions.txt
823
0644
edit
dl
rm
gitsubmodules.html
31699
0644
edit
dl
rm
gitsubmodules.txt
10366
0644
edit
dl
rm
gittutorial-2.html
34547
0644
edit
dl
rm
gittutorial-2.txt
14750
0644
edit
dl
rm
gittutorial.html
46263
0644
edit
dl
rm
gittutorial.txt
22972
0644
edit
dl
rm
gitworkflows.html
39869
0644
edit
dl
rm
gitworkflows.txt
17414
0644
edit
dl
rm
glossary-content.txt
32609
0644
edit
dl
rm
howto-index.html
22991
0644
edit
dl
rm
howto-index.txt
4001
0644
edit
dl
rm
i18n.txt
2940
0644
edit
dl
rm
line-range-format.txt
1162
0644
edit
dl
rm
line-range-options.txt
761
0644
edit
dl
rm
merge-options.txt
7236
0644
edit
dl
rm
merge-strategies.txt
6610
0644
edit
dl
rm
mergetools-diff.txt
1507
0644
edit
dl
rm
mergetools-merge.txt
2586
0644
edit
dl
rm
MyFirstContribution.html
90572
0644
edit
dl
rm
MyFirstContribution.txt
54596
0644
edit
dl
rm
MyFirstObjectWalk.html
60554
0644
edit
dl
rm
MyFirstObjectWalk.txt
28979
0644
edit
dl
rm
object-format-disclaimer.txt
470
0644
edit
dl
rm
pretty-formats.txt
15669
0644
edit
dl
rm
pretty-options.txt
4201
0644
edit
dl
rm
pull-fetch-param.txt
5476
0644
edit
dl
rm
README.md
3652
0644
edit
dl
rm
ref-reachability-filters.txt
391
0644
edit
dl
rm
rerere-options.txt
414
0644
edit
dl
rm
rev-list-description.txt
2531
0644
edit
dl
rm
rev-list-options.txt
46906
0644
edit
dl
rm
ReviewingGuidelines.html
26831
0644
edit
dl
rm
ReviewingGuidelines.txt
8100
0644
edit
dl
rm
revisions.txt
17109
0644
edit
dl
rm
scalar.html
26055
0644
edit
dl
rm
scalar.txt
6056
0644
edit
dl
rm
sequencer.txt
472
0644
edit
dl
rm
signoff-option.txt
781
0644
edit
dl
rm
SubmittingPatches.html
55660
0644
edit
dl
rm
SubmittingPatches.txt
30147
0644
edit
dl
rm
ToolsForGit.html
19020
0644
edit
dl
rm
ToolsForGit.txt
1348
0644
edit
dl
rm
trace2-target-values.txt
529
0644
edit
dl
rm
transfer-data-leaks.txt
1712
0644
edit
dl
rm
urls-remotes.txt
2642
0644
edit
dl
rm
urls.txt
3634
0644
edit
dl
rm
user-manual.html
275731
0644
edit
dl
rm
user-manual.txt
173518
0644
edit
dl
rm
Edit:
/usr/share/doc/git/MyFirstObjectWalk.txt
(28979B)
= My First Object Walk == What's an Object Walk? The object walk is a key concept in Git - this is the process that underpins operations like object transfer and fsck. Beginning from a given commit, the list of objects is found by walking parent relationships between commits (commit X based on commit W) and containment relationships between objects (tree Y is contained within commit X, and blob Z is located within tree Y, giving our working tree for commit X something like `y/z.txt`). A related concept is the revision walk, which is focused on commit objects and their parent relationships and does not delve into other object types. The revision walk is used for operations like `git log`. === Related Reading - `Documentation/user-manual.txt` under "Hacking Git" contains some coverage of the revision walker in its various incarnations. - `revision.h` - https://eagain.net/articles/git-for-computer-scientists/[Git for Computer Scientists] gives a good overview of the types of objects in Git and what your object walk is really describing. == Setting Up Create a new branch from `master`. ---- git checkout -b revwalk origin/master ---- We'll put our fiddling into a new command. For fun, let's name it `git walken`. Open up a new file `builtin/walken.c` and set up the command handler: ---- /* * "git walken" * * Part of the "My First Object Walk" tutorial. */ #include "builtin.h" #include "trace.h" int cmd_walken(int argc, const char **argv, const char *prefix) { trace_printf(_("cmd_walken incoming...\n")); return 0; } ---- NOTE: `trace_printf()`, defined in `trace.h`, differs from `printf()` in that it can be turned on or off at runtime. For the purposes of this tutorial, we will write `walken` as though it is intended for use as a "plumbing" command: that is, a command which is used primarily in scripts, rather than interactively by humans (a "porcelain" command). So we will send our debug output to `trace_printf()` instead. When running, enable trace output by setting the environment variable `GIT_TRACE`. Add usage text and `-h` handling, like all subcommands should consistently do (our test suite will notice and complain if you fail to do so). We'll need to include the `parse-options.h` header. ---- #include "parse-options.h" ... int cmd_walken(int argc, const char **argv, const char *prefix) { const char * const walken_usage[] = { N_("git walken"), NULL, }; struct option options[] = { OPT_END() }; argc = parse_options(argc, argv, prefix, options, walken_usage, 0); ... } ---- Also add the relevant line in `builtin.h` near `cmd_whatchanged()`: ---- int cmd_walken(int argc, const char **argv, const char *prefix); ---- Include the command in `git.c` in `commands[]` near the entry for `whatchanged`, maintaining alphabetical ordering: ---- { "walken", cmd_walken, RUN_SETUP }, ---- Add it to the `Makefile` near the line for `builtin/worktree.o`: ---- BUILTIN_OBJS += builtin/walken.o ---- Build and test out your command, without forgetting to ensure the `DEVELOPER` flag is set, and with `GIT_TRACE` enabled so the debug output can be seen: ---- $ echo DEVELOPER=1 >>config.mak $ make $ GIT_TRACE=1 ./bin-wrappers/git walken ---- NOTE: For a more exhaustive overview of the new command process, take a look at `Documentation/MyFirstContribution.txt`. NOTE: A reference implementation can be found at https://github.com/nasamuffin/git/tree/revwalk. === `struct rev_cmdline_info` The definition of `struct rev_cmdline_info` can be found in `revision.h`. This struct is contained within the `rev_info` struct and is used to reflect parameters provided by the user over the CLI. `nr` represents the number of `rev_cmdline_entry` present in the array. `alloc` is used by the `ALLOC_GROW` macro. Check `alloc.h` - this variable is used to track the allocated size of the list. Per entry, we find: `item` is the object provided upon which to base the object walk. Items in Git can be blobs, trees, commits, or tags. (See `Documentation/gittutorial-2.txt`.) `name` is the object ID (OID) of the object - a hex string you may be familiar with from using Git to organize your source in the past. Check the tutorial mentioned above towards the top for a discussion of where the OID can come from. `whence` indicates some information about what to do with the parents of the specified object. We'll explore this flag more later on; take a look at `Documentation/revisions.txt` to get an idea of what could set the `whence` value. `flags` are used to hint the beginning of the revision walk and are the first block under the `#include`s in `revision.h`. The most likely ones to be set in the `rev_cmdline_info` are `UNINTERESTING` and `BOTTOM`, but these same flags can be used during the walk, as well. === `struct rev_info` This one is quite a bit longer, and many fields are only used during the walk by `revision.c` - not configuration options. Most of the configurable flags in `struct rev_info` have a mirror in `Documentation/rev-list-options.txt`. It's a good idea to take some time and read through that document. == Basic Commit Walk First, let's see if we can replicate the output of `git log --oneline`. We'll refer back to the implementation frequently to discover norms when performing an object walk of our own. To do so, we'll first find all the commits, in order, which preceded the current commit. We'll extract the name and subject of the commit from each. Ideally, we will also be able to find out which ones are currently at the tip of various branches. === Setting Up Preparing for your object walk has some distinct stages. 1. Perform default setup for this mode, and others which may be invoked. 2. Check configuration files for relevant settings. 3. Set up the `rev_info` struct. 4. Tweak the initialized `rev_info` to suit the current walk. 5. Prepare the `rev_info` for the walk. 6. Iterate over the objects, processing each one. ==== Default Setups Before examining configuration files which may modify command behavior, set up default state for switches or options your command may have. If your command utilizes other Git components, ask them to set up their default states as well. For instance, `git log` takes advantage of `grep` and `diff` functionality, so its `init_log_defaults()` sets its own state (`decoration_style`) and asks `grep` and `diff` to initialize themselves by calling each of their initialization functions. ==== Configuring From `.gitconfig` Next, we should have a look at any relevant configuration settings (i.e., settings readable and settable from `git config`). This is done by providing a callback to `git_config()`; within that callback, you can also invoke methods from other components you may need that need to intercept these options. Your callback will be invoked once per each configuration value which Git knows about (global, local, worktree, etc.). Similarly to the default values, we don't have anything to do here yet ourselves; however, we should call `git_default_config()` if we aren't calling any other existing config callbacks. Add a new function to `builtin/walken.c`. We'll also need to include the `config.h` header: ---- #include "config.h" ... static int git_walken_config(const char *var, const char *value, void *cb) { /* * For now, we don't have any custom configuration, so fall back to * the default config. */ return git_default_config(var, value, cb); } ---- Make sure to invoke `git_config()` with it in your `cmd_walken()`: ---- int cmd_walken(int argc, const char **argv, const char *prefix) { ... git_config(git_walken_config, NULL); ... } ---- ==== Setting Up `rev_info` Now that we've gathered external configuration and options, it's time to initialize the `rev_info` object which we will use to perform the walk. This is typically done by calling `repo_init_revisions()` with the repository you intend to target, as well as the `prefix` argument of `cmd_walken` and your `rev_info` struct. Add the `struct rev_info` and the `repo_init_revisions()` call. We'll also need to include the `revision.h` header: ---- #include "revision.h" ... int cmd_walken(int argc, const char **argv, const char *prefix) { /* This can go wherever you like in your declarations.*/ struct rev_info rev; ... /* This should go after the git_config() call. */ repo_init_revisions(the_repository, &rev, prefix); ... } ---- ==== Tweaking `rev_info` For the Walk We're getting close, but we're still not quite ready to go. Now that `rev` is initialized, we can modify it to fit our needs. This is usually done within a helper for clarity, so let's add one: ---- static void final_rev_info_setup(struct rev_info *rev) { /* * We want to mimic the appearance of `git log --oneline`, so let's * force oneline format. */ get_commit_format("oneline", rev); /* Start our object walk at HEAD. */ add_head_to_pending(rev); } ---- [NOTE] ==== Instead of using the shorthand `add_head_to_pending()`, you could do something like this: ---- struct setup_revision_opt opt; memset(&opt, 0, sizeof(opt)); opt.def = "HEAD"; opt.revarg_opt = REVARG_COMMITTISH; setup_revisions(argc, argv, rev, &opt); ---- Using a `setup_revision_opt` gives you finer control over your walk's starting point. ==== Then let's invoke `final_rev_info_setup()` after the call to `repo_init_revisions()`: ---- int cmd_walken(int argc, const char **argv, const char *prefix) { ... final_rev_info_setup(&rev); ... } ---- Later, we may wish to add more arguments to `final_rev_info_setup()`. But for now, this is all we need. ==== Preparing `rev_info` For the Walk Now that `rev` is all initialized and configured, we've got one more setup step before we get rolling. We can do this in a helper, which will both prepare the `rev_info` for the walk, and perform the walk itself. Let's start the helper with the call to `prepare_revision_walk()`, which can return an error without dying on its own: ---- static void walken_commit_walk(struct rev_info *rev) { if (prepare_revision_walk(rev)) die(_("revision walk setup failed")); } ---- NOTE: `die()` prints to `stderr` and exits the program. Since it will print to `stderr` it's likely to be seen by a human, so we will localize it. ==== Performing the Walk! Finally! We are ready to begin the walk itself. Now we can see that `rev_info` can also be used as an iterator; we move to the next item in the walk by using `get_revision()` repeatedly. Add the listed variable declarations at the top and the walk loop below the `prepare_revision_walk()` call within your `walken_commit_walk()`: ---- #include "pretty.h" ... static void walken_commit_walk(struct rev_info *rev) { struct commit *commit; struct strbuf prettybuf = STRBUF_INIT; ... while ((commit = get_revision(rev))) { strbuf_reset(&prettybuf); pp_commit_easy(CMIT_FMT_ONELINE, commit, &prettybuf); puts(prettybuf.buf); } strbuf_release(&prettybuf); } ---- NOTE: `puts()` prints a `char*` to `stdout`. Since this is the part of the command we expect to be machine-parsed, we're sending it directly to stdout. Give it a shot. ---- $ make $ ./bin-wrappers/git walken ---- You should see all of the subject lines of all the commits in your tree's history, in order, ending with the initial commit, "Initial revision of "git", the information manager from hell". Congratulations! You've written your first revision walk. You can play with printing some additional fields from each commit if you're curious; have a look at the functions available in `commit.h`. === Adding a Filter Next, let's try to filter the commits we see based on their author. This is equivalent to running `git log --author=<pattern>`. We can add a filter by modifying `rev_info.grep_filter`, which is a `struct grep_opt`. First some setup. Add `grep_config()` to `git_walken_config()`: ---- static int git_walken_config(const char *var, const char *value, void *cb) { grep_config(var, value, cb); return git_default_config(var, value, cb); } ---- Next, we can modify the `grep_filter`. This is done with convenience functions found in `grep.h`. For fun, we're filtering to only commits from folks using a `gmail.com` email address - a not-very-precise guess at who may be working on Git as a hobby. Since we're checking the author, which is a specific line in the header, we'll use the `append_header_grep_pattern()` helper. We can use the `enum grep_header_field` to indicate which part of the commit header we want to search. In `final_rev_info_setup()`, add your filter line: ---- static void final_rev_info_setup(int argc, const char **argv, const char *prefix, struct rev_info *rev) { ... append_header_grep_pattern(&rev->grep_filter, GREP_HEADER_AUTHOR, "gmail"); compile_grep_patterns(&rev->grep_filter); ... } ---- `append_header_grep_pattern()` adds your new "gmail" pattern to `rev_info`, but it won't work unless we compile it with `compile_grep_patterns()`. NOTE: If you are using `setup_revisions()` (for example, if you are passing a `setup_revision_opt` instead of using `add_head_to_pending()`), you don't need to call `compile_grep_patterns()` because `setup_revisions()` calls it for you. NOTE: We could add the same filter via the `append_grep_pattern()` helper if we wanted to, but `append_header_grep_pattern()` adds the `enum grep_context` and `enum grep_pat_token` for us. === Changing the Order There are a few ways that we can change the order of the commits during a revision walk. Firstly, we can use the `enum rev_sort_order` to choose from some typical orderings. `topo_order` is the same as `git log --topo-order`: we avoid showing a parent before all of its children have been shown, and we avoid mixing commits which are in different lines of history. (`git help log`'s section on `--topo-order` has a very nice diagram to illustrate this.) Let's see what happens when we run with `REV_SORT_BY_COMMIT_DATE` as opposed to `REV_SORT_BY_AUTHOR_DATE`. Add the following: ---- static void final_rev_info_setup(int argc, const char **argv, const char *prefix, struct rev_info *rev) { ... rev->topo_order = 1; rev->sort_order = REV_SORT_BY_COMMIT_DATE; ... } ---- Let's output this into a file so we can easily diff it with the walk sorted by author date. ---- $ make $ ./bin-wrappers/git walken > commit-date.txt ---- Then, let's sort by author date and run it again. ---- static void final_rev_info_setup(int argc, const char **argv, const char *prefix, struct rev_info *rev) { ... rev->topo_order = 1; rev->sort_order = REV_SORT_BY_AUTHOR_DATE; ... } ---- ---- $ make $ ./bin-wrappers/git walken > author-date.txt ---- Finally, compare the two. This is a little less helpful without object names or dates, but hopefully we get the idea. ---- $ diff -u commit-date.txt author-date.txt ---- This display indicates that commits can be reordered after they're written, for example with `git rebase`. Let's try one more reordering of commits. `rev_info` exposes a `reverse` flag. Set that flag somewhere inside of `final_rev_info_setup()`: ---- static void final_rev_info_setup(int argc, const char **argv, const char *prefix, struct rev_info *rev) { ... rev->reverse = 1; ... } ---- Run your walk again and note the difference in order. (If you remove the grep pattern, you should see the last commit this call gives you as your current HEAD.) == Basic Object Walk So far we've been walking only commits. But Git has more types of objects than that! Let's see if we can walk _all_ objects, and find out some information about each one. We can base our work on an example. `git pack-objects` prepares all kinds of objects for packing into a bitmap or packfile. The work we are interested in resides in `builtins/pack-objects.c:get_object_list()`; examination of that function shows that the all-object walk is being performed by `traverse_commit_list()` or `traverse_commit_list_filtered()`. Those two functions reside in `list-objects.c`; examining the source shows that, despite the name, these functions traverse all kinds of objects. Let's have a look at the arguments to `traverse_commit_list()`. - `struct rev_info *revs`: This is the `rev_info` used for the walk. If its `filter` member is not `NULL`, then `filter` contains information for how to filter the object list. - `show_commit_fn show_commit`: A callback which will be used to handle each individual commit object. - `show_object_fn show_object`: A callback which will be used to handle each non-commit object (so each blob, tree, or tag). - `void *show_data`: A context buffer which is passed in turn to `show_commit` and `show_object`. In addition, `traverse_commit_list_filtered()` has an additional parameter: - `struct oidset *omitted`: A linked-list of object IDs which the provided filter caused to be omitted. It looks like these methods use callbacks we provide instead of needing us to call it repeatedly ourselves. Cool! Let's add the callbacks first. For the sake of this tutorial, we'll simply keep track of how many of each kind of object we find. At file scope in `builtin/walken.c` add the following tracking variables: ---- static int commit_count; static int tag_count; static int blob_count; static int tree_count; ---- Commits are handled by a different callback than other objects; let's do that one first: ---- static void walken_show_commit(struct commit *cmt, void *buf) { commit_count++; } ---- The `cmt` argument is fairly self-explanatory. But it's worth mentioning that the `buf` argument is actually the context buffer that we can provide to the traversal calls - `show_data`, which we mentioned a moment ago. Since we have the `struct commit` object, we can look at all the same parts that we looked at in our earlier commit-only walk. For the sake of this tutorial, though, we'll just increment the commit counter and move on. The callback for non-commits is a little different, as we'll need to check which kind of object we're dealing with: ---- static void walken_show_object(struct object *obj, const char *str, void *buf) { switch (obj->type) { case OBJ_TREE: tree_count++; break; case OBJ_BLOB: blob_count++; break; case OBJ_TAG: tag_count++; break; case OBJ_COMMIT: BUG("unexpected commit object in walken_show_object\n"); default: BUG("unexpected object type %s in walken_show_object\n", type_name(obj->type)); } } ---- Again, `obj` is fairly self-explanatory, and we can guess that `buf` is the same context pointer that `walken_show_commit()` receives: the `show_data` argument to `traverse_commit_list()` and `traverse_commit_list_filtered()`. Finally, `str` contains the name of the object, which ends up being something like `foo.txt` (blob), `bar/baz` (tree), or `v1.2.3` (tag). To help assure us that we aren't double-counting commits, we'll include some complaining if a commit object is routed through our non-commit callback; we'll also complain if we see an invalid object type. Since those two cases should be unreachable, and would only change in the event of a semantic change to the Git codebase, we complain by using `BUG()` - which is a signal to a developer that the change they made caused unintended consequences, and the rest of the codebase needs to be updated to understand that change. `BUG()` is not intended to be seen by the public, so it is not localized. Our main object walk implementation is substantially different from our commit walk implementation, so let's make a new function to perform the object walk. We can perform setup which is applicable to all objects here, too, to keep separate from setup which is applicable to commit-only walks. We'll start by enabling all types of objects in the `struct rev_info`. We'll also turn on `tree_blobs_in_commit_order`, which means that we will walk a commit's tree and everything it points to immediately after we find each commit, as opposed to waiting for the end and walking through all trees after the commit history has been discovered. With the appropriate settings configured, we are ready to call `prepare_revision_walk()`. ---- static void walken_object_walk(struct rev_info *rev) { rev->tree_objects = 1; rev->blob_objects = 1; rev->tag_objects = 1; rev->tree_blobs_in_commit_order = 1; if (prepare_revision_walk(rev)) die(_("revision walk setup failed")); commit_count = 0; tag_count = 0; blob_count = 0; tree_count = 0; ---- Let's start by calling just the unfiltered walk and reporting our counts. Complete your implementation of `walken_object_walk()`. We'll also need to include the `list-objects.h` header. ---- #include "list-objects.h" ... traverse_commit_list(rev, walken_show_commit, walken_show_object, NULL); printf("commits %d\nblobs %d\ntags %d\ntrees %d\n", commit_count, blob_count, tag_count, tree_count); } ---- NOTE: This output is intended to be machine-parsed. Therefore, we are not sending it to `trace_printf()`, and we are not localizing it - we need scripts to be able to count on the formatting to be exactly the way it is shown here. If we were intending this output to be read by humans, we would need to localize it with `_()`. Finally, we'll ask `cmd_walken()` to use the object walk instead. Discussing command line options is out of scope for this tutorial, so we'll just hardcode a branch we can change at compile time. Where you call `final_rev_info_setup()` and `walken_commit_walk()`, instead branch like so: ---- if (1) { add_head_to_pending(&rev); walken_object_walk(&rev); } else { final_rev_info_setup(argc, argv, prefix, &rev); walken_commit_walk(&rev); } ---- NOTE: For simplicity, we've avoided all the filters and sorts we applied in `final_rev_info_setup()` and simply added `HEAD` to our pending queue. If you want, you can certainly use the filters we added before by moving `final_rev_info_setup()` out of the conditional and removing the call to `add_head_to_pending()`. Now we can try to run our command! It should take noticeably longer than the commit walk, but an examination of the output will give you an idea why. Your output should look similar to this example, but with different counts: ---- Object walk completed. Found 55733 commits, 100274 blobs, 0 tags, and 104210 trees. ---- This makes sense. We have more trees than commits because the Git project has lots of subdirectories which can change, plus at least one tree per commit. We have no tags because we started on a commit (`HEAD`) and while tags can point to commits, commits can't point to tags. NOTE: You will have different counts when you run this yourself! The number of objects grows along with the Git project. === Adding a Filter There are a handful of filters that we can apply to the object walk laid out in `Documentation/rev-list-options.txt`. These filters are typically useful for operations such as creating packfiles or performing a partial clone. They are defined in `list-objects-filter-options.h`. For the purposes of this tutorial we will use the "tree:1" filter, which causes the walk to omit all trees and blobs which are not directly referenced by commits reachable from the commit in `pending` when the walk begins. (`pending` is the list of objects which need to be traversed during a walk; you can imagine a breadth-first tree traversal to help understand. In our case, that means we omit trees and blobs not directly referenced by `HEAD` or `HEAD`'s history, because we begin the walk with only `HEAD` in the `pending` list.) For now, we are not going to track the omitted objects, so we'll replace those parameters with `NULL`. For the sake of simplicity, we'll add a simple build-time branch to use our filter or not. Preface the line calling `traverse_commit_list()` with the following, which will remind us which kind of walk we've just performed: ---- if (0) { /* Unfiltered: */ trace_printf(_("Unfiltered object walk.\n")); } else { trace_printf( _("Filtered object walk with filterspec 'tree:1'.\n")); CALLOC_ARRAY(rev->filter, 1); parse_list_objects_filter(rev->filter, "tree:1"); } traverse_commit_list(rev, walken_show_commit, walken_show_object, NULL); ---- The `rev->filter` member is usually built directly from a command line argument, so the module provides an easy way to build one from a string. Even though we aren't taking user input right now, we can still build one with a hardcoded string using `parse_list_objects_filter()`. With the filter spec "tree:1", we are expecting to see _only_ the root tree for each commit; therefore, the tree object count should be less than or equal to the number of commits. (For an example of why that's true: `git commit --revert` points to the same tree object as its grandparent.) === Counting Omitted Objects We also have the capability to enumerate all objects which were omitted by a filter, like with `git log --filter=<spec> --filter-print-omitted`. Asking `traverse_commit_list_filtered()` to populate the `omitted` list means that our object walk does not perform any better than an unfiltered object walk; all reachable objects are walked in order to populate the list. First, add the `struct oidset` and related items we will use to iterate it: ---- #include "oidset.h" ... static void walken_object_walk( ... struct oidset omitted; struct oidset_iter oit; struct object_id *oid = NULL; int omitted_count = 0; oidset_init(&omitted, 0); ... ---- Modify the call to `traverse_commit_list_filtered()` to include your `omitted` object: ---- ... traverse_commit_list_filtered(rev, walken_show_commit, walken_show_object, NULL, &omitted); ... ---- Then, after your traversal, the `oidset` traversal is pretty straightforward. Count all the objects within and modify the print statement: ---- /* Count the omitted objects. */ oidset_iter_init(&omitted, &oit); while ((oid = oidset_iter_next(&oit))) omitted_count++; printf("commits %d\nblobs %d\ntags %d\ntrees %d\nomitted %d\n", commit_count, blob_count, tag_count, tree_count, omitted_count); ---- By running your walk with and without the filter, you should find that the total object count in each case is identical. You can also time each invocation of the `walken` subcommand, with and without `omitted` being passed in, to confirm to yourself the runtime impact of tracking all omitted objects. === Changing the Order Finally, let's demonstrate that you can also reorder walks of all objects, not just walks of commits. First, we'll make our handlers chattier - modify `walken_show_commit()` and `walken_show_object()` to print the object as they go: ---- #include "hex.h" ... static void walken_show_commit(struct commit *cmt, void *buf) { trace_printf("commit: %s\n", oid_to_hex(&cmt->object.oid)); commit_count++; } static void walken_show_object(struct object *obj, const char *str, void *buf) { trace_printf("%s: %s\n", type_name(obj->type), oid_to_hex(&obj->oid)); ... } ---- NOTE: Since we will be examining this output directly as humans, we'll use `trace_printf()` here. Additionally, since this change introduces a significant number of printed lines, using `trace_printf()` will allow us to easily silence those lines without having to recompile. (Leave the counter increment logic in place.) With only that change, run again (but save yourself some scrollback): ---- $ GIT_TRACE=1 ./bin-wrappers/git walken | head -n 10 ---- Take a look at the top commit with `git show` and the object ID you printed; it should be the same as the output of `git show HEAD`. Next, let's change a setting on our `struct rev_info` within `walken_object_walk()`. Find where you're changing the other settings on `rev`, such as `rev->tree_objects` and `rev->tree_blobs_in_commit_order`, and add the `reverse` setting at the bottom: ---- ... rev->tree_objects = 1; rev->blob_objects = 1; rev->tag_objects = 1; rev->tree_blobs_in_commit_order = 1; rev->reverse = 1; ... ---- Now, run again, but this time, let's grab the last handful of objects instead of the first handful: ---- $ make $ GIT_TRACE=1 ./bin-wrappers git walken | tail -n 10 ---- The last commit object given should have the same OID as the one we saw at the top before, and running `git show <oid>` with that OID should give you again the same results as `git show HEAD`. Furthermore, if you run and examine the first ten lines again (with `head` instead of `tail` like we did before applying the `reverse` setting), you should see that now the first commit printed is the initial commit, `e83c5163`. == Wrapping Up Let's review. In this tutorial, we: - Built a commit walk from the ground up - Enabled a grep filter for that commit walk - Changed the sort order of that filtered commit walk - Built an object walk (tags, commits, trees, and blobs) from the ground up - Learned how to add a filter-spec to an object walk - Changed the display order of the filtered object walk
Save
cmd:
run