Builtin git-tar-tree.
PATCH 1/8 Builtin git-ls-files.
In reply to a message not in the archiveFrom: Peter Eriksen <[email protected]>
---
bc0dc50a3e9208011a39adc653e3463aa3ab4886
Makefile | 6 +++--- ls-files.c => builtin-ls-files.c | 3 ++- builtin.h | 1 + git.c | 3 ++- 4 files changed, 8 insertions(+), 5 deletions(-) rename ls-files.c => builtin-ls-files.c (100%)
bc0dc50a3e9208011a39adc653e3463aa3ab4886
Makefile +3 -3
@@ -155,7 +155,7 @@ PROGRAMS = \ git-diff-index$X git-diff-stages$X \ git-diff-tree$X git-fetch-pack$X git-fsck-objects$X \ git-hash-object$X git-index-pack$X git-local-fetch$X \ - git-ls-files$X git-ls-tree$X git-mailinfo$X git-merge-base$X \ + git-ls-tree$X git-mailinfo$X git-merge-base$X \ git-merge-index$X git-mktag$X git-mktree$X git-pack-objects$X git-patch-id$X \ git-peek-remote$X git-prune-packed$X git-read-tree$X \ git-receive-pack$X git-rev-parse$X \
@@ -171,7 +171,7 @@ PROGRAMS = \ BUILT_INS = git-log$X git-whatchanged$X git-show$X \ git-count-objects$X git-diff$X git-push$X \ git-grep$X git-rev-list$X git-check-ref-format$X \ - git-init-db$X + git-init-db$X git-ls-files$X # what 'all' will build and 'install' will install, in gitexecdir ALL_PROGRAMS = $(PROGRAMS) $(SIMPLE_PROGRAMS) $(SCRIPTS)
@@ -220,7 +220,7 @@ LIB_OBJS = \ BUILTIN_OBJS = \ builtin-log.o builtin-help.o builtin-count.o builtin-diff.o builtin-push.o \ builtin-grep.o builtin-rev-list.o builtin-check-ref-format.o \ - builtin-init-db.o + builtin-init-db.o builtin-ls-files.o GITLIBS = $(LIB_FILE) $(XDIFF_LIB) LIBS = $(GITLIBS) -lz
builtin-ls-files.c renamed from ls-files.c +2 -1
@@ -10,6 +10,7 @@ #include <fnmatch.h>#include "cache.h" #include "quote.h" +#include "builtin.h" static int abbrev =0 ;static int show_deleted =0 ;
@@ -648,7 +649,7 @@ static const char ls_files_usage[] ="[ --exclude-per-directory=<filename> ] [--full-name] [--abbrev] " "[--] [<file>]*" ; -int main (int argc,const char **argv) +int cmd_ls_files (int argc,const char **argv,char ** envp) {int i;int exc_given =0 ;
builtin.h +1 -0
@@ -27,5 +27,6 @@ extern int cmd_grep(int argc, const charextern int cmd_rev_list (int argc,const char **argv,char **envp);extern int cmd_check_ref_format (int argc,const char **argv,char **envp);extern int cmd_init_db (int argc,const char **argv,char **envp); +extern int cmd_ls_files (int argc,const char **argv,char **envp);#endif
git.c +2 -1
@@ -52,7 +52,8 @@ static void handle_internal_command(int { "grep", cmd_grep }, { "rev-list", cmd_rev_list }, { "init-db", cmd_init_db }, - { "check-ref-format", cmd_check_ref_format } + { "check-ref-format", cmd_check_ref_format }, + { "ls-files", cmd_ls_files } };int i;
Signature · 1 line
1.3.3.g288c
PATCH 2/8 Builtin git-ls-tree.
In reply to a message not in the archiveFrom: Peter Eriksen <[email protected]>
---
419257801e5bc91fc435bd4ff9eb42aa8063ffbb
Makefile | 6 +++--- ls-tree.c => builtin-ls-tree.c | 3 ++- builtin.h | 1 + git.c | 3 ++- 4 files changed, 8 insertions(+), 5 deletions(-) rename ls-tree.c => builtin-ls-tree.c (98%)
419257801e5bc91fc435bd4ff9eb42aa8063ffbb
Makefile +3 -3
@@ -155,7 +155,7 @@ PROGRAMS = \ git-diff-index$X git-diff-stages$X \ git-diff-tree$X git-fetch-pack$X git-fsck-objects$X \ git-hash-object$X git-index-pack$X git-local-fetch$X \ - git-ls-tree$X git-mailinfo$X git-merge-base$X \ + git-mailinfo$X git-merge-base$X \ git-merge-index$X git-mktag$X git-mktree$X git-pack-objects$X git-patch-id$X \ git-peek-remote$X git-prune-packed$X git-read-tree$X \ git-receive-pack$X git-rev-parse$X \
@@ -171,7 +171,7 @@ PROGRAMS = \ BUILT_INS = git-log$X git-whatchanged$X git-show$X \ git-count-objects$X git-diff$X git-push$X \ git-grep$X git-rev-list$X git-check-ref-format$X \ - git-init-db$X git-ls-files$X + git-init-db$X git-ls-files$X git-ls-tree$X # what 'all' will build and 'install' will install, in gitexecdir ALL_PROGRAMS = $(PROGRAMS) $(SIMPLE_PROGRAMS) $(SCRIPTS)
@@ -220,7 +220,7 @@ LIB_OBJS = \ BUILTIN_OBJS = \ builtin-log.o builtin-help.o builtin-count.o builtin-diff.o builtin-push.o \ builtin-grep.o builtin-rev-list.o builtin-check-ref-format.o \ - builtin-init-db.o builtin-ls-files.o + builtin-init-db.o builtin-ls-files.o builtin-ls-tree.o GITLIBS = $(LIB_FILE) $(XDIFF_LIB) LIBS = $(GITLIBS) -lz
builtin-ls-tree.c renamed from ls-tree.c +2 -1
@@ -7,6 +7,7 @@ #include "cache.h"#include "blob.h" #include "tree.h" #include "quote.h" +#include "builtin.h" static int line_termination ='\n' ;#define LS_RECURSIVE 1
@@ -84,7 +85,7 @@ static int show_tree(unsigned char *sha1return retval; } -int main (int argc,const char **argv) +int cmd_ls_tree (int argc,const char **argv,char **envp) {unsigned char sha1[20 ];struct tree *tree;
builtin.h +1 -0
@@ -28,5 +28,6 @@ extern int cmd_rev_list(int argc, constextern int cmd_check_ref_format (int argc,const char **argv,char **envp);extern int cmd_init_db (int argc,const char **argv,char **envp);extern int cmd_ls_files (int argc,const char **argv,char **envp); +extern int cmd_ls_tree (int argc,const char **argv,char **envp);#endif
git.c +2 -1
@@ -53,7 +53,8 @@ static void handle_internal_command(int { "rev-list", cmd_rev_list }, { "init-db", cmd_init_db }, { "check-ref-format", cmd_check_ref_format }, - { "ls-files", cmd_ls_files } + { "ls-files", cmd_ls_files }, + { "ls-tree", cmd_ls_tree } };int i;
Signature · 1 line
1.3.3.g288c
PATCH 3/8 Builtin git-tar-tree.
In reply to a message not in the archiveFrom: Peter Eriksen <[email protected]>
---
9860ed2d4a598ad100c3b4f6b07dd0a88a4547a6
Makefile | 8 +++++--- tar-tree.c => builtin-tar-tree.c | 3 ++- builtin.h | 1 + git.c | 3 ++- 4 files changed, 10 insertions(+), 5 deletions(-) rename tar-tree.c => builtin-tar-tree.c (99%)
9860ed2d4a598ad100c3b4f6b07dd0a88a4547a6
Makefile +5 -3
@@ -161,7 +161,7 @@ PROGRAMS = \ git-receive-pack$X git-rev-parse$X \ git-send-pack$X git-show-branch$X git-shell$X \ git-show-index$X git-ssh-fetch$X \ - git-ssh-upload$X git-tar-tree$X git-unpack-file$X \ + git-ssh-upload$X git-unpack-file$X \ git-unpack-objects$X git-update-index$X git-update-server-info$X \ git-upload-pack$X git-verify-pack$X git-write-tree$X \ git-update-ref$X git-symbolic-ref$X \
@@ -171,7 +171,8 @@ PROGRAMS = \ BUILT_INS = git-log$X git-whatchanged$X git-show$X \ git-count-objects$X git-diff$X git-push$X \ git-grep$X git-rev-list$X git-check-ref-format$X \ - git-init-db$X git-ls-files$X git-ls-tree$X + git-init-db$X git-ls-files$X git-ls-tree$X \ + git-tar-tree$X # what 'all' will build and 'install' will install, in gitexecdir ALL_PROGRAMS = $(PROGRAMS) $(SIMPLE_PROGRAMS) $(SCRIPTS)
@@ -220,7 +221,8 @@ LIB_OBJS = \ BUILTIN_OBJS = \ builtin-log.o builtin-help.o builtin-count.o builtin-diff.o builtin-push.o \ builtin-grep.o builtin-rev-list.o builtin-check-ref-format.o \ - builtin-init-db.o builtin-ls-files.o builtin-ls-tree.o + builtin-init-db.o builtin-ls-files.o builtin-ls-tree.o \ + builtin-tar-tree.o GITLIBS = $(LIB_FILE) $(XDIFF_LIB) LIBS = $(GITLIBS) -lz
builtin-tar-tree.c renamed from tar-tree.c +2 -1
@@ -7,6 +7,7 @@ #include "tree-walk.h"#include "commit.h" #include "strbuf.h" #include "tar.h" +#include "builtin.h" #define RECORDSIZE (512)#define BLOCKSIZE (RECORDSIZE * 20)
@@ -301,7 +302,7 @@ static void traverse_tree(struct tree_de } } -int main (int argc,char **argv) +int cmd_tar_tree (int argc,const char **argv,char ** envp) {unsigned char sha1[20 ], tree_sha1[20 ];struct commit *commit;
builtin.h +1 -0
@@ -29,5 +29,6 @@ extern int cmd_check_ref_format(int argcextern int cmd_init_db (int argc,const char **argv,char **envp);extern int cmd_ls_files (int argc,const char **argv,char **envp);extern int cmd_ls_tree (int argc,const char **argv,char **envp); +extern int cmd_tar_tree (int argc,const char **argv,char **envp);#endif
git.c +2 -1
@@ -54,7 +54,8 @@ static void handle_internal_command(int { "init-db", cmd_init_db }, { "check-ref-format", cmd_check_ref_format }, { "ls-files", cmd_ls_files }, - { "ls-tree", cmd_ls_tree } + { "ls-tree", cmd_ls_tree }, + { "tar-tree", cmd_tar_tree } };int i;
Signature · 1 line
1.3.3.g288c
Re: Make more commands builtin
In reply to a message not in the archiveBtw.
I used these commands to produce the patch series:
git diff --stat -C 24b65a30015aedd..pe/builtin
git-send-email --no-chain-reply-to --compose \
[email protected] --not-signed-off-by-cc \
--quiet \
--subject="Make more commands builtin" \
[email protected] Patches/*Is this a reasonable way to do it?
Peter
Re: Make more commands builtin
Quoted 10 lines · Peter Eriksen
Btw.
I used these commands to produce the patch series:
git diff --stat -C 24b65a30015aedd..pe/builtin
git-send-email --no-chain-reply-to --compose \ [email protected] --not-signed-off-by-cc \ --quiet \ --subject="Make more commands builtin" \ [email protected] Patches/*
I wonder why the patches themselves are not replies to the main/summary email, i.e. "Make more commands builtin" email...
Signature · 2 lines
Jakub Narebski Warsaw, Poland
Re: Make more commands builtin
Quoted 13 lines · Jakub Narebski
Quoted 10 lines · Peter Eriksen
Btw.
I used these commands to produce the patch series:
git diff --stat -C 24b65a30015aedd..pe/builtin
git-send-email --no-chain-reply-to --compose \ [email protected] --not-signed-off-by-cc \ --quiet \ --subject="Make more commands builtin" \ [email protected] Patches/*
Quoted 2 lines
I wonder why the patches themselves are not replies to the main/summary email, i.e. "Make more commands builtin" email...
It seems thay are:
Subject: Make more commands builtin
Message-Id: <11483865361243-git-send-email-1>
Subject: [PATCH 1/8] Builtin git-ls-files.
Message-Id: <11483865362613-git-send-email-1>
In-Reply-To: <11483865361243-git-send-email-1>
Subject: [PATCH 2/8] Builtin git-ls-tree.
Message-Id: <11483865362923-git-send-email-1>
In-Reply-To: <11483865361243-git-send-email-1>
Peter
Re: Make more commands builtin
Quoted 17 lines · Peter Eriksen
Quoted 13 lines · Jakub Narebski
Quoted 10 lines · Peter Eriksen
Btw.
I used these commands to produce the patch series:
git diff --stat -C 24b65a30015aedd..pe/builtin
git-send-email --no-chain-reply-to --compose \ [email protected] --not-signed-off-by-cc \ --quiet \ --subject="Make more commands builtin" \ [email protected] Patches/*Quoted 2 lines
I wonder why the patches themselves are not replies to the main/summary email, i.e. "Make more commands builtin" email...
Quoted 8 lines
It seems thay are:
Subject: Make more commands builtin
Message-Id: <11483865361243-git-send-email-1>Subject: [PATCH 1/8] Builtin git-ls-files.
Message-Id: <11483865362613-git-send-email-1>
In-Reply-To: <11483865361243-git-send-email-1>
Ahh... I'm reading git mailing list through GMane NNTP interface. It would be nice if git-send-email added 'References:' Usenet/news header in addition to email one 'In-Reply-To:'.
Signature · 2 lines
Jakub Narebski Warsaw, Poland
Re: Make more commands builtin
Quoted 24 lines · Jakub Narebski
Quoted 22 lines · Peter Eriksen
Quoted 13 lines · Jakub Narebski
Quoted 10 lines · Peter Eriksen
Btw.
I used these commands to produce the patch series:
git diff --stat -C 24b65a30015aedd..pe/builtin
git-send-email --no-chain-reply-to --compose \ [email protected] --not-signed-off-by-cc \ --quiet \ --subject="Make more commands builtin" \ [email protected] Patches/*Quoted 2 lines
I wonder why the patches themselves are not replies to the main/summary email, i.e. "Make more commands builtin" email...
It seems thay are:
Subject: Make more commands builtin
Message-Id: <11483865361243-git-send-email-1>
Quoted 7 lines
Quoted 3 lines
Subject: [PATCH 1/8] Builtin git-ls-files.
Message-Id: <11483865362613-git-send-email-1>
In-Reply-To: <11483865361243-git-send-email-1>Ahh... I'm reading git mailing list through GMane NNTP interface. It would be nice if git-send-email added 'References:' Usenet/news header in addition to email one 'In-Reply-To:'.
Things would have worked better if --no-chain-reply-to had *not* been used, at least for those of us reading via mutt.
I'm still in the process of getting my machines setup after moving, when I get sorted out, I'll try to look into this.
PATCH 4/8 Builtin git-read-tree.
In reply to a message not in the archiveFrom: Peter Eriksen <[email protected]>
---
baba8c18d8a5fff876d16a434b49677cd3ebbdb0
Makefile | 6 +++--- read-tree.c => builtin-read-tree.c | 3 ++- builtin.h | 1 + git.c | 3 ++- 4 files changed, 8 insertions(+), 5 deletions(-) rename read-tree.c => builtin-read-tree.c (100%)
baba8c18d8a5fff876d16a434b49677cd3ebbdb0
Makefile +3 -3
@@ -157,7 +157,7 @@ PROGRAMS = \ git-hash-object$X git-index-pack$X git-local-fetch$X \ git-mailinfo$X git-merge-base$X \ git-merge-index$X git-mktag$X git-mktree$X git-pack-objects$X git-patch-id$X \ - git-peek-remote$X git-prune-packed$X git-read-tree$X \ + git-peek-remote$X git-prune-packed$X \ git-receive-pack$X git-rev-parse$X \ git-send-pack$X git-show-branch$X git-shell$X \ git-show-index$X git-ssh-fetch$X \
@@ -172,7 +172,7 @@ BUILT_INS = git-log$X git-whatchanged$X git-count-objects$X git-diff$X git-push$X \ git-grep$X git-rev-list$X git-check-ref-format$X \ git-init-db$X git-ls-files$X git-ls-tree$X \ - git-tar-tree$X + git-tar-tree$X git-read-tree$X # what 'all' will build and 'install' will install, in gitexecdir ALL_PROGRAMS = $(PROGRAMS) $(SIMPLE_PROGRAMS) $(SCRIPTS)
@@ -222,7 +222,7 @@ BUILTIN_OBJS = \ builtin-log.o builtin-help.o builtin-count.o builtin-diff.o builtin-push.o \ builtin-grep.o builtin-rev-list.o builtin-check-ref-format.o \ builtin-init-db.o builtin-ls-files.o builtin-ls-tree.o \ - builtin-tar-tree.o + builtin-tar-tree.o builtin-read-tree.o GITLIBS = $(LIB_FILE) $(XDIFF_LIB) LIBS = $(GITLIBS) -lz
builtin-read-tree.c renamed from read-tree.c +2 -1
@@ -11,6 +11,7 @@ #include "object.h"#include "tree.h" #include <sys/time.h> #include <signal.h> +#include "builtin.h" static int reset =0 ;static int merge =0 ;
@@ -763,7 +764,7 @@ static const char read_tree_usage[] = "gstatic struct cache_file cache_file; -int main (int argc,char **argv) +int cmd_read_tree (int argc,const char **argv,char **envp) {int i, newfd, stage =0 ;unsigned char sha1[20 ];
builtin.h +1 -0
@@ -30,5 +30,6 @@ extern int cmd_init_db(int argc, const cextern int cmd_ls_files (int argc,const char **argv,char **envp);extern int cmd_ls_tree (int argc,const char **argv,char **envp);extern int cmd_tar_tree (int argc,const char **argv,char **envp); +extern int cmd_read_tree (int argc,const char **argv,char **envp);#endif
git.c +2 -1
@@ -55,7 +55,8 @@ static void handle_internal_command(int { "check-ref-format", cmd_check_ref_format }, { "ls-files", cmd_ls_files }, { "ls-tree", cmd_ls_tree }, - { "tar-tree", cmd_tar_tree } + { "tar-tree", cmd_tar_tree }, + { "read-tree", cmd_read_tree } };int i;
Signature · 1 line
1.3.3.g288c
PATCH 5/8 Builtin git-commit-tree.
In reply to a message not in the archiveFrom: Peter Eriksen <[email protected]>
---
762e5a2efcde796d84c573fe8bf3224c9fbf3588
Makefile | 6 +++--- commit-tree.c => builtin-commit-tree.c | 3 ++- builtin.h | 1 + git.c | 3 ++- 4 files changed, 8 insertions(+), 5 deletions(-) rename commit-tree.c => builtin-commit-tree.c (98%)
762e5a2efcde796d84c573fe8bf3224c9fbf3588
Makefile +3 -3
@@ -150,7 +150,7 @@ SIMPLE_PROGRAMS = \ # ... and all the rest that could be moved out of bindir to gitexecdir PROGRAMS = \ git-apply$X git-cat-file$X \ - git-checkout-index$X git-clone-pack$X git-commit-tree$X \ + git-checkout-index$X git-clone-pack$X \ git-convert-objects$X git-diff-files$X \ git-diff-index$X git-diff-stages$X \ git-diff-tree$X git-fetch-pack$X git-fsck-objects$X \
@@ -172,7 +172,7 @@ BUILT_INS = git-log$X git-whatchanged$X git-count-objects$X git-diff$X git-push$X \ git-grep$X git-rev-list$X git-check-ref-format$X \ git-init-db$X git-ls-files$X git-ls-tree$X \ - git-tar-tree$X git-read-tree$X + git-tar-tree$X git-read-tree$X git-commit-tree$X # what 'all' will build and 'install' will install, in gitexecdir ALL_PROGRAMS = $(PROGRAMS) $(SIMPLE_PROGRAMS) $(SCRIPTS)
@@ -222,7 +222,7 @@ BUILTIN_OBJS = \ builtin-log.o builtin-help.o builtin-count.o builtin-diff.o builtin-push.o \ builtin-grep.o builtin-rev-list.o builtin-check-ref-format.o \ builtin-init-db.o builtin-ls-files.o builtin-ls-tree.o \ - builtin-tar-tree.o builtin-read-tree.o + builtin-tar-tree.o builtin-read-tree.o builtin-commit-tree.o GITLIBS = $(LIB_FILE) $(XDIFF_LIB) LIBS = $(GITLIBS) -lz
builtin-commit-tree.c renamed from commit-tree.c +2 -1
@@ -6,6 +6,7 @@#include "cache.h" #include "commit.h" #include "tree.h" +#include "builtin.h" #define BLOCKING (1ul << 14)
@@ -76,7 +77,7 @@ static int new_parent(int idx)return 1 ; } -int main (int argc,char **argv) +int cmd_commit_tree (int argc,const char **argv,char **envp) {int i;int parents =0 ;
builtin.h +1 -0
@@ -31,5 +31,6 @@ extern int cmd_ls_files(int argc, constextern int cmd_ls_tree (int argc,const char **argv,char **envp);extern int cmd_tar_tree (int argc,const char **argv,char **envp);extern int cmd_read_tree (int argc,const char **argv,char **envp); +extern int cmd_commit_tree (int argc,const char **argv,char **envp);#endif
git.c +2 -1
@@ -56,7 +56,8 @@ static void handle_internal_command(int { "ls-files", cmd_ls_files }, { "ls-tree", cmd_ls_tree }, { "tar-tree", cmd_tar_tree }, - { "read-tree", cmd_read_tree } + { "read-tree", cmd_read_tree }, + { "commit-tree", cmd_commit_tree } };int i;
Signature · 1 line
1.3.3.g288c
PATCH 6/8 Builtin git-apply.
In reply to a message not in the archiveFrom: Peter Eriksen <[email protected]>
---
104e34d8d562584d212f141b7ce736d47016b60a
Makefile | 8 +++++--- apply.c => builtin-apply.c | 3 ++- builtin.h | 1 + git.c | 3 ++- 4 files changed, 10 insertions(+), 5 deletions(-) rename apply.c => builtin-apply.c (100%)
104e34d8d562584d212f141b7ce736d47016b60a
Makefile +5 -3
@@ -149,7 +149,7 @@ SIMPLE_PROGRAMS = \ # ... and all the rest that could be moved out of bindir to gitexecdir PROGRAMS = \ - git-apply$X git-cat-file$X \ + git-cat-file$X \ git-checkout-index$X git-clone-pack$X \ git-convert-objects$X git-diff-files$X \ git-diff-index$X git-diff-stages$X \
@@ -172,7 +172,8 @@ BUILT_INS = git-log$X git-whatchanged$X git-count-objects$X git-diff$X git-push$X \ git-grep$X git-rev-list$X git-check-ref-format$X \ git-init-db$X git-ls-files$X git-ls-tree$X \ - git-tar-tree$X git-read-tree$X git-commit-tree$X + git-tar-tree$X git-read-tree$X git-commit-tree$X \ + git-apply$X # what 'all' will build and 'install' will install, in gitexecdir ALL_PROGRAMS = $(PROGRAMS) $(SIMPLE_PROGRAMS) $(SCRIPTS)
@@ -222,7 +223,8 @@ BUILTIN_OBJS = \ builtin-log.o builtin-help.o builtin-count.o builtin-diff.o builtin-push.o \ builtin-grep.o builtin-rev-list.o builtin-check-ref-format.o \ builtin-init-db.o builtin-ls-files.o builtin-ls-tree.o \ - builtin-tar-tree.o builtin-read-tree.o builtin-commit-tree.o + builtin-tar-tree.o builtin-read-tree.o builtin-commit-tree.o \ + builtin-apply.o GITLIBS = $(LIB_FILE) $(XDIFF_LIB) LIBS = $(GITLIBS) -lz
builtin-apply.c renamed from apply.c +2 -1
@@ -11,6 +11,7 @@ #include "cache.h"#include "quote.h" #include "blob.h" #include "delta.h" +#include "builtin.h" // --check turns on checking that the working tree matches the // files that are being modified, but doesn't apply the patch
@@ -2151,7 +2152,7 @@ static int git_apply_config(const char * } -int main (int argc,char **argv) +int cmd_apply (int argc,const char **argv,char **envp) {int i;int read_stdin =1 ;
builtin.h +1 -0
@@ -32,5 +32,6 @@ extern int cmd_ls_tree(int argc, const cextern int cmd_tar_tree (int argc,const char **argv,char **envp);extern int cmd_read_tree (int argc,const char **argv,char **envp);extern int cmd_commit_tree (int argc,const char **argv,char **envp); +extern int cmd_apply (int argc,const char **argv,char **envp);#endif
git.c +2 -1
@@ -57,7 +57,8 @@ static void handle_internal_command(int { "ls-tree", cmd_ls_tree }, { "tar-tree", cmd_tar_tree }, { "read-tree", cmd_read_tree }, - { "commit-tree", cmd_commit_tree } + { "commit-tree", cmd_commit_tree }, + { "apply", cmd_apply } };int i;
Signature · 1 line
1.3.3.g288c
PATCH 7/8 Builtin git-show-branch.
In reply to a message not in the archiveFrom: Peter Eriksen <[email protected]>
---
d0d1cfb7985fa90442e423a55ca23e6bc83f912d
Makefile | 6 +++--- show-branch.c => builtin-show-branch.c | 3 ++- builtin.h | 1 + git.c | 3 ++- 4 files changed, 8 insertions(+), 5 deletions(-) rename show-branch.c => builtin-show-branch.c (100%)
d0d1cfb7985fa90442e423a55ca23e6bc83f912d
Makefile +3 -3
@@ -159,7 +159,7 @@ PROGRAMS = \ git-merge-index$X git-mktag$X git-mktree$X git-pack-objects$X git-patch-id$X \ git-peek-remote$X git-prune-packed$X \ git-receive-pack$X git-rev-parse$X \ - git-send-pack$X git-show-branch$X git-shell$X \ + git-send-pack$X git-shell$X \ git-show-index$X git-ssh-fetch$X \ git-ssh-upload$X git-unpack-file$X \ git-unpack-objects$X git-update-index$X git-update-server-info$X \
@@ -173,7 +173,7 @@ BUILT_INS = git-log$X git-whatchanged$X git-grep$X git-rev-list$X git-check-ref-format$X \ git-init-db$X git-ls-files$X git-ls-tree$X \ git-tar-tree$X git-read-tree$X git-commit-tree$X \ - git-apply$X + git-apply$X git-show-branch$X # what 'all' will build and 'install' will install, in gitexecdir ALL_PROGRAMS = $(PROGRAMS) $(SIMPLE_PROGRAMS) $(SCRIPTS)
@@ -224,7 +224,7 @@ BUILTIN_OBJS = \ builtin-grep.o builtin-rev-list.o builtin-check-ref-format.o \ builtin-init-db.o builtin-ls-files.o builtin-ls-tree.o \ builtin-tar-tree.o builtin-read-tree.o builtin-commit-tree.o \ - builtin-apply.o + builtin-apply.o builtin-show-branch.o GITLIBS = $(LIB_FILE) $(XDIFF_LIB) LIBS = $(GITLIBS) -lz
builtin-show-branch.c renamed from show-branch.c +2 -1
@@ -3,6 +3,7 @@ #include <fnmatch.h>#include "cache.h" #include "commit.h" #include "refs.h" +#include "builtin.h" static const char show_branch_usage[] ="git-show-branch [--dense] [--current] [--all] [--heads] [--tags] [--topo-order] [--more=count | --list | --independent | --merge-base ] [--topics] [<refs>...]" ;
@@ -548,7 +549,7 @@ static int omit_in_dense(struct commit *return 0 ; } -int main (int ac,char **av) +int cmd_show_branch (int ac,const char **av,char **envp) {struct commit *rev[MAX_REVS ], *commit;struct commit_list *list =NULL , *seen =NULL ;
builtin.h +1 -0
@@ -33,5 +33,6 @@ extern int cmd_tar_tree(int argc, constextern int cmd_read_tree (int argc,const char **argv,char **envp);extern int cmd_commit_tree (int argc,const char **argv,char **envp);extern int cmd_apply (int argc,const char **argv,char **envp); +extern int cmd_show_branch (int argc,const char **argv,char **envp);#endif
git.c +2 -1
@@ -58,7 +58,8 @@ static void handle_internal_command(int { "tar-tree", cmd_tar_tree }, { "read-tree", cmd_read_tree }, { "commit-tree", cmd_commit_tree }, - { "apply", cmd_apply } + { "apply", cmd_apply }, + { "show-branch", cmd_show_branch } };int i;
Signature · 1 line
1.3.3.g288c
PATCH 8/8 Builtin git-diff-files, git-diff-index, git-diff-stages, and git-diff-tree.
In reply to a message not in the archiveFrom: Peter Eriksen <[email protected]>
---
e2d2468b8550f2760b46a2eb461b051abfef4dff
Makefile | 12 ++++++------ diff-files.c => builtin-diff-files.c | 3 ++- diff-index.c => builtin-diff-index.c | 3 ++- diff-stages.c => builtin-diff-stages.c | 3 ++- diff-tree.c => builtin-diff-tree.c | 3 ++- builtin.h | 5 +++++ git.c | 6 +++++- 7 files changed, 24 insertions(+), 11 deletions(-) rename diff-files.c => builtin-diff-files.c (94%) rename diff-index.c => builtin-diff-index.c (91%) rename diff-stages.c => builtin-diff-stages.c (97%) rename diff-tree.c => builtin-diff-tree.c (98%)
e2d2468b8550f2760b46a2eb461b051abfef4dff
Makefile +6 -6
@@ -151,9 +151,7 @@ # ... and all the rest that could be mov PROGRAMS = \ git-cat-file$X \ git-checkout-index$X git-clone-pack$X \ - git-convert-objects$X git-diff-files$X \ - git-diff-index$X git-diff-stages$X \ - git-diff-tree$X git-fetch-pack$X git-fsck-objects$X \ + git-convert-objects$X git-fetch-pack$X git-fsck-objects$X \ git-hash-object$X git-index-pack$X git-local-fetch$X \ git-mailinfo$X git-merge-base$X \ git-merge-index$X git-mktag$X git-mktree$X git-pack-objects$X git-patch-id$X \
@@ -173,7 +171,8 @@ BUILT_INS = git-log$X git-whatchanged$X git-grep$X git-rev-list$X git-check-ref-format$X \ git-init-db$X git-ls-files$X git-ls-tree$X \ git-tar-tree$X git-read-tree$X git-commit-tree$X \ - git-apply$X git-show-branch$X + git-apply$X git-show-branch$X git-diff-files$X \ + git-diff-index$X git-diff-stages$X git-diff-tree$X # what 'all' will build and 'install' will install, in gitexecdir ALL_PROGRAMS = $(PROGRAMS) $(SIMPLE_PROGRAMS) $(SCRIPTS)
@@ -223,8 +222,9 @@ BUILTIN_OBJS = \ builtin-log.o builtin-help.o builtin-count.o builtin-diff.o builtin-push.o \ builtin-grep.o builtin-rev-list.o builtin-check-ref-format.o \ builtin-init-db.o builtin-ls-files.o builtin-ls-tree.o \ - builtin-tar-tree.o builtin-read-tree.o builtin-commit-tree.o \ - builtin-apply.o builtin-show-branch.o + builtin-tar-tree.o builtin-read-tree.o builtin-commit-tree.o \ + builtin-apply.o builtin-show-branch.o builtin-diff-files.o \ + builtin-diff-index.o builtin-diff-stages.o builtin-diff-tree.o GITLIBS = $(LIB_FILE) $(XDIFF_LIB) LIBS = $(GITLIBS) -lz
builtin-diff-files.c renamed from diff-files.c +2 -1
@@ -7,12 +7,13 @@ #include "cache.h"#include "diff.h" #include "commit.h" #include "revision.h" +#include "builtin.h" static const char diff_files_usage[] ="git-diff-files [-q] [-0/-1/2/3 |-c|--cc] [<common diff options>] [<path>...]" COMMON_DIFF_OPTIONS_HELP ; -int main (int argc,const char **argv) +int cmd_diff_files (int argc,const char **argv,char **envp) {struct rev_info rev;int silent =0 ;
builtin-diff-index.c renamed from diff-index.c +2 -1
@@ -2,13 +2,14 @@ #include "cache.h"#include "diff.h" #include "commit.h" #include "revision.h" +#include "builtin.h" static const char diff_cache_usage[] ="git-diff-index [-m] [--cached] " "[<common diff options>] <tree-ish> [<path>...]" COMMON_DIFF_OPTIONS_HELP ; -int main (int argc,const char **argv) +int cmd_diff_index (int argc,const char **argv,char **envp) {struct rev_info rev;int cached =0 ;
builtin-diff-stages.c renamed from diff-stages.c +2 -1
@@ -4,6 +4,7 @@#include "cache.h" #include "diff.h" +#include "builtin.h" static struct diff_options diff_options;
@@ -54,7 +55,7 @@ static void diff_stages(int stage1, int } } -int main (int ac,const char **av) +int cmd_diff_stages (int ac,const char **av,char **envp) {int stage1, stage2;const char *prefix =setup_git_directory ();
builtin-diff-tree.c renamed from diff-tree.c +2 -1
@@ -2,6 +2,7 @@ #include "cache.h"#include "diff.h" #include "commit.h" #include "log-tree.h" +#include "builtin.h" static struct rev_info log_tree_opt;
@@ -58,7 +59,7 @@ static const char diff_tree_usage[] =" --root include the initial commit as diff against /dev/null\n" COMMON_DIFF_OPTIONS_HELP ; -int main (int argc,const char **argv) +int cmd_diff_tree (int argc,const char **argv,char **envp) {int nr_sha1;char line[1000 ];
builtin.h +5 -0
@@ -34,5 +34,10 @@ extern int cmd_read_tree(int argc, constextern int cmd_commit_tree (int argc,const char **argv,char **envp);extern int cmd_apply (int argc,const char **argv,char **envp);extern int cmd_show_branch (int argc,const char **argv,char **envp); +extern int cmd_diff_files (int argc,const char **argv,char **envp); +extern int cmd_diff_index (int argc,const char **argv,char **envp); +extern int cmd_diff_stages (int argc,const char **argv,char **envp); +extern int cmd_diff_tree (int argc,const char **argv,char **envp); +#endif
git.c +5 -1
@@ -59,7 +59,11 @@ static void handle_internal_command(int { "read-tree", cmd_read_tree }, { "commit-tree", cmd_commit_tree }, { "apply", cmd_apply }, - { "show-branch", cmd_show_branch } + { "show-branch", cmd_show_branch }, + { "diff-files", cmd_diff_files }, + { "diff-index", cmd_diff_index }, + { "diff-stages", cmd_diff_stages }, + { "diff-tree", cmd_diff_tree } };int i;
Signature · 1 line
1.3.3.g288c