{"thread":{"id":"25870","subject":"[PATCH] Fallback on _NSGetExecutablePath to get the executable path if using argv[0] fails","startedAt":"2010-11-29T16:57:02Z","lastAt":"2010-12-03T07:50:03Z","messageCount":14,"participants":["Jeremy Huddleston","Thiago Farina","Jonathan Nieder","Junio C Hamano","Kevin Ballard"],"isPatch":true,"patchVersion":1,"patchTotal":null},"messages":[{"id":"156815","messageId":"051964C9-0507-4CCB-A111-55CA36652F00@apple.com","threadId":"25870","inReplyTo":null,"subject":"[PATCH] Fallback on _NSGetExecutablePath to get the executable path if using argv[0] fails","fromName":"Jeremy Huddleston","fromEmail":"jeremyhu@apple.com","sentAt":"2010-11-29T16:57:02Z","receivedAt":"2010-11-29T16:57:02Z","isPatch":true,"sender":{"key":"jeremyhu@apple.com","avatar":"https://avatars.githubusercontent.com/u/1258676?v=4"},"body":"\nSigned-off-by: Jeremy Huddleston <jeremyhu@apple.com>\nReviewed-by: Matt Wright <mww@apple.com>\n---\n exec_cmd.c |   17 +++++++++++++++++\n 1 files changed, 17 insertions(+), 0 deletions(-)\n\ndiff --git a/exec_cmd.c b/exec_cmd.c\nindex bf22570..1e24a8f 100644\n--- a/exec_cmd.c\n+++ b/exec_cmd.c\n@@ -3,6 +3,10 @@\n #include \"quote.h\"\n #define MAX_ARGS\t32\n \n+#if defined(__APPLE__) && defined(RUNTIME_PREFIX)\n+#include <mach-o/dyld.h>\n+#endif\n+\n extern char **environ;\n static const char *argv_exec_path;\n static const char *argv0_path;\n@@ -53,6 +57,19 @@ const char *git_extract_argv0_path(const char *argv0)\n \tif (slash >= argv0) {\n \t\targv0_path = xstrndup(argv0, slash - argv0);\n \t\treturn slash + 1;\n+#ifdef __APPLE__\n+\t} else {\n+\t\tchar new_argv0[PATH_MAX];\n+\t\tuint32_t new_argv0_s = PATH_MAX;\n+\t\tif(_NSGetExecutablePath(new_argv0, &new_argv0_s) == 0) {\n+\t\t\tslash = new_argv0 + new_argv0_s;\n+\t\t\twhile (new_argv0 <= slash && !is_dir_sep(*slash))\n+\t\t                slash--;\n+\n+\t\t\tif (slash >= new_argv0)\n+\t\t\t\targv0_path = xstrndup(new_argv0, slash - new_argv0);\n+\t\t}\n+#endif\n \t}\n \n \treturn argv0;\n-- \n1.7.3.2\n"},{"id":"156816","messageId":"AANLkTimwRJqje1-HhzKj-L-5-2CvhTC0+Pr0Cvj7d_kc@mail.gmail.com","threadId":"25870","inReplyTo":"051964C9-0507-4CCB-A111-55CA36652F00@apple.com","subject":"Re: [PATCH] Fallback on _NSGetExecutablePath to get the executable path if using argv[0] fails","fromName":"Thiago Farina","fromEmail":"tfransosi@gmail.com","sentAt":"2010-11-29T17:09:11Z","receivedAt":"2010-11-29T17:09:11Z","isPatch":true,"sender":{"key":"tfransosi@gmail.com","avatar":"https://avatars.githubusercontent.com/u/970071?v=4"},"body":"On Mon, Nov 29, 2010 at 2:57 PM, Jeremy Huddleston <jeremyhu@apple.com> wrote:\n>\n> Signed-off-by: Jeremy Huddleston <jeremyhu@apple.com>\n> Reviewed-by: Matt Wright <mww@apple.com>\n> ---\n>  exec_cmd.c |   17 +++++++++++++++++\n>  1 files changed, 17 insertions(+), 0 deletions(-)\n>\n> diff --git a/exec_cmd.c b/exec_cmd.c\n> index bf22570..1e24a8f 100644\n> --- a/exec_cmd.c\n> +++ b/exec_cmd.c\n> @@ -3,6 +3,10 @@\n>  #include \"quote.h\"\n>  #define MAX_ARGS       32\n>\n> +#if defined(__APPLE__) && defined(RUNTIME_PREFIX)\n> +#include <mach-o/dyld.h>\n> +#endif\n> +\n>  extern char **environ;\n>  static const char *argv_exec_path;\n>  static const char *argv0_path;\n> @@ -53,6 +57,19 @@ const char *git_extract_argv0_path(const char *argv0)\n>        if (slash >= argv0) {\n>                argv0_path = xstrndup(argv0, slash - argv0);\n>                return slash + 1;\n> +#ifdef __APPLE__\n\nWhy not #if defined(__APPLE__), like above?\n"},{"id":"156817","messageId":"20101129171211.GL8037@burratino","threadId":"25870","inReplyTo":"AANLkTimwRJqje1-HhzKj-L-5-2CvhTC0+Pr0Cvj7d_kc@mail.gmail.com","subject":"Re: [PATCH] Fallback on _NSGetExecutablePath to get the executable path if using argv[0] fails","fromName":"Jonathan Nieder","fromEmail":"jrnieder@gmail.com","sentAt":"2010-11-29T17:12:11Z","receivedAt":"2010-11-29T17:12:11Z","isPatch":true,"sender":{"key":"jrnieder@gmail.com","avatar":"https://avatars.githubusercontent.com/u/281595?v=4"},"body":"Thiago Farina wrote:\n> On Mon, Nov 29, 2010 at 2:57 PM, Jeremy Huddleston <jeremyhu@apple.com> wrote:\n\n>> Signed-off-by: Jeremy Huddleston <jeremyhu@apple.com>\n>> Reviewed-by: Matt Wright <mww@apple.com>\n\nI like the idea, but could you add a short commit message\nexplaining the existing behavior and what improvement this makes?\n\n> Why not #if defined(__APPLE__), like above?\n\nMore importantly, please search for #ifdef in existing code to get\nsome examples of how we like to do platform-specific things.\n\nThe section \"2) #ifdefs are ugly\" of\nlinux-2.6/Documentation/SubmittingPatches explains the rationale.\n\nRegards,\nJonathan\n"},{"id":"156823","messageId":"DD9829B7-8851-41CF-BCC6-2676B6015028@apple.com","threadId":"25870","inReplyTo":"20101129171211.GL8037@burratino","subject":"[PATCH updated] Fallback on _NSGetExecutablePath to get the executable path if using argv[0] fails","fromName":"Jeremy Huddleston","fromEmail":"jeremyhu@apple.com","sentAt":"2010-11-29T18:29:39Z","receivedAt":"2010-11-29T18:29:39Z","isPatch":true,"sender":{"key":"jeremyhu@apple.com","avatar":"https://avatars.githubusercontent.com/u/1258676?v=4"},"body":"\nThis adds better support for RUNTIME_PREFIX on Mac OS X.  The previous codepath\nwould only work if argv[0] contained the full path to the executable or $PATH\nalready contained /path/to/libexec/git-core.  We use _NSGetExecutablePath here\nto find the full path (and thus prepend the correct libexec/git-core to $PATH)\nin the case where argv[0] does not contain the full path to the executable.\n\nSigned-off-by: Jeremy Huddleston <jeremyhu@apple.com>\nReviewed-by: Matt Wright <mww@apple.com>\n---\n exec_cmd.c |   17 +++++++++++++++++\n 1 files changed, 17 insertions(+), 0 deletions(-)\n\ndiff --git a/exec_cmd.c b/exec_cmd.c\nindex bf22570..182fd3a 100644\n--- a/exec_cmd.c\n+++ b/exec_cmd.c\n@@ -3,6 +3,10 @@\n #include \"quote.h\"\n #define MAX_ARGS\t32\n \n+#if defined(__APPLE__) && defined(RUNTIME_PREFIX)\n+#include <mach-o/dyld.h>\n+#endif\n+\n extern char **environ;\n static const char *argv_exec_path;\n static const char *argv0_path;\n@@ -53,6 +57,19 @@ const char *git_extract_argv0_path(const char *argv0)\n \tif (slash >= argv0) {\n \t\targv0_path = xstrndup(argv0, slash - argv0);\n \t\treturn slash + 1;\n+#if defined(__APPLE__)\n+\t} else {\n+\t\tchar new_argv0[PATH_MAX];\n+\t\tuint32_t new_argv0_s = PATH_MAX;\n+\t\tif(_NSGetExecutablePath(new_argv0, &new_argv0_s) == 0) {\n+\t\t\tslash = new_argv0 + strlen(new_argv0);\n+\t\t\twhile (new_argv0 <= slash && !is_dir_sep(*slash))\n+\t\t                slash--;\n+\n+\t\t\tif (slash >= new_argv0)\n+\t\t\t\targv0_path = xstrndup(new_argv0, slash - new_argv0);\n+\t\t}\n+#endif\n \t}\n \n \treturn argv0;\n-- \n1.7.3.2\n"},{"id":"156824","messageId":"37CD335A-00A7-4074-BD39-4FCDEEB3D083@apple.com","threadId":"25870","inReplyTo":"20101129171211.GL8037@burratino","subject":"Re: [PATCH] Fallback on _NSGetExecutablePath to get the executable path if using argv[0] fails","fromName":"Jeremy Huddleston","fromEmail":"jeremyhu@apple.com","sentAt":"2010-11-29T18:34:54Z","receivedAt":"2010-11-29T18:34:54Z","isPatch":true,"sender":{"key":"jeremyhu@apple.com","avatar":"https://avatars.githubusercontent.com/u/1258676?v=4"},"body":"\nOn Nov 29, 2010, at 12:12, Jonathan Nieder wrote:\n\n> Thiago Farina wrote:\n>> On Mon, Nov 29, 2010 at 2:57 PM, Jeremy Huddleston <jeremyhu@apple.com> wrote:\n> \n>>> Signed-off-by: Jeremy Huddleston <jeremyhu@apple.com>\n>>> Reviewed-by: Matt Wright <mww@apple.com>\n> \n> I like the idea, but could you add a short commit message\n> explaining the existing behavior and what improvement this makes?\n\nHopefully what I resent is sufficient for explaining the changes.\n\n>> Why not #if defined(__APPLE__), like above?\n\nOriginally for style.  I like #ifdef better than #if defined(), but I changed it for you in the resend.\n\n> More importantly, please search for #ifdef in existing code to get\n> some examples of how we like to do platform-specific things.\n\nYeah, I see some:\n#ifdef _WIN32\n\nwhich is why I used __APPLE__.  Do you have a better suggestion?\n\n> The section \"2) #ifdefs are ugly\" of\n> linux-2.6/Documentation/SubmittingPatches explains the rationale.\n\nI agree, but I don't really see a way around it here since this API is specific to OS X.\n"},{"id":"156825","messageId":"20101129184929.GA9441@burratino","threadId":"25870","inReplyTo":"DD9829B7-8851-41CF-BCC6-2676B6015028@apple.com","subject":"Re: [PATCH updated] Fallback on _NSGetExecutablePath to get the executable path if using argv[0] fails","fromName":"Jonathan Nieder","fromEmail":"jrnieder@gmail.com","sentAt":"2010-11-29T18:49:29Z","receivedAt":"2010-11-29T18:49:29Z","isPatch":true,"sender":{"key":"jrnieder@gmail.com","avatar":"https://avatars.githubusercontent.com/u/281595?v=4"},"body":"Jeremy Huddleston wrote:\n\n> This adds better support for RUNTIME_PREFIX on Mac OS X.  The previous codepath\n> would only work if argv[0] contained the full path to the executable or $PATH\n> already contained /path/to/libexec/git-core.  We use _NSGetExecutablePath here\n> to find the full path (and thus prepend the correct libexec/git-core to $PATH)\n> in the case where argv[0] does not contain the full path to the executable.\n\nCloser.  But that is perhaps too much at the level of code rather than\nthe user:\n\n\tSubject: MacOSX: Use _NSGetExecutablePath to get full argv[0] path\n\n\tWhen RUNTIME_PREFIX support is enabled (which is common on Mac OS X)\n\tthe exec-path is derived from the program invocation path.\n\tUnfortunately, usual Unix semantics are for argv[0] to contain\n\tthe path used to invoke a program rather than the path to the\n\texecutable.  So usual invocations of git would not result in\n\thelpers from exec-path being found correctly:\n\n\t\t$ git fast-import\n\t\t... example output here ...\n\n\tSo in the spirit of v1.6.0-rc1~21 (Windows: make sure argv[0]\n\thas a path, 2008-07-21), use _NSGetExecutablePath to find the full\n\tpath to the git binary, avoiding such trouble.\n\n> --- a/exec_cmd.c\n> +++ b/exec_cmd.c\n[...]\n> @@ -53,6 +57,19 @@ const char *git_extract_argv0_path(const char *argv0)\n>  \tif (slash >= argv0) {\n>  \t\targv0_path = xstrndup(argv0, slash - argv0);\n>  \t\treturn slash + 1;\n> +#if defined(__APPLE__)\n> +\t} else {\n> +\t\tchar new_argv0[PATH_MAX];\n> +\t\tuint32_t new_argv0_s = PATH_MAX;\n> +\t\tif(_NSGetExecutablePath(new_argv0, &new_argv0_s) == 0) {\n> +\t\t\tslash = new_argv0 + strlen(new_argv0);\n> +\t\t\twhile (new_argv0 <= slash && !is_dir_sep(*slash))\n> +\t\t                slash--;\n> +\n> +\t\t\tif (slash >= new_argv0)\n> +\t\t\t\targv0_path = xstrndup(new_argv0, slash - new_argv0);\n> +\t\t}\n> +#endif\n\nCan't this ifdef be avoided?  The ideal is for such code to be\nabstracted away into helper functions in git-compat-util.h and compat/*.c.\n\nJonathan\n"},{"id":"156826","messageId":"20101129185030.GB9441@burratino","threadId":"25870","inReplyTo":"37CD335A-00A7-4074-BD39-4FCDEEB3D083@apple.com","subject":"Re: [PATCH] Fallback on _NSGetExecutablePath to get the executable path if using argv[0] fails","fromName":"Jonathan Nieder","fromEmail":"jrnieder@gmail.com","sentAt":"2010-11-29T18:50:30Z","receivedAt":"2010-11-29T18:50:30Z","isPatch":true,"sender":{"key":"jrnieder@gmail.com","avatar":"https://avatars.githubusercontent.com/u/281595?v=4"},"body":"Jeremy Huddleston wrote:\n> On Nov 29, 2010, at 12:12, Jonathan Nieder wrote:\n\n>> The section \"2) #ifdefs are ugly\" of\n>> linux-2.6/Documentation/SubmittingPatches explains the rationale.\n>\n> I agree, but I don't really see a way around it here since this API is specific to OS X.\n\nDid you actually read that section? :)\n"},{"id":"156831","messageId":"BED9E026-6804-4ABF-A26D-8F20699BAD0B@apple.com","threadId":"25870","inReplyTo":"20101129185030.GB9441@burratino","subject":"Re: [PATCH] Fallback on _NSGetExecutablePath to get the executable path if using argv[0] fails","fromName":"Jeremy Huddleston","fromEmail":"jeremyhu@apple.com","sentAt":"2010-11-29T20:07:38Z","receivedAt":"2010-11-29T20:07:38Z","isPatch":true,"sender":{"key":"jeremyhu@apple.com","avatar":"https://avatars.githubusercontent.com/u/1258676?v=4"},"body":"\nOn Nov 29, 2010, at 13:50, Jonathan Nieder wrote:\n\n> Jeremy Huddleston wrote:\n>> On Nov 29, 2010, at 12:12, Jonathan Nieder wrote:\n> \n>>> The section \"2) #ifdefs are ugly\" of\n>>> linux-2.6/Documentation/SubmittingPatches explains the rationale.\n>> \n>> I agree, but I don't really see a way around it here since this API is specific to OS X.\n> \n> Did you actually read that section? :)\n\nYes, but I don't have the time to \"do it right\" right now ... I'm contributing the patch that we are using back to the community in the spirit of OSS development, but I don't have the time resources currently to \"do it right\" at present.  I'll come back to it once time allows if nobody else picks it up.\n\nThanks,\nJeremy\n"},{"id":"156832","messageId":"20101129201958.GA10334@burratino","threadId":"25870","inReplyTo":"BED9E026-6804-4ABF-A26D-8F20699BAD0B@apple.com","subject":"Re: [PATCH] Fallback on _NSGetExecutablePath to get the executable path if using argv[0] fails","fromName":"Jonathan Nieder","fromEmail":"jrnieder@gmail.com","sentAt":"2010-11-29T20:19:58Z","receivedAt":"2010-11-29T20:19:58Z","isPatch":true,"sender":{"key":"jrnieder@gmail.com","avatar":"https://avatars.githubusercontent.com/u/281595?v=4"},"body":"Jeremy Huddleston wrote:\n> On Nov 29, 2010, at 13:50, Jonathan Nieder wrote:\n>> Jeremy Huddleston wrote:\n>>> On Nov 29, 2010, at 12:12, Jonathan Nieder wrote:\n\n>>>> The section \"2) #ifdefs are ugly\" of\n>>>> linux-2.6/Documentation/SubmittingPatches explains the rationale.\n>>> \n>>> I agree, but I don't really see a way around it here since this API is specific to OS X.\n>> \n>> Did you actually read that section? :)\n>\n> Yes, but I don't have the time to \"do it right\" right now ... I'm\n> contributing the patch that we are using back to the community in\n> the spirit of OSS development, but I don't have the time resources\n> currently to \"do it right\" at present.  I'll come back to it once\n> time allows if nobody else picks it up.\n\nOkay.  Thanks for reporting.\n\nMy guess is that the Windows version could be simplified, too, if\nwe introduce a function to get the path to the binary.  On Linux\nit should use \"readlink /proc/$$/exe\", on Darwin the function you\npointed to, on Win32 _pgmptr, as a fallback look for argv[0] in\n$PATH if someone on another platform is interested.\n\nJonathan\n"},{"id":"156840","messageId":"7veia32803.fsf@alter.siamese.dyndns.org","threadId":"25870","inReplyTo":"20101129184929.GA9441@burratino","subject":"Re: [PATCH updated] Fallback on _NSGetExecutablePath to get the executable path if using argv[0] fails","fromName":"Junio C Hamano","fromEmail":"gitster@pobox.com","sentAt":"2010-11-29T20:24:28Z","receivedAt":"2010-11-29T20:24:28Z","isPatch":true,"sender":{"key":"gitster@pobox.com","avatar":"https://avatars.githubusercontent.com/u/54884?v=4"},"body":"Jonathan Nieder <jrnieder@gmail.com> writes:\n\n>> --- a/exec_cmd.c\n>> +++ b/exec_cmd.c\n> [...]\n>> @@ -53,6 +57,19 @@ const char *git_extract_argv0_path(const char *argv0)\n>>  \tif (slash >= argv0) {\n>>  \t\targv0_path = xstrndup(argv0, slash - argv0);\n>>  \t\treturn slash + 1;\n>> +#if defined(__APPLE__)\n>> +\t} else {\n>> +\t\tchar new_argv0[PATH_MAX];\n>> +\t\tuint32_t new_argv0_s = PATH_MAX;\n>> +\t\tif(_NSGetExecutablePath(new_argv0, &new_argv0_s) == 0) {\n>> +\t\t\tslash = new_argv0 + strlen(new_argv0);\n>> +\t\t\twhile (new_argv0 <= slash && !is_dir_sep(*slash))\n>> +\t\t                slash--;\n>> +\n>> +\t\t\tif (slash >= new_argv0)\n>> +\t\t\t\targv0_path = xstrndup(new_argv0, slash - new_argv0);\n>> +\t\t}\n>> +#endif\n>\n> Can't this ifdef be avoided?  The ideal is for such code to be\n> abstracted away into helper functions in git-compat-util.h and compat/*.c.\n\nI had exactly the same reaction.  Also doesn't the above need to be\nprotected by defined(RUNTIME_PREFIX), too?\n"},{"id":"156841","messageId":"5873960D-848E-4039-B884-AA5B4E1787B8@apple.com","threadId":"25870","inReplyTo":"7veia32803.fsf@alter.siamese.dyndns.org","subject":"Re: [PATCH updated] Fallback on _NSGetExecutablePath to get the executable path if using argv[0] fails","fromName":"Jeremy Huddleston","fromEmail":"jeremyhu@apple.com","sentAt":"2010-11-29T21:02:00Z","receivedAt":"2010-11-29T21:02:00Z","isPatch":true,"sender":{"key":"jeremyhu@apple.com","avatar":"https://avatars.githubusercontent.com/u/1258676?v=4"},"body":"\nOn Nov 29, 2010, at 15:24, Junio C Hamano wrote:\n\n> Jonathan Nieder <jrnieder@gmail.com> writes:\n> \n>>> --- a/exec_cmd.c\n>>> +++ b/exec_cmd.c\n>> [...]\n>>> @@ -53,6 +57,19 @@ const char *git_extract_argv0_path(const char *argv0)\n>>> \tif (slash >= argv0) {\n>>> \t\targv0_path = xstrndup(argv0, slash - argv0);\n>>> \t\treturn slash + 1;\n>>> +#if defined(__APPLE__)\n>>> +\t} else {\n>>> +\t\tchar new_argv0[PATH_MAX];\n>>> +\t\tuint32_t new_argv0_s = PATH_MAX;\n>>> +\t\tif(_NSGetExecutablePath(new_argv0, &new_argv0_s) == 0) {\n>>> +\t\t\tslash = new_argv0 + strlen(new_argv0);\n>>> +\t\t\twhile (new_argv0 <= slash && !is_dir_sep(*slash))\n>>> +\t\t                slash--;\n>>> +\n>>> +\t\t\tif (slash >= new_argv0)\n>>> +\t\t\t\targv0_path = xstrndup(new_argv0, slash - new_argv0);\n>>> +\t\t}\n>>> +#endif\n>> \n>> Can't this ifdef be avoided?  The ideal is for such code to be\n>> abstracted away into helper functions in git-compat-util.h and compat/*.c.\n> \n> I had exactly the same reaction.  Also doesn't the above need to be\n> protected by defined(RUNTIME_PREFIX), too?\n\nIt already is inside of an #ifdef RUNTIME_PREFIX block.\n"},{"id":"156862","messageId":"7534C13D-A52A-4BA4-B8C5-14E17CFA0351@sb.org","threadId":"25870","inReplyTo":"20101129171211.GL8037@burratino","subject":"Re: [PATCH] Fallback on _NSGetExecutablePath to get the executable path if using argv[0] fails","fromName":"Kevin Ballard","fromEmail":"kevin@sb.org","sentAt":"2010-11-29T23:13:22Z","receivedAt":"2010-11-29T23:13:22Z","isPatch":true,"sender":{"key":"kevin@sb.org","avatar":"https://avatars.githubusercontent.com/u/714?v=4"},"body":"On Nov 29, 2010, at 9:12 AM, Jonathan Nieder wrote:\n\n> The section \"2) #ifdefs are ugly\" of\n> linux-2.6/Documentation/SubmittingPatches explains the rationale.\n\nMight this be worth pulling into git.git/Documentation/CodingGuidelines?\n\n-Kevin Ballard\n"},{"id":"157174","messageId":"20101203074259.GB18202@burratino","threadId":"25870","inReplyTo":"7534C13D-A52A-4BA4-B8C5-14E17CFA0351@sb.org","subject":"Re: [PATCH] Fallback on _NSGetExecutablePath to get the executable path if using argv[0] fails","fromName":"Jonathan Nieder","fromEmail":"jrnieder@gmail.com","sentAt":"2010-12-03T07:42:59Z","receivedAt":"2010-12-03T07:42:59Z","isPatch":true,"sender":{"key":"jrnieder@gmail.com","avatar":"https://avatars.githubusercontent.com/u/281595?v=4"},"body":"Kevin Ballard wrote:\n> On Nov 29, 2010, at 9:12 AM, Jonathan Nieder wrote:\n\n>> The section \"2) #ifdefs are ugly\" of\n>> linux-2.6/Documentation/SubmittingPatches explains the rationale.\n>\n> Might this be worth pulling into git.git/Documentation/CodingGuidelines?\n\nYes, the example there includes good advice I wish I had received\nsooner, and Documentation/CodingGuidelines seems like a good place to\nhelp people find it.  Do you have some wording in mind?\n"},{"id":"157175","messageId":"CC3783DE-FE16-45E5-B53B-EC8AA133B876@sb.org","threadId":"25870","inReplyTo":"20101203074259.GB18202@burratino","subject":"Re: [PATCH] Fallback on _NSGetExecutablePath to get the executable path if using argv[0] fails","fromName":"Kevin Ballard","fromEmail":"kevin@sb.org","sentAt":"2010-12-03T07:50:03Z","receivedAt":"2010-12-03T07:50:03Z","isPatch":true,"sender":{"key":"kevin@sb.org","avatar":"https://avatars.githubusercontent.com/u/714?v=4"},"body":"On Dec 2, 2010, at 11:42 PM, Jonathan Nieder wrote:\n\n> Kevin Ballard wrote:\n>> On Nov 29, 2010, at 9:12 AM, Jonathan Nieder wrote:\n> \n>>> The section \"2) #ifdefs are ugly\" of\n>>> linux-2.6/Documentation/SubmittingPatches explains the rationale.\n>> \n>> Might this be worth pulling into git.git/Documentation/CodingGuidelines?\n> \n> Yes, the example there includes good advice I wish I had received\n> sooner, and Documentation/CodingGuidelines seems like a good place to\n> help people find it.  Do you have some wording in mind?\n\nNot particularly. It just seems that if we're going to point people at the\nlinux-2.6 documentation, then what we're referencing should be pulled into\nour own docs. It's not reasonable to expect people to read the documentation\nfrom another project to find out what they should do in this one.\n\n-Kevin Ballard\n"}]}