{"thread":{"id":"34982","subject":"[PATCH v2] build: add default configuration","startedAt":"2013-09-21T11:47:16Z","lastAt":"2013-09-22T08:52:17Z","messageCount":7,"participants":["Felipe Contreras","David Aguilar","Johannes Sixt"],"isPatch":true,"patchVersion":2,"patchTotal":null},"messages":[{"id":"227965","messageId":"1379764036-3782-1-git-send-email-felipe.contreras@gmail.com","threadId":"34982","inReplyTo":null,"subject":"[PATCH v2] build: add default configuration","fromName":"Felipe Contreras","fromEmail":"felipe.contreras@gmail.com","sentAt":"2013-09-21T11:47:16Z","receivedAt":"2013-09-21T11:47:16Z","isPatch":true,"sender":{"key":"felipe.contreras@gmail.com","avatar":"https://avatars.githubusercontent.com/u/8358?v=4"},"body":"For now simply add a few common aliases.\n\n  co = checkout\n  ci = commit\n  rb = rebase\n  st = status\n\nSigned-off-by: Felipe Contreras <felipe.contreras@gmail.com>\n---\n Documentation/git-checkout.txt | 5 +++++\n Documentation/git-commit.txt   | 5 +++++\n Documentation/git-rebase.txt   | 5 +++++\n Documentation/git-status.txt   | 5 +++++\n Makefile                       | 5 ++++-\n gitconfig                      | 5 +++++\n 6 files changed, 29 insertions(+), 1 deletion(-)\n create mode 100644 gitconfig\n\ndiff --git a/Documentation/git-checkout.txt b/Documentation/git-checkout.txt\nindex ca118ac..7597813 100644\n--- a/Documentation/git-checkout.txt\n+++ b/Documentation/git-checkout.txt\n@@ -14,6 +14,11 @@ SYNOPSIS\n 'git checkout' [-f|--ours|--theirs|-m|--conflict=<style>] [<tree-ish>] [--] <paths>...\n 'git checkout' [-p|--patch] [<tree-ish>] [--] [<paths>...]\n \n+ALIAS\n+-----\n+\n+git co\n+\n DESCRIPTION\n -----------\n Updates files in the working tree to match the version in the index\ndiff --git a/Documentation/git-commit.txt b/Documentation/git-commit.txt\nindex 1a7616c..8705abc 100644\n--- a/Documentation/git-commit.txt\n+++ b/Documentation/git-commit.txt\n@@ -15,6 +15,11 @@ SYNOPSIS\n \t   [--date=<date>] [--cleanup=<mode>] [--[no-]status]\n \t   [-i | -o] [-S[<keyid>]] [--] [<file>...]\n \n+ALIAS\n+-----\n+\n+git ci\n+\n DESCRIPTION\n -----------\n Stores the current contents of the index in a new commit along\ndiff --git a/Documentation/git-rebase.txt b/Documentation/git-rebase.txt\nindex 6b2e1c8..69b192d 100644\n--- a/Documentation/git-rebase.txt\n+++ b/Documentation/git-rebase.txt\n@@ -14,6 +14,11 @@ SYNOPSIS\n \t--root [<branch>]\n 'git rebase' --continue | --skip | --abort | --edit-todo\n \n+ALIAS\n+-----\n+\n+git co\n+\n DESCRIPTION\n -----------\n If <branch> is specified, 'git rebase' will perform an automatic\ndiff --git a/Documentation/git-status.txt b/Documentation/git-status.txt\nindex 9046df9..30ecd25 100644\n--- a/Documentation/git-status.txt\n+++ b/Documentation/git-status.txt\n@@ -11,6 +11,11 @@ SYNOPSIS\n [verse]\n 'git status' [<options>...] [--] [<pathspec>...]\n \n+ALIAS\n+-----\n+\n+git st\n+\n DESCRIPTION\n -----------\n Displays paths that have differences between the index file and the\ndiff --git a/Makefile b/Makefile\nindex 3588ca1..18081bf 100644\n--- a/Makefile\n+++ b/Makefile\n@@ -1010,7 +1010,7 @@ ifndef sysconfdir\n ifeq ($(prefix),/usr)\n sysconfdir = /etc\n else\n-sysconfdir = etc\n+sysconfdir = $(prefix)/etc\n endif\n endif\n \n@@ -1586,6 +1586,7 @@ template_dir_SQ = $(subst ','\\'',$(template_dir))\n htmldir_relative_SQ = $(subst ','\\'',$(htmldir_relative))\n prefix_SQ = $(subst ','\\'',$(prefix))\n gitwebdir_SQ = $(subst ','\\'',$(gitwebdir))\n+sysconfdir_SQ = $(subst ','\\'',$(sysconfdir))\n \n SHELL_PATH_SQ = $(subst ','\\'',$(SHELL_PATH))\n PERL_PATH_SQ = $(subst ','\\'',$(PERL_PATH))\n@@ -2340,6 +2341,8 @@ install: all\n \t$(MAKE) -C templates DESTDIR='$(DESTDIR_SQ)' install\n \t$(INSTALL) -d -m 755 '$(DESTDIR_SQ)$(mergetools_instdir_SQ)'\n \t$(INSTALL) -m 644 mergetools/* '$(DESTDIR_SQ)$(mergetools_instdir_SQ)'\n+\t$(INSTALL) -d -m 755 '$(DESTDIR_SQ)$(sysconfdir_SQ)'\n+\t$(INSTALL) -m 644 gitconfig '$(DESTDIR_SQ)$(ETC_GITCONFIG_SQ)'\n ifndef NO_GETTEXT\n \t$(INSTALL) -d -m 755 '$(DESTDIR_SQ)$(localedir_SQ)'\n \t(cd po/build/locale && $(TAR) cf - .) | \\\ndiff --git a/gitconfig b/gitconfig\nnew file mode 100644\nindex 0000000..c45d300\n--- /dev/null\n+++ b/gitconfig\n@@ -0,0 +1,5 @@\n+[alias]\n+\tco = checkout\n+\tci = commit\n+\trb = rebase\n+\tst = status\n-- \n1.8.4.9.g218b36e.dirty\n"},{"id":"228000","messageId":"f779019f-2417-45b1-afcb-e58e93d64489@email.android.com","threadId":"34982","inReplyTo":"1379764036-3782-1-git-send-email-felipe.contreras@gmail.com","subject":"Re: [PATCH v2] build: add default configuration","fromName":"David Aguilar","fromEmail":"davvid@gmail.com","sentAt":"2013-09-21T17:50:58Z","receivedAt":"2013-09-21T17:50:58Z","isPatch":true,"sender":{"key":"davvid@gmail.com","avatar":"https://avatars.githubusercontent.com/u/13196?v=4"},"body":"Felipe Contreras <felipe.contreras@gmail.com> wrote:\n>For now simply add a few common aliases.\n>\n>  co = checkout\n>  ci = commit\n>  rb = rebase\n>  st = status\n>\n>Signed-off-by: Felipe Contreras <felipe.contreras@gmail.com>\n>---\n> Documentation/git-checkout.txt | 5 +++++\n> Documentation/git-commit.txt   | 5 +++++\n> Documentation/git-rebase.txt   | 5 +++++\n> Documentation/git-status.txt   | 5 +++++\n> Makefile                       | 5 ++++-\n> gitconfig                      | 5 +++++\n> 6 files changed, 29 insertions(+), 1 deletion(-)\n\nThe .spec.in file contains a manifest of all the files provided by the git package. We're adding a new file so there may be a %{sysconfdir}/gitconfig entry needed there.  \n\n> create mode 100644 gitconfig\n>\n>diff --git a/Documentation/git-checkout.txt\n>b/Documentation/git-checkout.txt\n>index ca118ac..7597813 100644\n>--- a/Documentation/git-checkout.txt\n>+++ b/Documentation/git-checkout.txt\n>@@ -14,6 +14,11 @@ SYNOPSIS\n>'git checkout' [-f|--ours|--theirs|-m|--conflict=<style>] [<tree-ish>]\n>[--] <paths>...\n> 'git checkout' [-p|--patch] [<tree-ish>] [--] [<paths>...]\n> \n>+ALIAS\n>+-----\n>+\n>+git co\n>+\n> DESCRIPTION\n> -----------\n> Updates files in the working tree to match the version in the index\n>diff --git a/Documentation/git-commit.txt\n>b/Documentation/git-commit.txt\n>index 1a7616c..8705abc 100644\n>--- a/Documentation/git-commit.txt\n>+++ b/Documentation/git-commit.txt\n>@@ -15,6 +15,11 @@ SYNOPSIS\n> \t   [--date=<date>] [--cleanup=<mode>] [--[no-]status]\n> \t   [-i | -o] [-S[<keyid>]] [--] [<file>...]\n> \n>+ALIAS\n>+-----\n>+\n>+git ci\n>+\n> DESCRIPTION\n> -----------\n> Stores the current contents of the index in a new commit along\n>diff --git a/Documentation/git-rebase.txt\n>b/Documentation/git-rebase.txt\n>index 6b2e1c8..69b192d 100644\n>--- a/Documentation/git-rebase.txt\n>+++ b/Documentation/git-rebase.txt\n>@@ -14,6 +14,11 @@ SYNOPSIS\n> \t--root [<branch>]\n> 'git rebase' --continue | --skip | --abort | --edit-todo\n> \n>+ALIAS\n>+-----\n>+\n>+git co\n\nTypofix: git rb\n\n>+\n> DESCRIPTION\n> -----------\n> If <branch> is specified, 'git rebase' will perform an automatic\n>diff --git a/Documentation/git-status.txt\n>b/Documentation/git-status.txt\n>index 9046df9..30ecd25 100644\n>--- a/Documentation/git-status.txt\n>+++ b/Documentation/git-status.txt\n>@@ -11,6 +11,11 @@ SYNOPSIS\n> [verse]\n> 'git status' [<options>...] [--] [<pathspec>...]\n> \n>+ALIAS\n>+-----\n>+\n>+git st\n>+\n> DESCRIPTION\n> -----------\n> Displays paths that have differences between the index file and the\n>diff --git a/Makefile b/Makefile\n>index 3588ca1..18081bf 100644\n>--- a/Makefile\n>+++ b/Makefile\n>@@ -1010,7 +1010,7 @@ ifndef sysconfdir\n> ifeq ($(prefix),/usr)\n> sysconfdir = /etc\n> else\n>-sysconfdir = etc\n>+sysconfdir = $(prefix)/etc\n> endif\n> endif\n\nHmmm that's odd that the original used just \"etc\", but this seems correct (I don't have a machine around to check).\n\nOne small complication here is Mac OS X -- I always end up needing to special-case it to use /private/etc because /etc is a symlink and it's very easy to break the system by replacing it with a real directory.  Kinda ugly, but it's best to be safe.  I learned that the hard way.\n\n> \n>@@ -1586,6 +1586,7 @@ template_dir_SQ = $(subst ','\\'',$(template_dir))\n> htmldir_relative_SQ = $(subst ','\\'',$(htmldir_relative))\n> prefix_SQ = $(subst ','\\'',$(prefix))\n> gitwebdir_SQ = $(subst ','\\'',$(gitwebdir))\n>+sysconfdir_SQ = $(subst ','\\'',$(sysconfdir))\n> \n> SHELL_PATH_SQ = $(subst ','\\'',$(SHELL_PATH))\n> PERL_PATH_SQ = $(subst ','\\'',$(PERL_PATH))\n>@@ -2340,6 +2341,8 @@ install: all\n> \t$(MAKE) -C templates DESTDIR='$(DESTDIR_SQ)' install\n> \t$(INSTALL) -d -m 755 '$(DESTDIR_SQ)$(mergetools_instdir_SQ)'\n>\t$(INSTALL) -m 644 mergetools/* '$(DESTDIR_SQ)$(mergetools_instdir_SQ)'\n>+\t$(INSTALL) -d -m 755 '$(DESTDIR_SQ)$(sysconfdir_SQ)'\n>+\t$(INSTALL) -m 644 gitconfig '$(DESTDIR_SQ)$(ETC_GITCONFIG_SQ)'\n> ifndef NO_GETTEXT\n> \t$(INSTALL) -d -m 755 '$(DESTDIR_SQ)$(localedir_SQ)'\n> \t(cd po/build/locale && $(TAR) cf - .) | \\\n>diff --git a/gitconfig b/gitconfig\n>new file mode 100644\n>index 0000000..c45d300\n>--- /dev/null\n>+++ b/gitconfig\n>@@ -0,0 +1,5 @@\n>+[alias]\n>+\tco = checkout\n>+\tci = commit\n>+\trb = rebase\n>+\tst = status\n\n\n-- \nDavid\n"},{"id":"228009","messageId":"523DEC3F.9080807@kdbg.org","threadId":"34982","inReplyTo":"1379764036-3782-1-git-send-email-felipe.contreras@gmail.com","subject":"Re: [PATCH v2] build: add default configuration","fromName":"Johannes Sixt","fromEmail":"j6t@kdbg.org","sentAt":"2013-09-21T18:58:07Z","receivedAt":"2013-09-21T18:58:07Z","isPatch":true,"sender":{"key":"j6t@kdbg.org","avatar":"https://avatars.githubusercontent.com/u/14810926?v=4"},"body":"Am 21.09.2013 13:47, schrieb Felipe Contreras:\n> diff --git a/Makefile b/Makefile\n> index 3588ca1..18081bf 100644\n> --- a/Makefile\n> +++ b/Makefile\n> @@ -1010,7 +1010,7 @@ ifndef sysconfdir\n>  ifeq ($(prefix),/usr)\n>  sysconfdir = /etc\n>  else\n> -sysconfdir = etc\n> +sysconfdir = $(prefix)/etc\n\nNot good: There is a reason why this is a relative path. Please dig the\nhistory, it's pretty clear.\n\n-- Hannes\n"},{"id":"228010","messageId":"CAMP44s34=HW=C5Fex6xabyQ=Zv4pg7p8RddMEOSVZqudgUkQ_A@mail.gmail.com","threadId":"34982","inReplyTo":"523DEC3F.9080807@kdbg.org","subject":"Re: [PATCH v2] build: add default configuration","fromName":"Felipe Contreras","fromEmail":"felipe.contreras@gmail.com","sentAt":"2013-09-21T19:02:57Z","receivedAt":"2013-09-21T19:02:57Z","isPatch":true,"sender":{"key":"felipe.contreras@gmail.com","avatar":"https://avatars.githubusercontent.com/u/8358?v=4"},"body":"On Sat, Sep 21, 2013 at 1:58 PM, Johannes Sixt <j6t@kdbg.org> wrote:\n> Am 21.09.2013 13:47, schrieb Felipe Contreras:\n>> diff --git a/Makefile b/Makefile\n>> index 3588ca1..18081bf 100644\n>> --- a/Makefile\n>> +++ b/Makefile\n>> @@ -1010,7 +1010,7 @@ ifndef sysconfdir\n>>  ifeq ($(prefix),/usr)\n>>  sysconfdir = /etc\n>>  else\n>> -sysconfdir = etc\n>> +sysconfdir = $(prefix)/etc\n>\n> Not good: There is a reason why this is a relative path. Please dig the\n> history, it's pretty clear.\n\nIt's pretty clear it's *not* a relative path.\n\nWhat is relative about 'sysconfdir = /etc'?\n\n-- \nFelipe Contreras\n"},{"id":"228024","messageId":"46ebee31-2b4f-48c1-952c-99364aeede98@email.android.com","threadId":"34982","inReplyTo":"CAMP44s34=HW=C5Fex6xabyQ=Zv4pg7p8RddMEOSVZqudgUkQ_A@mail.gmail.com","subject":"Re: [PATCH v2] build: add default configuration","fromName":"David Aguilar","fromEmail":"davvid@gmail.com","sentAt":"2013-09-22T05:19:46Z","receivedAt":"2013-09-22T05:19:46Z","isPatch":true,"sender":{"key":"davvid@gmail.com","avatar":"https://avatars.githubusercontent.com/u/13196?v=4"},"body":"Felipe Contreras <felipe.contreras@gmail.com> wrote:\n>On Sat, Sep 21, 2013 at 1:58 PM, Johannes Sixt <j6t@kdbg.org> wrote:\n>> Am 21.09.2013 13:47, schrieb Felipe Contreras:\n>>> diff --git a/Makefile b/Makefile\n>>> index 3588ca1..18081bf 100644\n>>> --- a/Makefile\n>>> +++ b/Makefile\n>>> @@ -1010,7 +1010,7 @@ ifndef sysconfdir\n>>>  ifeq ($(prefix),/usr)\n>>>  sysconfdir = /etc\n>>>  else\n>>> -sysconfdir = etc\n>>> +sysconfdir = $(prefix)/etc\n>>\n>> Not good: There is a reason why this is a relative path. Please dig\n>the\n>> history, it's pretty clear.\n>\n>It's pretty clear it's *not* a relative path.\n>\n>What is relative about 'sysconfdir = /etc'?\n\nThanks Johannes. Felipe, the history and this comment from the makefile should shed some light on it:\n\n# Among the variables below, these:\n#   gitexecdir\n#   template_dir\n#   sysconfdir\n# can be specified as a relative path some/where/else;\n# this is interpreted as relative to $(prefix) and \"git\" at\n# runtime figures out where they are based on the path to the executable.\n...\nSo it'll probably need another makefile variable to do this cleanly.\n\nI hope that helps.\nCheers,\n\n\n-- \nDavid\n"},{"id":"228025","messageId":"523e815966074_547c41e7c16566@nysa.mail","threadId":"34982","inReplyTo":"46ebee31-2b4f-48c1-952c-99364aeede98@email.android.com","subject":"Re: [PATCH v2] build: add default configuration","fromName":"Felipe Contreras","fromEmail":"felipe.contreras@gmail.com","sentAt":"2013-09-22T05:34:17Z","receivedAt":"2013-09-22T05:34:17Z","isPatch":true,"sender":{"key":"felipe.contreras@gmail.com","avatar":"https://avatars.githubusercontent.com/u/8358?v=4"},"body":"David Aguilar wrote:\n> Felipe Contreras <felipe.contreras@gmail.com> wrote:\n> >On Sat, Sep 21, 2013 at 1:58 PM, Johannes Sixt <j6t@kdbg.org> wrote:\n> >> Am 21.09.2013 13:47, schrieb Felipe Contreras:\n> >>> diff --git a/Makefile b/Makefile\n> >>> index 3588ca1..18081bf 100644\n> >>> --- a/Makefile\n> >>> +++ b/Makefile\n> >>> @@ -1010,7 +1010,7 @@ ifndef sysconfdir\n> >>>  ifeq ($(prefix),/usr)\n> >>>  sysconfdir = /etc\n> >>>  else\n> >>> -sysconfdir = etc\n> >>> +sysconfdir = $(prefix)/etc\n> >>\n> >> Not good: There is a reason why this is a relative path. Please dig\n> >the\n> >> history, it's pretty clear.\n> >\n> >It's pretty clear it's *not* a relative path.\n> >\n> >What is relative about 'sysconfdir = /etc'?\n> \n> Thanks Johannes. Felipe, the history and this comment from the makefile should shed some light on it:\n> \n> # Among the variables below, these:\n> #   gitexecdir\n> #   template_dir\n> #   sysconfdir\n> # can be specified as a relative path some/where/else;\n> # this is interpreted as relative to $(prefix) and \"git\" at\n> # runtime figures out where they are based on the path to the executable.\n\nThey *can* be, but not necessarily so, and in particular sysconfig for probably\n99% of the users is not relative, it's /etc.\n\n-- \nFelipe Contreras\n"},{"id":"228031","messageId":"5940c6ca-86f4-4a57-bc9e-41a73842cc6d@email.android.com","threadId":"34982","inReplyTo":"523e815966074_547c41e7c16566@nysa.mail","subject":"Re: [PATCH v2] build: add default configuration","fromName":"David Aguilar","fromEmail":"davvid@gmail.com","sentAt":"2013-09-22T08:52:17Z","receivedAt":"2013-09-22T08:52:17Z","isPatch":true,"sender":{"key":"davvid@gmail.com","avatar":"https://avatars.githubusercontent.com/u/13196?v=4"},"body":"Felipe Contreras <felipe.contreras@gmail.com> wrote:\n>David Aguilar wrote:\n>> Felipe Contreras <felipe.contreras@gmail.com> wrote:\n>> >On Sat, Sep 21, 2013 at 1:58 PM, Johannes Sixt <j6t@kdbg.org> wrote:\n>> >> Am 21.09.2013 13:47, schrieb Felipe Contreras:\n>> >>> diff --git a/Makefile b/Makefile\n>> >>> index 3588ca1..18081bf 100644\n>> >>> --- a/Makefile\n>> >>> +++ b/Makefile\n>> >>> @@ -1010,7 +1010,7 @@ ifndef sysconfdir\n>> >>>  ifeq ($(prefix),/usr)\n>> >>>  sysconfdir = /etc\n>> >>>  else\n>> >>> -sysconfdir = etc\n>> >>> +sysconfdir = $(prefix)/etc\n>> >>\n>> >> Not good: There is a reason why this is a relative path. Please\n>dig\n>> >the\n>> >> history, it's pretty clear.\n>> >\n>> >It's pretty clear it's *not* a relative path.\n>> >\n>> >What is relative about 'sysconfdir = /etc'?\n>> \n>> Thanks Johannes. Felipe, the history and this comment from the\n>makefile should shed some light on it:\n>> \n>> # Among the variables below, these:\n>> #   gitexecdir\n>> #   template_dir\n>> #   sysconfdir\n>> # can be specified as a relative path some/where/else;\n>> # this is interpreted as relative to $(prefix) and \"git\" at\n>> # runtime figures out where they are based on the path to the\n>executable.\n>\n>They *can* be, but not necessarily so, and in particular sysconfig for\n>probably\n>99% of the users is not relative, it's /etc.\n\nThis makes Git relocatable. MsysGit has many more users then developers, and represents a pretty large chunk of users. \n\n-- \nDavid\n"}]}