From: Nicolas Pitre <nico@cam.org>
To: Junio C Hamano <junkio@cox.net>
Cc: git@vger.kernel.org
Subject: [PATCH/RFC] "init-db" can really be just "init"
Date: Mon, 27 Nov 2006 16:31:47 -0500 (EST) [thread overview]
Message-ID: <Pine.LNX.4.64.0611271622260.9647@xanadu.home> (raw)
This should make first GIT impression a little less intimidating.
Signed-off-by: Nicolas Pitre <nico@cam.org>
---
Maybe that could be a good rule of thumb to have all porcelainish
commands not have any hyphen in their name, like "diff", "commit",
"add", etc. ?
diff --git a/Documentation/everyday.txt b/Documentation/everyday.txt
index 9677671..ee9ddee 100644
--- a/Documentation/everyday.txt
+++ b/Documentation/everyday.txt
@@ -25,7 +25,7 @@ Basic Repository[[Basic Repository]]
Everybody uses these commands to maintain git repositories.
- * gitlink:git-init-db[1] or gitlink:git-clone[1] to create a
+ * gitlink:git-init[1] or gitlink:git-clone[1] to create a
new repository.
* gitlink:git-fsck-objects[1] to check the repository for errors.
@@ -106,7 +106,7 @@ Use a tarball as a starting point for a new repository:
------------
$ tar zxf frotz.tar.gz
$ cd frotz
-$ git-init-db
+$ git-init
$ git add . <1>
$ git commit -m 'import of frotz source tree.'
$ git tag v2.43 <2>
diff --git a/Documentation/git-init-db.txt b/Documentation/git-init-db.txt
index ca7d09d..bc3ba14 100644
--- a/Documentation/git-init-db.txt
+++ b/Documentation/git-init-db.txt
@@ -74,6 +74,7 @@ Running `git-init-db` in an existing repository is safe. It will not overwrite
things that are already there. The primary reason for rerunning `git-init-db`
is to pick up newly added templates.
+Note that `git-init` is the same as `git-init-db`.
EXAMPLES
diff --git a/Documentation/git-init.txt b/Documentation/git-init.txt
new file mode 100644
index 0000000..36838c7
--- /dev/null
+++ b/Documentation/git-init.txt
@@ -0,0 +1 @@
+include::git-init-db.txt[]
diff --git a/Documentation/git.txt b/Documentation/git.txt
index 619d656..5501ae0 100644
--- a/Documentation/git.txt
+++ b/Documentation/git.txt
@@ -347,6 +347,7 @@ gitlink:git-hash-object[1]::
gitlink:git-index-pack[1]::
Build pack idx file for an existing packed archive.
+gitlink:git-init[1]::
gitlink:git-init-db[1]::
Creates an empty git object database, or reinitialize an
existing one.
diff --git a/Documentation/tutorial-2.txt b/Documentation/tutorial-2.txt
index 6389de5..13a1878 100644
--- a/Documentation/tutorial-2.txt
+++ b/Documentation/tutorial-2.txt
@@ -17,7 +17,7 @@ Let's start a new project and create a small amount of history:
------------------------------------------------
$ mkdir test-project
$ cd test-project
-$ git init-db
+$ git init
defaulting to local storage area
$ echo 'hello world' > file.txt
$ git add .
diff --git a/Documentation/tutorial.txt b/Documentation/tutorial.txt
index 35af81a..978d4bd 100644
--- a/Documentation/tutorial.txt
+++ b/Documentation/tutorial.txt
@@ -20,7 +20,7 @@ can place it under git revision control as follows.
------------------------------------------------
$ tar xzf project.tar.gz
$ cd project
-$ git init-db
+$ git init
------------------------------------------------
Git will reply
diff --git a/Makefile b/Makefile
index e547e2a..c307324 100644
--- a/Makefile
+++ b/Makefile
@@ -203,7 +203,7 @@ EXTRA_PROGRAMS =
BUILT_INS = \
git-format-patch$X git-show$X git-whatchanged$X git-cherry$X \
- git-get-tar-commit-id$X \
+ git-get-tar-commit-id$X git-init$X \
$(patsubst builtin-%.o,git-%$X,$(BUILTIN_OBJS))
# what 'all' will build and 'install' will install, in gitexecdir
diff --git a/builtin-init-db.c b/builtin-init-db.c
index 235a0ee..408b51a 100644
--- a/builtin-init-db.c
+++ b/builtin-init-db.c
@@ -242,7 +242,7 @@ static void create_default_files(const char *git_dir, const char *template_path)
}
static const char init_db_usage[] =
-"git-init-db [--template=<template-directory>] [--shared]";
+"git-init [--template=<template-directory>] [--shared]";
/*
* If you want to, you can share the DB area with any number of branches.
diff --git a/git.c b/git.c
index f97de60..5ae5afc 100644
--- a/git.c
+++ b/git.c
@@ -241,6 +241,7 @@ static void handle_internal_command(int argc, const char **argv, char **envp)
{ "get-tar-commit-id", cmd_get_tar_commit_id },
{ "grep", cmd_grep, RUN_SETUP },
{ "help", cmd_help },
+ { "init", cmd_init_db },
{ "init-db", cmd_init_db },
{ "log", cmd_log, RUN_SETUP | USE_PAGER },
next reply other threads:[~2006-11-27 21:32 UTC|newest]
Thread overview: 104+ messages / expand[flat|nested] mbox.gz Atom feed top
2006-11-27 21:31 Nicolas Pitre [this message]
2006-11-27 22:05 ` [PATCH/RFC] "init-db" can really be just "init" Junio C Hamano
2006-11-27 22:40 ` Hyphens and hiding core commands (was: "init-db" can really be just "init") Carl Worth
2006-11-27 23:59 ` Hyphens and hiding core commands Junio C Hamano
2006-11-28 0:23 ` Carl Worth
2006-11-28 0:42 ` Junio C Hamano
2006-11-28 1:35 ` Carl Worth
2006-11-28 2:18 ` Junio C Hamano
2006-11-28 5:40 ` Theodore Tso
2006-11-28 9:15 ` Junio C Hamano
2006-11-29 7:14 ` Michael S. Tsirkin
2006-11-28 6:59 ` [PATCH 0/2] Making "git commit" to mean "git commit -a" Junio C Hamano
2006-11-28 10:26 ` Andy Whitcroft
2006-11-28 13:00 ` Josef Weidendorfer
2006-11-28 13:23 ` Jakub Narebski
2006-11-28 18:18 ` Carl Worth
2006-11-29 3:06 ` Junio C Hamano
2006-11-29 4:33 ` Nicolas Pitre
2006-11-29 7:44 ` Junio C Hamano
2006-11-29 18:08 ` Nicolas Pitre
2006-11-29 18:18 ` Jakub Narebski
2006-11-29 19:12 ` Steven Grimm
2006-11-29 19:30 ` Jakub Narebski
2006-11-29 18:53 ` Junio C Hamano
2006-11-29 19:09 ` Steven Grimm
2006-11-29 20:01 ` Johannes Schindelin
2006-11-29 20:39 ` Junio C Hamano
2006-11-29 21:50 ` xdl_merge(), was " Johannes Schindelin
2006-11-30 5:24 ` Seth Falcon
2006-11-29 23:37 ` Carl Worth
2006-11-29 23:53 ` Johannes Schindelin
2006-11-30 1:03 ` Junio C Hamano
2006-11-30 1:22 ` Junio C Hamano
2006-11-30 1:58 ` Steven Grimm
2006-11-30 2:04 ` Sam Vilain
2006-11-30 2:12 ` Junio C Hamano
2006-11-30 2:11 ` Johannes Schindelin
2006-11-30 3:10 ` Linus Torvalds
2006-11-30 10:27 ` Johannes Schindelin
2006-11-30 11:09 ` Andreas Ericsson
2006-11-30 15:58 ` Linus Torvalds
2006-11-30 16:40 ` Theodore Tso
2006-11-30 17:13 ` Linus Torvalds
2006-11-30 17:37 ` Nicolas Pitre
2006-11-30 18:38 ` Carl Worth
2006-11-30 18:47 ` Jakub Narebski
2006-11-30 19:04 ` Carl Worth
2006-12-01 8:44 ` Andreas Ericsson
2006-12-01 9:31 ` Han-Wen Nienhuys
2006-11-30 18:51 ` Carl Worth
2006-11-30 19:55 ` Linus Torvalds
2006-11-30 20:47 ` Nicolas Pitre
2006-11-30 21:03 ` Linus Torvalds
2006-11-30 21:16 ` Jakub Narebski
2006-11-30 21:37 ` Carl Worth
2006-11-30 21:41 ` Michael K. Edwards
2006-11-30 21:50 ` Carl Worth
2006-11-30 21:58 ` Jakub Narebski
2006-11-30 22:26 ` Johannes Schindelin
2006-11-30 22:07 ` Josef Weidendorfer
2006-11-30 22:25 ` Johannes Schindelin
2006-11-30 22:37 ` Nicolas Pitre
2006-11-30 22:31 ` Nicolas Pitre
2006-11-30 22:47 ` Junio C Hamano
2006-12-01 8:34 ` Andy Parkins
2006-12-01 23:33 ` Alan Chandler
2006-11-30 21:19 ` Junio C Hamano
2006-11-30 22:21 ` Nicolas Pitre
2006-11-30 23:02 ` Junio C Hamano
2006-11-30 23:40 ` Linus Torvalds
2006-12-01 0:13 ` Carl Worth
2006-12-01 0:21 ` Linus Torvalds
2006-12-01 1:10 ` Carl Worth
2006-12-01 1:32 ` Linus Torvalds
2006-12-01 2:08 ` Carl Worth
2006-12-01 2:44 ` Linus Torvalds
2006-12-01 3:40 ` Carl Worth
2006-12-01 3:52 ` Michael K. Edwards
2006-12-01 0:24 ` Junio C Hamano
[not found] ` <Pine.LNX.4. 64.0611301520370.3513@woody.osdl.org>
2006-12-01 0:06 ` Jakub Narebski
2006-12-01 1:20 ` Nicolas Pitre
2006-12-01 8:59 ` Andreas Ericsson
2006-12-01 23:36 ` Alan Chandler
[not found] ` <7vac28h898.fsf@assigned-by-dhcp.cox.net>
2006-11-30 22:46 ` Nicolas Pitre
2006-11-30 22:55 ` Johannes Schindelin
2006-11-30 21:33 ` Robert Shearman
2006-11-30 21:41 ` Jakub Narebski
2006-12-01 18:27 ` Shawn Pearce
2006-12-02 7:48 ` Marco Costalba
2006-11-30 18:09 ` Carl Worth
2006-11-30 18:33 ` Linus Torvalds
2006-11-30 0:52 ` Daniel Barkalow
2006-11-30 12:23 ` Salikh Zakirov
2006-11-30 13:16 ` Jakub Narebski
2006-11-30 15:15 ` Seth Falcon
2006-11-30 15:50 ` Nguyen Thai Ngoc Duy
2006-11-30 16:03 ` Seth Falcon
2006-11-30 16:05 ` Jakub Narebski
2006-11-30 17:13 ` Andy Whitcroft
2006-11-28 7:00 ` [PATCH 1/2] git-commit: prepare to make '-a' behaviour the default Junio C Hamano
2006-11-28 7:00 ` [PATCH 2/2] git-commit: make '-a' " Junio C Hamano
2006-11-28 9:09 ` Jakub Narebski
2006-11-27 23:36 ` [PATCH/RFC] "init-db" can really be just "init" Johannes Schindelin
2006-11-28 10:45 ` Han-Wen Nienhuys
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=Pine.LNX.4.64.0611271622260.9647@xanadu.home \
--to=nico@cam.org \
--cc=git@vger.kernel.org \
--cc=junkio@cox.net \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).