* [PATCH v2 6/6] mingw: get rid of getpass implementation
From: Erik Faye-Lund @ 2012-12-04 8:10 UTC (permalink / raw)
To: git; +Cc: msysgit, johannes.schindelin, gitster, peff
In-Reply-To: <1354608642-5316-1-git-send-email-kusmabite@gmail.com>
There's no remaining call-sites, and as pointed out in the
previous commit message, it's not quite ideal. So let's just
lose it.
Signed-off-by: Erik Faye-Lund <kusmabite@gmail.com>
---
compat/mingw.c | 15 ---------------
compat/mingw.h | 2 --
2 files changed, 17 deletions(-)
diff --git a/compat/mingw.c b/compat/mingw.c
index 33ddfdf..5fc14b7 100644
--- a/compat/mingw.c
+++ b/compat/mingw.c
@@ -1758,21 +1758,6 @@ int link(const char *oldpath, const char *newpath)
return 0;
}
-char *getpass(const char *prompt)
-{
- struct strbuf buf = STRBUF_INIT;
-
- fputs(prompt, stderr);
- for (;;) {
- char c = _getch();
- if (c == '\r' || c == '\n')
- break;
- strbuf_addch(&buf, c);
- }
- fputs("\n", stderr);
- return strbuf_detach(&buf, NULL);
-}
-
pid_t waitpid(pid_t pid, int *status, int options)
{
HANDLE h = OpenProcess(SYNCHRONIZE | PROCESS_QUERY_INFORMATION,
diff --git a/compat/mingw.h b/compat/mingw.h
index 6b9e69a..f494ecb 100644
--- a/compat/mingw.h
+++ b/compat/mingw.h
@@ -55,8 +55,6 @@ struct passwd {
char *pw_dir;
};
-extern char *getpass(const char *prompt);
-
typedef void (__cdecl *sig_handler_t)(int);
struct sigaction {
sig_handler_t sa_handler;
--
1.8.0.4.g3c6fb4f.dirty
--
*** Please reply-to-all at all times ***
*** (do not pretend to know who is subscribed and who is not) ***
*** Please avoid top-posting. ***
The msysGit Wiki is here: https://github.com/msysgit/msysgit/wiki - Github accounts are free.
You received this message because you are subscribed to the Google
Groups "msysGit" group.
To post to this group, send email to msysgit@googlegroups.com
To unsubscribe from this group, send email to
msysgit+unsubscribe@googlegroups.com
For more options, and view previous threads, visit this group at
http://groups.google.com/group/msysgit?hl=en_US?hl=en
^ permalink raw reply related
* [PATCH v2 5/6] mingw: reuse tty-version of git_terminal_prompt
From: Erik Faye-Lund @ 2012-12-04 8:10 UTC (permalink / raw)
To: git; +Cc: msysgit, johannes.schindelin, gitster, peff
In-Reply-To: <1354608642-5316-1-git-send-email-kusmabite@gmail.com>
The getpass-implementation we use on Windows isn't at all ideal;
it works in raw-mode (as opposed to cooked mode), and as a result
does not deal correcly with deletion, arrow-keys etc.
Instead, use cooked mode to read a line at the time, allowing the
C run-time to process the input properly.
Since we set files to be opened in binary-mode by default on
Windows, introduce a FORCE_TEXT macro that expands to the "t"
modifier that forces the terminal to be opened in text-mode so we
do not have to deal with CRLF issues.
Signed-off-by: Erik Faye-Lund <kusmabite@gmail.com>
---
compat/terminal.c | 69 +++++++++++++++++++++++++++++++++++++++++++++++--------
1 file changed, 60 insertions(+), 9 deletions(-)
diff --git a/compat/terminal.c b/compat/terminal.c
index 9aecad6..9b5e3d1 100644
--- a/compat/terminal.c
+++ b/compat/terminal.c
@@ -3,8 +3,22 @@
#include "sigchain.h"
#include "strbuf.h"
+#if defined(HAVE_DEV_TTY) || defined(WIN32)
+
+static void restore_term(void);
+
+static void restore_term_on_signal(int sig)
+{
+ restore_term();
+ sigchain_pop(sig);
+ raise(sig);
+}
+
#ifdef HAVE_DEV_TTY
+#define INPUT_PATH "/dev/tty"
+#define OUTPUT_PATH "/dev/tty"
+
static int term_fd = -1;
static struct termios old_term;
@@ -18,13 +32,6 @@ static void restore_term(void)
term_fd = -1;
}
-static void restore_term_on_signal(int sig)
-{
- restore_term();
- sigchain_pop(sig);
- raise(sig);
-}
-
static int disable_echo(void)
{
struct termios t;
@@ -46,17 +53,61 @@ error:
return -1;
}
+#elif defined(WIN32)
+
+#define INPUT_PATH "CONIN$"
+#define OUTPUT_PATH "CONOUT$"
+#define FORCE_TEXT "t"
+
+static HANDLE hconin = INVALID_HANDLE_VALUE;
+static DWORD cmode;
+
+static void restore_term(void)
+{
+ if (hconin == INVALID_HANDLE_VALUE)
+ return;
+
+ SetConsoleMode(hconin, cmode);
+ CloseHandle(hconin);
+ hconin = INVALID_HANDLE_VALUE;
+}
+
+static int disable_echo(void)
+{
+ hconin = CreateFile("CONIN$", GENERIC_READ | GENERIC_WRITE,
+ FILE_SHARE_READ, NULL, OPEN_EXISTING,
+ FILE_ATTRIBUTE_NORMAL, NULL);
+ if (hconin == INVALID_HANDLE_VALUE)
+ return -1;
+
+ GetConsoleMode(hconin, &cmode);
+ sigchain_push_common(restore_term_on_signal);
+ if (!SetConsoleMode(hconin, cmode & (~ENABLE_ECHO_INPUT))) {
+ CloseHandle(hconin);
+ hconin = INVALID_HANDLE_VALUE;
+ return -1;
+ }
+
+ return 0;
+}
+
+#endif
+
+#ifndef FORCE_TEXT
+#define FORCE_TEXT
+#endif
+
char *git_terminal_prompt(const char *prompt, int echo)
{
static struct strbuf buf = STRBUF_INIT;
int r;
FILE *input_fh, *output_fh;
- input_fh = fopen("/dev/tty", "r");
+ input_fh = fopen(INPUT_PATH, "r" FORCE_TEXT);
if (!input_fh)
return NULL;
- output_fh = fopen("/dev/tty", "w");
+ output_fh = fopen(OUTPUT_PATH, "w" FORCE_TEXT);
if (!output_fh) {
fclose(input_fh);
return NULL;
--
1.8.0.4.g3c6fb4f.dirty
--
*** Please reply-to-all at all times ***
*** (do not pretend to know who is subscribed and who is not) ***
*** Please avoid top-posting. ***
The msysGit Wiki is here: https://github.com/msysgit/msysgit/wiki - Github accounts are free.
You received this message because you are subscribed to the Google
Groups "msysGit" group.
To post to this group, send email to msysgit@googlegroups.com
To unsubscribe from this group, send email to
msysgit+unsubscribe@googlegroups.com
For more options, and view previous threads, visit this group at
http://groups.google.com/group/msysgit?hl=en_US?hl=en
^ permalink raw reply related
* [PATCH v2 4/6] compat/terminal: separate input and output handles
From: Erik Faye-Lund @ 2012-12-04 8:10 UTC (permalink / raw)
To: git; +Cc: msysgit, johannes.schindelin, gitster, peff
In-Reply-To: <1354608642-5316-1-git-send-email-kusmabite@gmail.com>
On Windows, the terminal cannot be opened in read-write mode, so
we need distinct pairs for reading and writing. Since this works
fine on other platforms as well, always open them in pairs.
Signed-off-by: Erik Faye-Lund <kusmabite@gmail.com>
---
compat/terminal.c | 29 ++++++++++++++++++-----------
1 file changed, 18 insertions(+), 11 deletions(-)
diff --git a/compat/terminal.c b/compat/terminal.c
index a6212ca..9aecad6 100644
--- a/compat/terminal.c
+++ b/compat/terminal.c
@@ -50,29 +50,36 @@ char *git_terminal_prompt(const char *prompt, int echo)
{
static struct strbuf buf = STRBUF_INIT;
int r;
- FILE *fh;
+ FILE *input_fh, *output_fh;
- fh = fopen("/dev/tty", "w+");
- if (!fh)
+ input_fh = fopen("/dev/tty", "r");
+ if (!input_fh)
return NULL;
+ output_fh = fopen("/dev/tty", "w");
+ if (!output_fh) {
+ fclose(input_fh);
+ return NULL;
+ }
+
if (!echo && disable_echo()) {
- fclose(fh);
+ fclose(input_fh);
+ fclose(output_fh);
return NULL;
}
- fputs(prompt, fh);
- fflush(fh);
+ fputs(prompt, output_fh);
+ fflush(output_fh);
- r = strbuf_getline(&buf, fh, '\n');
+ r = strbuf_getline(&buf, input_fh, '\n');
if (!echo) {
- fseek(fh, SEEK_CUR, 0);
- putc('\n', fh);
- fflush(fh);
+ putc('\n', output_fh);
+ fflush(output_fh);
}
restore_term();
- fclose(fh);
+ fclose(input_fh);
+ fclose(output_fh);
if (r == EOF)
return NULL;
--
1.8.0.4.g3c6fb4f.dirty
--
*** Please reply-to-all at all times ***
*** (do not pretend to know who is subscribed and who is not) ***
*** Please avoid top-posting. ***
The msysGit Wiki is here: https://github.com/msysgit/msysgit/wiki - Github accounts are free.
You received this message because you are subscribed to the Google
Groups "msysGit" group.
To post to this group, send email to msysgit@googlegroups.com
To unsubscribe from this group, send email to
msysgit+unsubscribe@googlegroups.com
For more options, and view previous threads, visit this group at
http://groups.google.com/group/msysgit?hl=en_US?hl=en
^ permalink raw reply related
* [PATCH v2 3/6] compat/terminal: factor out echo-disabling
From: Erik Faye-Lund @ 2012-12-04 8:10 UTC (permalink / raw)
To: git; +Cc: msysgit, johannes.schindelin, gitster, peff
In-Reply-To: <1354608642-5316-1-git-send-email-kusmabite@gmail.com>
By moving the echo-disabling code to a separate function, we can
implement OS-specific versions of it for non-POSIX platforms.
Signed-off-by: Erik Faye-Lund <kusmabite@gmail.com>
---
compat/terminal.c | 43 +++++++++++++++++++++++++------------------
1 file changed, 25 insertions(+), 18 deletions(-)
diff --git a/compat/terminal.c b/compat/terminal.c
index bbb038d..a6212ca 100644
--- a/compat/terminal.c
+++ b/compat/terminal.c
@@ -14,6 +14,7 @@ static void restore_term(void)
return;
tcsetattr(term_fd, TCSAFLUSH, &old_term);
+ close(term_fd);
term_fd = -1;
}
@@ -24,6 +25,27 @@ static void restore_term_on_signal(int sig)
raise(sig);
}
+static int disable_echo(void)
+{
+ struct termios t;
+
+ term_fd = open("/dev/tty", O_RDWR);
+ if (tcgetattr(term_fd, &t) < 0)
+ goto error;
+
+ old_term = t;
+ sigchain_push_common(restore_term_on_signal);
+
+ t.c_lflag &= ~ECHO;
+ if (!tcsetattr(term_fd, TCSAFLUSH, &t))
+ return 0;
+
+error:
+ close(term_fd);
+ term_fd = -1;
+ return -1;
+}
+
char *git_terminal_prompt(const char *prompt, int echo)
{
static struct strbuf buf = STRBUF_INIT;
@@ -34,24 +56,9 @@ char *git_terminal_prompt(const char *prompt, int echo)
if (!fh)
return NULL;
- if (!echo) {
- struct termios t;
-
- if (tcgetattr(fileno(fh), &t) < 0) {
- fclose(fh);
- return NULL;
- }
-
- old_term = t;
- term_fd = fileno(fh);
- sigchain_push_common(restore_term_on_signal);
-
- t.c_lflag &= ~ECHO;
- if (tcsetattr(fileno(fh), TCSAFLUSH, &t) < 0) {
- term_fd = -1;
- fclose(fh);
- return NULL;
- }
+ if (!echo && disable_echo()) {
+ fclose(fh);
+ return NULL;
}
fputs(prompt, fh);
--
1.8.0.4.g3c6fb4f.dirty
--
*** Please reply-to-all at all times ***
*** (do not pretend to know who is subscribed and who is not) ***
*** Please avoid top-posting. ***
The msysGit Wiki is here: https://github.com/msysgit/msysgit/wiki - Github accounts are free.
You received this message because you are subscribed to the Google
Groups "msysGit" group.
To post to this group, send email to msysgit@googlegroups.com
To unsubscribe from this group, send email to
msysgit+unsubscribe@googlegroups.com
For more options, and view previous threads, visit this group at
http://groups.google.com/group/msysgit?hl=en_US?hl=en
^ permalink raw reply related
* [PATCH v2 2/6] mingw: make fgetc raise SIGINT if apropriate
From: Erik Faye-Lund @ 2012-12-04 8:10 UTC (permalink / raw)
To: git; +Cc: msysgit, johannes.schindelin, gitster, peff
In-Reply-To: <1354608642-5316-1-git-send-email-kusmabite@gmail.com>
Set a control-handler to prevent the process from terminating, and
simulate SIGINT so it can be handled by a signal-handler as usual.
Signed-off-by: Erik Faye-Lund <kusmabite@gmail.com>
---
compat/mingw.c | 76 ++++++++++++++++++++++++++++++++++++++++++++++++++--------
compat/mingw.h | 6 +++++
2 files changed, 72 insertions(+), 10 deletions(-)
diff --git a/compat/mingw.c b/compat/mingw.c
index 78e8f54..33ddfdf 100644
--- a/compat/mingw.c
+++ b/compat/mingw.c
@@ -319,6 +319,31 @@ ssize_t mingw_write(int fd, const void *buf, size_t count)
return write(fd, buf, min(count, 31 * 1024 * 1024));
}
+static BOOL WINAPI ctrl_ignore(DWORD type)
+{
+ return TRUE;
+}
+
+#undef fgetc
+int mingw_fgetc(FILE *stream)
+{
+ int ch;
+ if (!isatty(_fileno(stream)))
+ return fgetc(stream);
+
+ SetConsoleCtrlHandler(ctrl_ignore, TRUE);
+ while (1) {
+ ch = fgetc(stream);
+ if (ch != EOF || GetLastError() != ERROR_OPERATION_ABORTED)
+ break;
+
+ /* Ctrl+C was pressed, simulate SIGINT and retry */
+ mingw_raise(SIGINT);
+ }
+ SetConsoleCtrlHandler(ctrl_ignore, FALSE);
+ return ch;
+}
+
#undef fopen
FILE *mingw_fopen (const char *filename, const char *otype)
{
@@ -1524,7 +1549,7 @@ static HANDLE timer_event;
static HANDLE timer_thread;
static int timer_interval;
static int one_shot;
-static sig_handler_t timer_fn = SIG_DFL;
+static sig_handler_t timer_fn = SIG_DFL, sigint_fn = SIG_DFL;
/* The timer works like this:
* The thread, ticktack(), is a trivial routine that most of the time
@@ -1538,13 +1563,7 @@ static sig_handler_t timer_fn = SIG_DFL;
static unsigned __stdcall ticktack(void *dummy)
{
while (WaitForSingleObject(timer_event, timer_interval) == WAIT_TIMEOUT) {
- if (timer_fn == SIG_DFL) {
- if (isatty(STDERR_FILENO))
- fputs("Alarm clock\n", stderr);
- exit(128 + SIGALRM);
- }
- if (timer_fn != SIG_IGN)
- timer_fn(SIGALRM);
+ mingw_raise(SIGALRM);
if (one_shot)
break;
}
@@ -1635,12 +1654,49 @@ int sigaction(int sig, struct sigaction *in, struct sigaction *out)
sig_handler_t mingw_signal(int sig, sig_handler_t handler)
{
sig_handler_t old = timer_fn;
- if (sig != SIGALRM)
+
+ switch (sig) {
+ case SIGALRM:
+ timer_fn = handler;
+ break;
+
+ case SIGINT:
+ sigint_fn = handler;
+ break;
+
+ default:
return signal(sig, handler);
- timer_fn = handler;
+ }
+
return old;
}
+#undef raise
+int mingw_raise(int sig)
+{
+ switch (sig) {
+ case SIGALRM:
+ if (timer_fn == SIG_DFL) {
+ if (isatty(STDERR_FILENO))
+ fputs("Alarm clock\n", stderr);
+ exit(128 + SIGALRM);
+ } else if (timer_fn != SIG_IGN)
+ timer_fn(SIGALRM);
+ return 0;
+
+ case SIGINT:
+ if (sigint_fn == SIG_DFL)
+ exit(128 + SIGINT);
+ else if (sigint_fn != SIG_IGN)
+ sigint_fn(SIGINT);
+ return 0;
+
+ default:
+ return raise(sig);
+ }
+}
+
+
static const char *make_backslash_path(const char *path)
{
static char buf[PATH_MAX + 1];
diff --git a/compat/mingw.h b/compat/mingw.h
index 61a6521..6b9e69a 100644
--- a/compat/mingw.h
+++ b/compat/mingw.h
@@ -179,6 +179,9 @@ int mingw_open (const char *filename, int oflags, ...);
ssize_t mingw_write(int fd, const void *buf, size_t count);
#define write mingw_write
+int mingw_fgetc(FILE *stream);
+#define fgetc mingw_fgetc
+
FILE *mingw_fopen (const char *filename, const char *otype);
#define fopen mingw_fopen
@@ -287,6 +290,9 @@ static inline unsigned int git_ntohl(unsigned int x)
sig_handler_t mingw_signal(int sig, sig_handler_t handler);
#define signal mingw_signal
+int mingw_raise(int sig);
+#define raise mingw_raise
+
/*
* ANSI emulation wrappers
*/
--
1.8.0.4.g3c6fb4f.dirty
--
*** Please reply-to-all at all times ***
*** (do not pretend to know who is subscribed and who is not) ***
*** Please avoid top-posting. ***
The msysGit Wiki is here: https://github.com/msysgit/msysgit/wiki - Github accounts are free.
You received this message because you are subscribed to the Google
Groups "msysGit" group.
To post to this group, send email to msysgit@googlegroups.com
To unsubscribe from this group, send email to
msysgit+unsubscribe@googlegroups.com
For more options, and view previous threads, visit this group at
http://groups.google.com/group/msysgit?hl=en_US?hl=en
^ permalink raw reply related
* [PATCH v2 1/6] mingw: correct exit-code for SIGALRM's SIG_DFL
From: Erik Faye-Lund @ 2012-12-04 8:10 UTC (permalink / raw)
To: git; +Cc: msysgit, johannes.schindelin, gitster, peff
In-Reply-To: <1354608642-5316-1-git-send-email-kusmabite@gmail.com>
Make sure SIG_DFL for SIGALRM exits with 128 + SIGALRM so other
processes can diagnose why it exits.
While we're at it, make sure we only write to stderr if it's a
terminal, and change the output to match that of Linux.
Signed-off-by: Erik Faye-Lund <kusmabite@gmail.com>
---
compat/mingw.c | 7 +++++--
1 file changed, 5 insertions(+), 2 deletions(-)
diff --git a/compat/mingw.c b/compat/mingw.c
index afc892d..78e8f54 100644
--- a/compat/mingw.c
+++ b/compat/mingw.c
@@ -1538,8 +1538,11 @@ static sig_handler_t timer_fn = SIG_DFL;
static unsigned __stdcall ticktack(void *dummy)
{
while (WaitForSingleObject(timer_event, timer_interval) == WAIT_TIMEOUT) {
- if (timer_fn == SIG_DFL)
- die("Alarm");
+ if (timer_fn == SIG_DFL) {
+ if (isatty(STDERR_FILENO))
+ fputs("Alarm clock\n", stderr);
+ exit(128 + SIGALRM);
+ }
if (timer_fn != SIG_IGN)
timer_fn(SIGALRM);
if (one_shot)
--
1.8.0.4.g3c6fb4f.dirty
--
*** Please reply-to-all at all times ***
*** (do not pretend to know who is subscribed and who is not) ***
*** Please avoid top-posting. ***
The msysGit Wiki is here: https://github.com/msysgit/msysgit/wiki - Github accounts are free.
You received this message because you are subscribed to the Google
Groups "msysGit" group.
To post to this group, send email to msysgit@googlegroups.com
To unsubscribe from this group, send email to
msysgit+unsubscribe@googlegroups.com
For more options, and view previous threads, visit this group at
http://groups.google.com/group/msysgit?hl=en_US?hl=en
^ permalink raw reply related
* [PATCH v2 0/6] win32: support echo for terminal-prompt
From: Erik Faye-Lund @ 2012-12-04 8:10 UTC (permalink / raw)
To: git; +Cc: msysgit, johannes.schindelin, gitster, peff
So here's v2 of this series. For reference, you can find v1 and
it's discussions here:
http://mid.gmane.org/1352815288-3996-1-git-send-email-kusmabite@gmail.com
The changes since the last round:
* 1/6: This patch has been added. It was missing in the last round,
due to stupidity on my behalf. I'm sorry about that.
* 3/6: This patch got a fixup for the disable_echo function signature
squashed in. I forgot "void" for the empty parameter list.
Thanks to Junio for noticing.
Otherwise, things are unchanged.
Erik Faye-Lund (6):
mingw: correct exit-code for SIGALRM's SIG_DFL
mingw: make fgetc raise SIGINT if apropriate
compat/terminal: factor out echo-disabling
compat/terminal: separate input and output handles
mingw: reuse tty-version of git_terminal_prompt
mingw: get rid of getpass implementation
compat/mingw.c | 88 +++++++++++++++++++++++++++----------
compat/mingw.h | 8 +++-
compat/terminal.c | 129 ++++++++++++++++++++++++++++++++++++++++--------------
3 files changed, 169 insertions(+), 56 deletions(-)
--
1.8.0.4.g3c6fb4f.dirty
--
*** Please reply-to-all at all times ***
*** (do not pretend to know who is subscribed and who is not) ***
*** Please avoid top-posting. ***
The msysGit Wiki is here: https://github.com/msysgit/msysgit/wiki - Github accounts are free.
You received this message because you are subscribed to the Google
Groups "msysGit" group.
To post to this group, send email to msysgit@googlegroups.com
To unsubscribe from this group, send email to
msysgit+unsubscribe@googlegroups.com
For more options, and view previous threads, visit this group at
http://groups.google.com/group/msysgit?hl=en_US?hl=en
^ permalink raw reply
* Re: [RFC] Add basic syntax check on shell scripts
From: Nguyen Thai Ngoc Duy @ 2012-12-04 7:20 UTC (permalink / raw)
To: Junio C Hamano; +Cc: Torsten Bögershausen, git
In-Reply-To: <7vzk1vrs63.fsf@alter.siamese.dyndns.org>
On Mon, Dec 3, 2012 at 11:56 PM, Junio C Hamano <gitster@pobox.com> wrote:
> Torsten Bögershausen <tboegi@web.de> writes:
>
>> The test suite needs to be run on different platforms.
>> As it may be difficult for contributors to catch syntax
>> which work on GNU/linux, but is unportable, make a quick check
>> for the most common problems.
>> "sed -i", "echo -n" or "array in shell scripts"
>> This list is not complete, and may need to be extended
>>
>> Signed-off-by: Torsten Bögershausen <tboegi@web.de>
>> ---
>> We add 1 second test execution time
>> Is this a useful idea at all?
>
> Please do not name it after t/t[0-9]*.sh pattern, which are about
> testing git.
>
> This (once it gets cleaned up to reduce false positives) belongs to
> "cd t && make test-lint".
Or a project commit hook? We can see how it goes and whether we can
improve anything for projects that rely on hooks.
--
Duy
^ permalink raw reply
* [PATCHv2] l10n: de.po: translate 22 new messages
From: Ralf Thielow @ 2012-12-04 6:19 UTC (permalink / raw)
To: git; +Cc: trast, jk, stimming, git, Ralf Thielow
In-Reply-To: <50BCC0A3.4050203@drmicha.warpmail.net>
Translate 22 new messages came from git.pot
updates in 9306b5b (l10n: Update git.pot (3 new,
6 removed messages)), fe52cd6 (l10n: Update git.pot
(14 new, 3 removed messages)) and f9472e3
(l10n: Update git.pot (5 new, 1 removed messages)).
Signed-off-by: Ralf Thielow <ralf.thielow@gmail.com>
Reviewed-by: Michael J Gruber <git@drmicha.warpmail.net>
---
Thanks for review!
>> -" (benutze \"git am --abort\" um den ursprünglichen Zweig wiederherzustellen)"
>> +" (benutze \"git pull\" um den externen Zweig mit Deinem zusammenzuführen)\n"
[...]
> BTW: Is there a standard about capitalising or not "Deine/Du" in de.pot?
> I think I've seen both here. (New spelling after the reform(s)
> recommends du/deine but Sie/Ihr, me thinks.)
Usually it's written in lower case. But there are some original messages
starting with capital letters, in which case the translation does simply the
same. In this special case, "Deinem" was meant as a short for "dein Zweig".
Switching to formal addressing is a point on my TODO list.
Thanks,
Ralf
po/de.po | 68 ++++++++++++++++++++++++++++++++++------------------------------
1 file changed, 36 insertions(+), 32 deletions(-)
diff --git a/po/de.po b/po/de.po
index a0bf3da..0e8ed54 100644
--- a/po/de.po
+++ b/po/de.po
@@ -5,7 +5,7 @@
#
msgid ""
msgstr ""
-"Project-Id-Version: git 1.8.0\n"
+"Project-Id-Version: git 1.8.1\n"
"Report-Msgid-Bugs-To: Git Mailing List <git@vger.kernel.org>\n"
"POT-Creation-Date: 2012-11-30 12:40+0800\n"
"PO-Revision-Date: 2012-10-02 19:35+0200\n"
@@ -130,6 +130,8 @@ msgid ""
"Negative patterns are forbidden in git attributes\n"
"Use '\\!' for literal leading exclamation."
msgstr ""
+"Verneinende Muster sind in Git-Attributen verboten.\n"
+"Benutze '\\!' für führende Ausrufezeichen."
#: bundle.c:36
#, c-format
@@ -305,22 +307,21 @@ msgstr[0] "vor %lu Jahr"
msgstr[1] "vor %lu Jahren"
#: diff.c:111
-#, fuzzy, c-format
+#, c-format
msgid " Failed to parse dirstat cut-off percentage '%s'\n"
msgstr ""
-" Fehler beim Parsen des abgeschnittenen \"dirstat\" Prozentsatzes '%.*s'\n"
+" Fehler beim Parsen des abgeschnittenen \"dirstat\" Prozentsatzes '%s'\n"
#: diff.c:116
-#, fuzzy, c-format
+#, c-format
msgid " Unknown dirstat parameter '%s'\n"
-msgstr " Unbekannter \"dirstat\" Parameter '%.*s'\n"
+msgstr " Unbekannter \"dirstat\" Parameter '%s'\n"
#: diff.c:194
-#, fuzzy, c-format
+#, c-format
msgid "Unknown value for 'diff.submodule' config variable: '%s'"
msgstr ""
-"Fehler in 'diff.dirstat' Konfigurationsvariable gefunden:\n"
-"%s"
+"Unbekannter Wert in Konfigurationsvariable 'diff.dirstat': '%s'"
#: diff.c:237
#, c-format
@@ -341,11 +342,10 @@ msgstr ""
"%s"
#: diff.c:3508
-#, fuzzy, c-format
+#, c-format
msgid "Failed to parse --submodule option parameter: '%s'"
msgstr ""
-"Fehler beim Parsen des --dirstat/-X Optionsparameters:\n"
-"%s"
+"Fehler beim Parsen des --submodule Optionsparameters: '%s'"
#: gpg-interface.c:59
msgid "could not run gpg."
@@ -726,7 +726,7 @@ msgstr[1] "Dein Zweig ist vor '%s' um %d Versionen.\n"
#: remote.c:1637
msgid " (use \"git push\" to publish your local commits)\n"
-msgstr ""
+msgstr " (benutze \"git push\" um deine lokalen Versionen herauszubringen)\n"
#: remote.c:1640
#, c-format
@@ -740,10 +740,9 @@ msgstr[1] ""
"werden.\n"
#: remote.c:1647
-#, fuzzy
msgid " (use \"git pull\" to update your local branch)\n"
msgstr ""
-" (benutze \"git am --abort\" um den ursprünglichen Zweig wiederherzustellen)"
+" (benutze \"git pull\" um deinen lokalen Zweig zu aktualisieren)\n"
#: remote.c:1650
#, c-format
@@ -761,10 +760,9 @@ msgstr[1] ""
"und haben jeweils %d und %d unterschiedliche Versionen.\n"
#: remote.c:1659
-#, fuzzy
msgid " (use \"git pull\" to merge the remote branch into yours)\n"
msgstr ""
-" (benutze \"git am --abort\" um den ursprünglichen Zweig wiederherzustellen)"
+" (benutze \"git pull\" um deinen Zweig mit dem externen zusammenzuführen)\n"
#: sequencer.c:123 builtin/merge.c:761 builtin/merge.c:874 builtin/merge.c:984
#: builtin/merge.c:994
@@ -2614,9 +2612,8 @@ msgid "git check-attr [-a | --all | attr...] [--] pathname..."
msgstr "git check-attr [-a | --all | Attribut...] [--] Pfadname..."
#: builtin/check-attr.c:12
-#, fuzzy
msgid "git check-attr --stdin [-z] [-a | --all | attr...] < <list-of-paths>"
-msgstr "git check-attr --stdin [-a | --all | Attribut...] < <Liste-von-Pfaden>"
+msgstr "git check-attr --stdin [-z] [-a | --all | Attribut...] < <Liste-von-Pfaden>"
#: builtin/check-attr.c:19
msgid "report all attributes set on file"
@@ -3596,9 +3593,8 @@ msgid "Paths with -a does not make sense."
msgstr "Pfade mit -a machen keinen Sinn."
#: builtin/commit.c:1067 builtin/commit.c:1202
-#, fuzzy
msgid "--long and -z are incompatible"
-msgstr "--column und -n sind inkompatibel"
+msgstr "--long und -z sind inkompatibel"
#: builtin/commit.c:1162 builtin/commit.c:1398
msgid "show status concisely"
@@ -3613,9 +3609,8 @@ msgid "machine-readable output"
msgstr "maschinenlesbare Ausgabe"
#: builtin/commit.c:1169 builtin/commit.c:1404
-#, fuzzy
msgid "show status in long format (default)"
-msgstr "zeigt zwischengespeicherten Dateien in der Ausgabe an (Standard)"
+msgstr "zeigt Status im Langformat (Standard)"
#: builtin/commit.c:1172 builtin/commit.c:1407
msgid "terminate entries with NUL"
@@ -4789,7 +4784,7 @@ msgstr "zeigt nur Übereinstimmungen von Dateien, die allen Mustern entsprechen"
#: builtin/grep.c:736
msgid "show parse tree for grep expression"
-msgstr ""
+msgstr "zeigt geparsten Baum für \"grep\"-Ausdruck"
#: builtin/grep.c:740
msgid "pager"
@@ -8029,6 +8024,9 @@ msgid ""
"submodule '%s' (or one of its nested submodules) uses a .git directory\n"
"(use 'rm -rf' if you really want to remove it including all of its history)"
msgstr ""
+"Unterprojekt '%s' (oder ein geschachteltes Unterprojekt hiervon) verwendet\n"
+"ein .git-Verzeichnis (benutze 'rm -rf' wenn du dieses wirklich mitsamt\n"
+"seiner Historie löschen möchtest)"
#: builtin/rm.c:174
#, c-format
@@ -8254,9 +8252,8 @@ msgid "git symbolic-ref [options] name [ref]"
msgstr "git symbolic-ref [Optionen] name [ref]"
#: builtin/symbolic-ref.c:8
-#, fuzzy
msgid "git symbolic-ref -d [-q] name"
-msgstr "git symbolic-ref [Optionen] name [ref]"
+msgstr "git symbolic-ref -d [-q] name"
#: builtin/symbolic-ref.c:40
msgid "suppress error message for non-symbolic (detached) refs"
@@ -8264,9 +8261,8 @@ msgstr ""
"unterdrückt Fehlermeldungen für nicht-symbolische (losgelöste) Referenzen"
#: builtin/symbolic-ref.c:41
-#, fuzzy
msgid "delete symbolic ref"
-msgstr "löscht ersetzende Referenzen"
+msgstr "löscht symbolische Referenzen"
#: builtin/symbolic-ref.c:42
msgid "shorten ref output"
@@ -9207,7 +9203,8 @@ msgstr "Kein Neuaufbau im Gange?"
#: git-rebase.sh:312
msgid "The --edit-todo action can only be used during interactive rebase."
-msgstr ""
+msgstr "Die --edit-todo Aktion kann nur während eines interaktiven "
+"Neuaufbaus benutzt werden."
#: git-rebase.sh:319
msgid "Cannot read HEAD"
@@ -9492,19 +9489,24 @@ msgstr "'$sm_path' existiert bereits und ist kein gültiges Git-Projektarchiv"
#: git-submodule.sh:365
#, sh-format
msgid "A git directory for '$sm_name' is found locally with remote(s):"
-msgstr ""
+msgstr "Ein Git-Verzeichnis für '$sm_name' wurde lokal gefunden mit den "
+"Fernarchiv(en):"
#: git-submodule.sh:367
#, sh-format
msgid ""
"If you want to reuse this local git directory instead of cloning again from"
msgstr ""
+"Wenn du dieses lokale Git-Verzeichnis wiederverwenden möchtest, anstatt "
+"erneut zu klonen"
#: git-submodule.sh:369
#, sh-format
msgid ""
"use the '--force' option. If the local git directory is not the correct repo"
msgstr ""
+"benutze die Option '--force'. Wenn das lokale Git-Verzeichnis nicht das "
+"korrekte Projektarchiv ist"
#: git-submodule.sh:370
#, sh-format
@@ -9512,11 +9514,13 @@ msgid ""
"or you are unsure what this means choose another name with the '--name' "
"option."
msgstr ""
+"oder du dir unsicher bist, was das bedeutet, wähle einen anderen Namen mit "
+"der Option '--name'."
#: git-submodule.sh:372
#, sh-format
msgid "Reactivating local git directory for submodule '$sm_name'."
-msgstr ""
+msgstr "Reaktiviere lokales Git-Verzeichnis für Unterprojekt '$sm_name'."
#: git-submodule.sh:384
#, sh-format
@@ -9659,9 +9663,9 @@ msgid "# Submodule changes to be committed:"
msgstr "# Änderungen in Unterprojekt zum Eintragen:"
#: git-submodule.sh:1080
-#, fuzzy, sh-format
+#, sh-format
msgid "Synchronizing submodule url for '$prefix$sm_path'"
-msgstr "Synchronisiere Unterprojekt-URL für '$name'"
+msgstr "Synchronisiere Unterprojekt-URL für '$prefix$sm_path'"
#~ msgid " 0 files changed"
#~ msgstr " 0 Dateien geändert"
--
1.8.0.1
^ permalink raw reply related
* Re: [RFC/PATCH] l10n: de.po: translate 825 new messages
From: Ralf Thielow @ 2012-12-04 6:19 UTC (permalink / raw)
To: Michael J Gruber; +Cc: trast, git, jk, stimming
In-Reply-To: <50BCBE58.30805@drmicha.warpmail.net>
2012/12/3 Michael J Gruber <git@drmicha.warpmail.net>:
>> 1 file changed, 61 insertions(+), 62 deletions(-)
> ...
>> #: builtin/fsck.c:620
>> msgid "also consider packs and alternate objects"
>> -msgstr "betrachtet auch Pakete und wechselnde Objekte"
>> +msgstr ""
>
> Oops ;)
>
>> #: builtin/push.c:391
>> msgid "check"
>> -msgstr "Überprüfung"
>> +msgstr ""
>
> Is this meant to omit the text? (I may have missed the pertaining
> discussion.)
>
For now, we let these two messages untranslated.
Ralf
^ permalink raw reply
* Re: [PATCH/RFC 1/5] mingw: make fgetc raise SIGINT if apropriate
From: Junio C Hamano @ 2012-12-04 0:23 UTC (permalink / raw)
To: kusmabite; +Cc: git, msysgit, peff
In-Reply-To: <CABPQNSb2NQesbjKc8LUT0TL4=xrnw2A_sJyjX72j9Je_zX1sQw@mail.gmail.com>
Erik Faye-Lund <kusmabite@gmail.com> writes:
> That patch corrected the exit-code for our SIGALRM's SIG_DFL routine;
> the old code did "die("Alarm");", but the new one does "fputs("Alarm
> clock\n", stderr); exit(128 + SIGALRM)"
>
>> Please double check the result when I push out the 'pu'
>> branch.
>
> The resolution is fine; you effectively got the two commits squashed.
> I'll send out a new version with the extra patch added, and your
> signature-fixup squashed in, OK?
Sure; thanks for a prompt response.
--
*** Please reply-to-all at all times ***
*** (do not pretend to know who is subscribed and who is not) ***
*** Please avoid top-posting. ***
The msysGit Wiki is here: https://github.com/msysgit/msysgit/wiki - Github accounts are free.
You received this message because you are subscribed to the Google
Groups "msysGit" group.
To post to this group, send email to msysgit@googlegroups.com
To unsubscribe from this group, send email to
msysgit+unsubscribe@googlegroups.com
For more options, and view previous threads, visit this group at
http://groups.google.com/group/msysgit?hl=en_US?hl=en
^ permalink raw reply
* Re: [PATCH v6 1/4] submodule: add get_submodule_config helper funtion
From: W. Trevor King @ 2012-12-04 0:17 UTC (permalink / raw)
To: Junio C Hamano, Phil Hord
Cc: Git, Heiko Voigt, Jeff King, Shawn Pearce, Jens Lehmann, Nahor
In-Reply-To: <7vehj7q6gr.fsf@alter.siamese.dyndns.org>
[-- Attachment #1: Type: text/plain, Size: 4793 bytes --]
On Mon, Dec 03, 2012 at 11:30:12AM -0800, Junio C Hamano wrote:
> > +get_submodule_config()
> > +{
>
> style (see CodingGuidelines):
>
> get_submodule_config () {
Will fix. I was generally just copying the surrounding code.
> > + name="$1"
> > + option="$2"
> > + default="$3"
> > + value=$(git config submodule."$name"."$option")
>
> This will get unwieldy quickly once we have submodule.$name.$var
> that takes a boolean option, as there are different ways to spell
> boolean and "git config --bool" is the way to ask for canonicalized
> "true" or "false".
>
> If we never query any boolean via this helper function, it is
> obviously not an issue, though.
We do in my submodule.<name>.active branch, and I adjusted the
function in
submodule: add submodule.<name>.active [1]
to add additional options passed through to `git config`. You do have
to pick a default to use the extra options though. If that becomes a
problem, I'd suggest extending git config itself to add a file above
or below the usual series of files. Then get_submodule_config could
be
git config --bottom-file .gitmodules submodule."$name"."$option"
or something, without needing a separate shell function.
On Mon, Dec 03, 2012 at 12:29:05PM -0800, Junio C Hamano wrote:
> "W. Trevor King" <wking@tremily.us> writes:
>
> > As an example to make this clearer:
> >
> > $ cat .gitmodules
> > [submodule "sub1"]
> > path = sub1
> > url = git://example.com/sub1.git
> > remote = remote1
> > branch = branch1
> > update-source = submodule-upstream
> > update = rebase
> > [submodule "sub2"]
> > ...
>
> Maybe it is just me but that "remote = remote1" sticks out like a
> sore thumb.
>
> If you are showing the .gitmodules file to be shared as hints to
> project participants, why does it even need to have both URL and
> remote1?
The remote name will probably only ever get configured locally in
.git/config. I put it in (as a separate patch) mostly because Phil
suggested something like it:
On Thu, Nov 29, 2012 at 10:27:19PM -0500, W. Trevor King wrote:
> On Thu, Nov 29, 2012 at 08:11:20PM -0500, Phil Hord wrote:
> > I've always felt that the "origin" defaults are broken and are simply
> > being ignored because most users do not trip over them. But ISTR that
> > submodule commands use the remote indicated by the superproject's
> > current remote-tracking configuration, with a fallback to 'origin' if
> > there is none. Sort of a "best effort" algorithm, I think. Am I
> > remembering that wrong?
>
> The current code uses a bare "git-fetch". I'm not sure what that
> defaults to if you're on a detached head. If it bothers you, I'm fine
> adding the submodule.<name>.remote option in v6.
and I hadn't heard any comments against it. I'm not really attached
to that patch though, so feel free to leave it out (unless Phil chimes
in with stronger motivation?).
On Mon, Dec 03, 2012 at 12:29:05PM -0800, Junio C Hamano wrote:
> But I do not see any reason to require or even suggest any local
> nickname that is to be used to call the remote. It really is a
> local matter. Why should .gitmodules have "remote = ..." line?
The idea for configuring it at all probably goes something like “I
don't like where upstream (origin) is taking this submodule. I want
to follow *my* upstream, but I've called it something besides origin.
Look, a submodule.<name>.remote option! Now I don't have to rename
my-remote→origin→original-remote.” I don't think this will come up
all that often.
> On the other hand, if you meant the above as an excerpt from
> $GIT_DIR/config, it also does not make sense. At that point, the
> participant own the file and updating url to point at whatever
> different repository without changing the remote name is sufficient.
Unless they still want to keep an the origin remote to track the
original submodule upstream. Maybe they'll want to switch back to
following that remote later. As I hinted at above, if they have
remotes `alice`, `bob`, etc., it's easier to flip between them by
configuring submodule.<name>.remote
$ git config submodule.submod.remote alice
than it is to reconfigure the submodule's origin:
$ cd submod
$ git remote rename origin charlie
$ git remote rename alice origin
> It looks way over-engineered for unclear/dubious benefit.
I'm not going to push for submodule.<name>.remote. Drop at will.
Cheers,
Trevor
[1]: https://github.com/wking/git/commit/fbe2d8419902700a6b0b40defaa5801811b887f7#L0R288
--
This email may be signed or encrypted with GnuPG (http://www.gnupg.org).
For more information, see http://en.wikipedia.org/wiki/Pretty_Good_Privacy
[-- Attachment #2: OpenPGP digital signature --]
[-- Type: application/pgp-signature, Size: 836 bytes --]
^ permalink raw reply
* Re: [PATCH/RFC 1/5] mingw: make fgetc raise SIGINT if apropriate
From: Erik Faye-Lund @ 2012-12-03 23:29 UTC (permalink / raw)
To: Junio C Hamano; +Cc: git, msysgit, peff
In-Reply-To: <7vfw3oka68.fsf@alter.siamese.dyndns.org>
On Sun, Dec 2, 2012 at 11:42 AM, Junio C Hamano <gitster@pobox.com> wrote:
> Erik Faye-Lund <kusmabite@gmail.com> writes:
>
>> @@ -1538,13 +1563,7 @@ static sig_handler_t timer_fn = SIG_DFL;
>> static unsigned __stdcall ticktack(void *dummy)
>> {
>> while (WaitForSingleObject(timer_event, timer_interval) == WAIT_TIMEOUT) {
>> - if (timer_fn == SIG_DFL) {
>> - if (isatty(STDERR_FILENO))
>> - fputs("Alarm clock\n", stderr);
>> - exit(128 + SIGALRM);
>> - }
>> - if (timer_fn != SIG_IGN)
>> - timer_fn(SIGALRM);
>> + mingw_raise(SIGALRM);
>> if (one_shot)
>> break;
>> }
>
> This hunk seems to have been based on a slightly newer codebase than
> what I have, and I had to wiggle the patch a bit to make the series
> apply.
Huh, no, it shouldn't be; it's based on 8c7a786 ("Git 1.8.0").
OH! I see now what the problem is... I *missed* a patch in the series! :P
That patch corrected the exit-code for our SIGALRM's SIG_DFL routine;
the old code did "die("Alarm");", but the new one does "fputs("Alarm
clock\n", stderr); exit(128 + SIGALRM)"
> Please double check the result when I push out the 'pu'
> branch.
The resolution is fine; you effectively got the two commits squashed.
I'll send out a new version with the extra patch added, and your
signature-fixup squashed in, OK?
^ permalink raw reply
* Re: [PATCH v7 p1 07/13] remote-testgit: remove irrelevant test
From: Pete Wyckoff @ 2012-12-03 23:13 UTC (permalink / raw)
To: Felipe Contreras; +Cc: git, Junio C Hamano, Jeff King
In-Reply-To: <1354140669-23533-8-git-send-email-felipe.contreras@gmail.com>
felipe.contreras@gmail.com wrote on Wed, 28 Nov 2012 23:11 +0100:
> This was only to cover a bug that was fixed in remote-testpy not to
> resurface.
>
> Signed-off-by: Felipe Contreras <felipe.contreras@gmail.com>
> Signed-off-by: Junio C Hamano <gitster@pobox.com>
> ---
> t/t5801-remote-helpers.sh | 13 -------------
> 1 file changed, 13 deletions(-)
>
> diff --git a/t/t5801-remote-helpers.sh b/t/t5801-remote-helpers.sh
> index 2f7fc10..6801529 100755
> --- a/t/t5801-remote-helpers.sh
> +++ b/t/t5801-remote-helpers.sh
> @@ -53,19 +53,6 @@ test_expect_success 'pushing to local repo' '
> compare_refs localclone HEAD server HEAD
> '
>
> -# Generally, skip this test. It demonstrates a now-fixed race in
> -# git-remote-testgit, but is too slow to leave in for general use.
> -: test_expect_success 'racily pushing to local repo' '
> - test_when_finished "rm -rf server2 localclone2" &&
> - cp -R server server2 &&
> - git clone "testgit::${PWD}/server2" localclone2 &&
> - (cd localclone2 &&
> - echo content >>file &&
> - git commit -a -m three &&
> - GIT_REMOTE_TESTGIT_SLEEPY=2 git push) &&
> - compare_refs localclone2 HEAD server2 HEAD
> -'
> -
Why does this cause problems?
If you're going to rip it out, please finish the job, and take
out the other two hunks that are needed to trigger this test. See
7fb8e16 (git-remote-testgit: fix race when spawning fast-import,
2012-04-22).
-- Pete
^ permalink raw reply
* Re: Python extension commands in git - request for policy change
From: Philippe Vaucher @ 2012-12-03 21:45 UTC (permalink / raw)
To: Felipe Contreras
Cc: esr, Magnus Bäck, Michael Haggerty, git@vger.kernel.org
In-Reply-To: <CAMP44s27gdDJGNx-UTe1rdQZFpn3M60L=nMyd69gAFo15VnMAA@mail.gmail.com>
> Also, you are ignoring all the advantages that shell has and python does not.
Out of curiosity, can you list the advantages? From what I gathered:
- no need to install bash
- git contributors are more used to bash
- there's only one "version" of bash (no real need to handle different
versions compared to py26, py27, etc)
Are there any "language" advantage or are all the advantages in the
"pragmatic" section?
I don't really have an opinion on this topic. A "real language" seems
better, but bash's pragmaticity seems to outweight the cons,
especially the "contributors want bash" argument.
Thanks,
Philippe
^ permalink raw reply
* Re: [PATCH] gitk: read and write a repository specific configuration file
From: Stefan Haller @ 2012-12-03 21:15 UTC (permalink / raw)
To: Lukasz Stelmach, git; +Cc: paulus, gitster
In-Reply-To: <1354483766-13925-1-git-send-email-stlman@poczta.fm>
Lukasz Stelmach <stlman@poczta.fm> wrote:
> Enable gitk read and write repository specific configuration
> file: ".git/k" if the file exists. To make gitk use the local
> file simply create one, e.g. with the touch(1) command.
I'm not sure I like this proposal. While it may be desirable to have
*some* settings stored per repository, for most settings I want them to
be remembered globally.
Git-gui tries to solve this by presenting two panes in the preferences
dialog, so that I can choose the scope of every setting I change. This
still doesn't help for things that are remembered implicitly, like the
window size.
I don't have good suggestions how to solve this; just pointing out
problems.
--
Stefan Haller
Berlin, Germany
http://www.haller-berlin.de/
^ permalink raw reply
* [ANNOUNCE] Git v1.8.1-rc0
From: Junio C Hamano @ 2012-12-03 21:09 UTC (permalink / raw)
To: git; +Cc: Linux Kernel
A release candidate preview, Git v1.8.1-rc0, is now available for
testing at the usual places.
This cycle has been a bit slow (perhaps because it had a major US
holiday to slow people down) but we seem to have managed to apply
reasonably large number of usability improvement changes, with a
handful of new features. There are several new and large-ish topics
that are cooking in 'next', but I think we would better keep them
cooking there without merging them to 'master' before the upcoming
release to happen before the year end. So as far as features goes,
this preview release is pretty much *it*.
The release tarballs are found at:
http://code.google.com/p/git-core/downloads/list
and their SHA-1 checksums are:
39faaa15bc71f8eb52048e77ea564cecf78c7adf git-1.8.1.rc0.tar.gz
2eeba24488337de02b58dc442258d58b79e2b8f4 git-htmldocs-1.8.1.rc0.tar.gz
b28d1f8e8b9268b712b33fbdfb67dd6f14afb499 git-manpages-1.8.1.rc0.tar.gz
Also the following public repositories all have a copy of the v1.8.1-rc0
tag and the master branch that the tag points at:
url = git://repo.or.cz/alt-git.git
url = https://code.google.com/p/git-core/
url = git://git.sourceforge.jp/gitroot/git-core/git.git
url = git://git-core.git.sourceforge.net/gitroot/git-core/git-core
url = https://github.com/gitster/git
Git v1.8.1 Release Notes (draft)
========================
Backward compatibility notes
----------------------------
In the next major release (not *this* one), we will change the
behavior of the "git push" command.
When "git push [$there]" does not say what to push, we have used the
traditional "matching" semantics so far (all your branches were sent
to the remote as long as there already are branches of the same name
over there). We will use the "simple" semantics that pushes the
current branch to the branch with the same name, only when the current
branch is set to integrate with that remote branch. There is a user
preference configuration variable "push.default" to change this, and
"git push" will warn about the upcoming change until you set this
variable in this release.
"git branch --set-upstream" is deprecated and may be removed in a
relatively distant future. "git branch [-u|--set-upstream-to]" has
been introduced with a saner order of arguments to replace it.
Updates since v1.8.0
--------------------
UI, Workflows & Features
* Command-line completion scripts for tcsh and zsh have been added.
* A new remote-helper interface for Mercurial has been added to
contrib/remote-helpers.
* We used to have a workaround for a bug in ancient "less" that
causes it to exit without any output when the terminal is resized.
The bug has been fixed in "less" version 406 (June 2007), and the
workaround has been removed in this release.
* Some documentation pages that used to ship only in the plain text
format are now formatted in HTML as well.
* "git-prompt" scriptlet (in contrib/completion) can be told to paint
pieces of the hints in the prompt string in colors.
* A new configuration variable "diff.context" can be used to
give the default number of context lines in the patch output, to
override the hardcoded default of 3 lines.
* When "git checkout" checks out a branch, it tells the user how far
behind (or ahead) the new branch is relative to the remote tracking
branch it builds upon. The message now also advises how to sync
them up by pushing or pulling. This can be disabled with the
advice.statusHints configuration variable.
* "git config --get" used to diagnose presence of multiple
definitions of the same variable in the same configuration file as
an error, but it now applies the "last one wins" rule used by the
internal configuration logic. Strictly speaking, this may be an
API regression but it is expected that nobody will notice it in
practice.
* "git log -p -S<string>" now looks for the <string> after applying
the textconv filter (if defined); earlier it inspected the contents
of the blobs without filtering.
* "git format-patch" learned the "--notes=<ref>" option to give
notes for the commit after the three-dash lines in its output.
* "git log --grep=<pcre>" learned to honor the "grep.patterntype"
configuration set to "perl".
* "git replace -d <object>" now interprets <object> as an extended
SHA-1 (e.g. HEAD~4 is allowed), instead of only accepting full hex
object name.
* "git rm $submodule" used to punt on removing a submodule working
tree to avoid losing the repository embedded in it. Because
recent git uses a mechanism to separate the submodule repository
from the submodule working tree, "git rm" learned to detect this
case and removes the submodule working tree when it is safe to do so.
* "git send-email" used to prompt for the sender address, even when
the committer identity is well specified (e.g. via user.name and
user.email configuration variables). The command no longer gives
this prompt when not necessary.
* "git send-email" did not allow non-address garbage strings to
appear after addresses on Cc: lines in the patch files (and when
told to pick them up to find more recipients), e.g.
Cc: Stable Kernel <stable@k.org> # for v3.2 and up
The command now strips " # for v3.2 and up" part before adding the
remainder of this line to the list of recipients.
* "git submodule add" learned to add a new submodule at the same
path as the path where an unrelated submodule was bound to in an
existing revision via the "--name" option.
* "git submodule sync" learned the "--recursive" option.
* "diff.submodule" configuration variable can be used to give custom
default value to the "git diff --submodule" option.
* "git symbolic-ref" learned the "-d $symref" option to delete the
named symbolic ref, which is more intuitive way to spell it than
"update-ref -d --no-deref $symref".
Foreign Interface
* "git cvsimport" can be told to record timezones (other than GMT)
per-author via its author info file.
* The remote helper interface to interact with subversion
repositories (one of the GSoC 2012 projects) has been merged.
Performance, Internal Implementation, etc.
* Compilation on Cygwin with newer header files are supported now.
* The logic to generate the initial advertisement from "upload-pack"
(i.e. what is invoked by "git fetch" on the other side of the
connection) to list what refs are available in the repository has
been optimized.
* The logic to find set of attributes that match a given path has
been optimized.
* Use preloadindex in "git diff-index" and "git update-index", which
has a nice speedup on systems with slow stat calls (and even on
Linux).
Also contains minor documentation updates and code clean-ups.
Fixes since v1.8.0
------------------
Unless otherwise noted, all the fixes since v1.8.0 in the maintenance
track are contained in this release (see release notes to them for
details).
* The configuration parser had an unnecessary hardcoded limit on
variable names that was not checked consistently.
(merge 0971e99 bw/config-lift-variable-name-length-limit later to maint).
* The "say" function in the test scaffolding incorrectly allowed
"echo" to interpret "\a" as if it were a C-string asking for a
BEL output.
(merge 7bc0911 jc/test-say-color-avoid-echo-escape later to maint).
* "git mergetool" feeds /dev/null as a common ancestor when dealing
with an add/add conflict, but p4merge backend cannot handle
it. Work it around by passing a temporary empty file.
(merge 3facc60 da/mergetools-p4 later to maint).
* "git log -F -E --grep='<ere>'" failed to use the given <ere>
pattern as extended regular expression, and instead looked for the
string literally.
(merge 727b6fc jc/grep-pcre-loose-ends~1 later to maint).
* "git grep -e pattern <tree>" asked the attribute system to read
"<tree>:.gitattributes" file in the working tree, which was
nonsense.
(merge 55c6168 nd/grep-true-path later to maint).
* A symbolic ref refs/heads/SYM was not correctly removed with "git
branch -d SYM"; the command removed the ref pointed by SYM
instead.
(merge 13baa9f rs/branch-del-symref later to maint).
* Update "remote tracking branch" in the documentation to
"remote-tracking branch".
(merge a6d3bde mm/maint-doc-remote-tracking later to maint).
* "git pull --rebase" run while the HEAD is detached tried to find
the upstream branch of the detached HEAD (which by definition
does not exist) and emitted unnecessary error messages.
(merge e980765 ph/pull-rebase-detached later to maint).
* The refs/replace hierarchy was not mentioned in the
repository-layout docs.
(merge 11fbe18 po/maint-refs-replace-docs later to maint).
* Various rfc2047 quoting issues around a non-ASCII name on the
From: line in the output from format-patch have been corrected.
(merge 25dc8da js/format-2047 later to maint).
* Sometimes curl_multi_timeout() function suggested a wrong timeout
value when there is no file descriptor to wait on and the http
transport ended up sleeping for minutes in select(2) system call.
A workaround has been added for this.
(merge 7202b81 sz/maint-curl-multi-timeout later to maint).
* For a fetch refspec (or the result of applying wildcard on one),
we always want the RHS to map to something inside "refs/"
hierarchy, but the logic to check it was not exactly right.
(merge 5c08c1f jc/maint-fetch-tighten-refname-check later to maint).
* "git diff -G<pattern>" did not honor textconv filter when looking
for changes.
(merge b1c2f57 jk/maint-diff-grep-textconv later to maint).
* Some HTTP servers ask for auth only during the actual packing phase
(not in ls-remote phase); this is not really a recommended
configuration, but the clients used to fail to authenticate with
such servers.
(merge 2e736fd jk/maint-http-half-auth-fetch later to maint).
* "git p4" used to try expanding malformed "$keyword$" that spans
across multiple lines.
(merge 6b2bf41 pw/maint-p4-rcs-expansion-newline later to maint).
* Syntax highlighting in "gitweb" was not quite working.
(merge 048b399 rh/maint-gitweb-highlight-ext later to maint).
* RSS feed from "gitweb" had a xss hole in its title output.
(merge 0f0ecf6 jk/maint-gitweb-xss later to maint).
* "git config --path $key" segfaulted on "[section] key" (a boolean
"true" spelled without "=", not "[section] key = true").
(merge 962c38e cn/config-missing-path later to maint).
* "git checkout -b foo" while on an unborn branch did not say
"Switched to a new branch 'foo'" like other cases.
(merge afa8c07 jk/checkout-out-of-unborn later to maint).
* We failed to mention a file without any content change but whose
permission bit was modified, or (worse yet) a new file without any
content in the "git diff --stat" output.
(merge de9095955 lt/diff-stat-show-0-lines later to maint).
* When "--stat-count" hides a diffstat for binary contents, the total
number of added and removed lines at the bottom was computed
incorrectly.
(merge de9095955 lt/diff-stat-show-0-lines later to maint).
* When "--stat-count" hides a diffstat for unmerged paths, the total
number of affected files at the bottom of the "diff --stat" output
was computed incorrectly.
(merge de9095955 lt/diff-stat-show-0-lines later to maint).
* "diff --shortstat" miscounted the total number of affected files
when there were unmerged paths.
(merge de9095955 lt/diff-stat-show-0-lines later to maint).
* "update-ref -d --deref SYM" to delete a ref through a symbolic ref
that points to it did not remove it correctly.
(merge b274a71 jh/update-ref-d-through-symref later to maint).
^ permalink raw reply
* Re: [PATCH v6 2/4] submodule update: add --remote for submodule's upstream changes
From: Junio C Hamano @ 2012-12-03 20:29 UTC (permalink / raw)
To: W. Trevor King
Cc: Git, Heiko Voigt, Jeff King, Phil Hord, Shawn Pearce,
Jens Lehmann, Nahor
In-Reply-To: <20121203183802.GD14981@odin.tremily.us>
"W. Trevor King" <wking@tremily.us> writes:
> As an example to make this clearer:
>
> $ cat .gitmodules
> [submodule "sub1"]
> path = sub1
> url = git://example.com/sub1.git
> remote = remote1
> branch = branch1
> update-source = submodule-upstream
> update = rebase
> [submodule "sub2"]
> ...
Maybe it is just me but that "remote = remote1" sticks out like a
sore thumb.
If you are showing the .gitmodules file to be shared as hints to
project participants, why does it even need to have both URL and
remote1? If remote1 points at some other repository, the recipient
of this .gitmodules file would not have any clue where it is. If
remote1 points at the same repository as the URL, why should it be
there in the first place? The superproject is in no business to
force what local remote name each participant would call in their
submodule checkout, and more importantly, there is no _need_ to do
so.
We could extend that reasoning to the branch name (which is also a
local matter, at least technically), but this is a lot more
justifiable. If the upstream of the superproject is the same
organization as the upstream of the submodule project, which is
often the case when a large project is organized as a forest of
submodules bound at the top-level with a superproject, the
superproject commit on a particular superproject branch may want any
update necessary to complete the superproject made to submodules on
specific branches at the central meeting place. The superproject's
Milestone22 branch may want to bind commits that is on submodule's
Milestone22 branch.
While a participant locally *can* create M22 branch in the submodule
and set it to build upon Milestone22 branch taken from the central
repository, most people don't. They use the same branch names
between local and remote (i.e. refs/heads/*:refs/remotes/origin/* to
keep the remote-tracking branches under the same name, and the local
branch $any builds upon the corresponding remote-tracking branch
refs/remotes/origin/$any. Most importantly, the work done on local
branch $any is pushed out to refs/heads/$any at the remote of the
submodule). Because of how people use "push" to push $any branch to
the branch of the same name $any at the central meeting place, and
because the upstream wants participants to use a particular branch
name in the submodule at the central meeting place, the set-up ends
up dictating what local branch name should be used.
But I do not see any reason to require or even suggest any local
nickname that is to be used to call the remote. It really is a
local matter. Why should .gitmodules have "remote = ..." line?
On the other hand, if you meant the above as an excerpt from
$GIT_DIR/config, it also does not make sense. At that point, the
participant own the file and updating url to point at whatever
different repository without changing the remote name is sufficient.
It looks way over-engineered for unclear/dubious benefit.
^ permalink raw reply
* Re: [PATCH v2 0/4] git-svn: More docs for branch handling in
From: Junio C Hamano @ 2012-12-03 19:32 UTC (permalink / raw)
To: Sebastian Leske; +Cc: git, Michael J Gruber, Eric Wong
In-Reply-To: <cover.1354324110.git.Sebastian.Leske@sleske.name>
I've sent comments on small nits I found but overall they looked
quite well researched. Will tentatively queue on the 'pu' branch,
expecting further updates and Acks from people involved polishing
these patches.
Thanks for writing it up.
^ permalink raw reply
* Re: [PATCH v2 3/4] git-svn: Expand documentation for --follow-parent
From: Junio C Hamano @ 2012-12-03 19:30 UTC (permalink / raw)
To: Sebastian Leske; +Cc: git, Michael J Gruber, Eric Wong
In-Reply-To: <cf118fcd52a0cf7bdf7b08a5a52cd0e285bd056b.1354324110.git.Sebastian.Leske@sleske.name>
Sebastian Leske <Sebastian.Leske@sleske.name> writes:
> Describe what the option --follow-parent does, and what happens if it is
> set or unset.
>
> Signed-off-by: Sebastian Leske <sebastian.leske@sleske.name>
> ---
> Documentation/git-svn.txt | 15 ++++++++++++---
> 1 file changed, 12 insertions(+), 3 deletions(-)
>
> diff --git a/Documentation/git-svn.txt b/Documentation/git-svn.txt
> index bfa8788..6bda014 100644
> --- a/Documentation/git-svn.txt
> +++ b/Documentation/git-svn.txt
> @@ -628,10 +628,19 @@ ADVANCED OPTIONS
> Default: "svn"
>
> --follow-parent::
> + This option is only relevant if we are tracking branches (using
> + one of the repository layout options --trunk, --tags,
> + --branches, --stdlayout). For each tracked branch, try to find
> + out where its revision was copied (i.e. branched) from, and set
> + a suitable parent in the first git commit for the branch.
I also commit this sin myself often, but it is a good habit to get
into to re-read the sentence after writing "... X (i.e. Y)", "... V
(meaning W)", "... A (in other words B)". We often write these
after realizing that "... X", "... V" or "... A" is hard to
understand and attempt to paraphrase to make it easier, but while
doing so we unconsciously hesitate to remove what we originally
wrote. The results sometimes (but not always) reads better if you
do not say X, V or A and only used the rephrased version that is
meant to be easier-to-read.
In this case, I think "was copied" and "was branched" alone are
equally good but adding "(i.e. branched)" sounds redundant.
> This is especially helpful when we're tracking a directory
> - that has been moved around within the repository, or if we
> - started tracking a branch and never tracked the trunk it was
> - descended from. This feature is enabled by default, use
> + that has been moved around within the repository. If this
> + feature is disabled, the branches created by 'git svn' will all
> + be linear and not share any history, meaning that there will be
> + no information on where branches where branched off or merged.
I think the second "where" is a typo for "were" here.
> + However, following long/convoluted histories can take a long
> + time, so disabling this feature may speed up the cloning
> + process. This feature is enabled by default, use
> --no-follow-parent to disable it.
> +
> [verse]
^ permalink raw reply
* Re: [PATCH v2 2/4] Recommend use of structure options for git svn.
From: Junio C Hamano @ 2012-12-03 19:30 UTC (permalink / raw)
To: Sebastian Leske; +Cc: git, Michael J Gruber, Eric Wong
In-Reply-To: <5cb2f71bc9be3323e425205020105dcfd948fca5.1354324110.git.Sebastian.Leske@sleske.name>
Sebastian Leske <Sebastian.Leske@sleske.name> writes:
> Document that when using git svn, one should usually either use the
> directory structure options to import branches as branches, or only
> import one subdirectory. The default behaviour of cloning all branches
> and tags as subdirectories in the working copy is usually not what the
> user wants.
>
> Signed-off-by: Sebastian Leske <sebastian.leske@sleske.name>
> ---
> Documentation/git-svn.txt | 24 +++++++++++++++++++++---
> 1 file changed, 21 insertions(+), 3 deletions(-)
>
> diff --git a/Documentation/git-svn.txt b/Documentation/git-svn.txt
> index 824bf82..bfa8788 100644
> --- a/Documentation/git-svn.txt
> +++ b/Documentation/git-svn.txt
> @@ -739,7 +739,8 @@ for rewriteRoot and rewriteUUID which can be used together.
> BASIC EXAMPLES
> --------------
>
> -Tracking and contributing to the trunk of a Subversion-managed project:
> +Tracking and contributing to the trunk of a Subversion-managed project
> +(ignoring tags and branches):
>
> ------------------------------------------------------------------------
> # Clone a repo (like git clone):
> @@ -764,8 +765,10 @@ Tracking and contributing to an entire Subversion-managed project
> (complete with a trunk, tags and branches):
>
> ------------------------------------------------------------------------
> -# Clone a repo (like git clone):
> - git svn clone http://svn.example.com/project -T trunk -b branches -t tags
> +# Clone a repo with standard SVN directory layout (like git clone):
> + git svn clone http://svn.example.com/project --stdlayout
> +# Or, if the repo uses a non-standard directory layout:
> + git svn clone http://svn.example.com/project -T tr -b branch -t tag
These command line, given that the SYNPOSIS section says:
git svn <command> [options] [arguments]
look strange to have the URL argument before all the options.
Because the original shares the same trait, this should not be fixed
in this patch, but it may be a good idea to fix the order of the
arguments in a separate follow-up patch.
> @@ -871,6 +874,21 @@ already dcommitted. It is considered bad practice to --amend commits
> you've already pushed to a remote repository for other users, and
> dcommit with SVN is analogous to that.
>
> +When cloning an SVN repository, if none of the options for describing
> +the repository layout is used (--trunk, --tags, --branches,
> +--stdlayout), 'git svn clone' will create a git repository with
> +completely linear history, where branches and tags appear as separate
> +folders in the working copy. ...
As existing text in git-svn.txt consistently uses "directory" and
never "folder", please match that terminology (like you did in a
later sentence in your patch).
> ... While this is the easiest way to get a
> +copy of a complete repository, for projects with many branches it will
> +lead to a working copy many times larger than just the trunk. Thus for
> +projects using the standard directory structure (trunk/branches/tags),
> +it is recommended to clone with option '--stdlayout'. If the project
> +uses a non-standard structure, and/or if branches and tags are not
> +required, it is easiest to only clone one directory (typically trunk),
> +without giving any repository layout options. If the full history with
> +branches and tags is required, the options '--trunk' / '--branches' /
> +'--tags' must be used.
> +
> When using multiple --branches or --tags, 'git svn' does not automatically
> handle name collisions (for example, if two branches from different paths have
> the same name, or if a branch and a tag have the same name). In these cases,
^ permalink raw reply
* Re: [PATCH v6 1/4] submodule: add get_submodule_config helper funtion
From: Junio C Hamano @ 2012-12-03 19:30 UTC (permalink / raw)
To: W. Trevor King
Cc: Git, Heiko Voigt, Jeff King, Phil Hord, Shawn Pearce,
Jens Lehmann, Nahor
In-Reply-To: <436a73a8fdc8f0695aa597d53483d4c4bae16ebb.1354417618.git.wking@tremily.us>
"W. Trevor King" <wking@tremily.us> writes:
> From: "W. Trevor King" <wking@tremily.us>
>
> Several submodule configuration variables
> (e.g. fetchRecurseSubmodules) are read from .gitmodules with local
> overrides from the usual git config files. This shell function mimics
> that logic to help initialize configuration variables in
> git-submodule.sh.
>
> Signed-off-by: W. Trevor King <wking@tremily.us>
> ---
> git-submodule.sh | 27 +++++++++++++++++++++++++++
> 1 file changed, 27 insertions(+)
>
> diff --git a/git-submodule.sh b/git-submodule.sh
> index ab6b110..97ce5e4 100755
> --- a/git-submodule.sh
> +++ b/git-submodule.sh
> @@ -152,6 +152,33 @@ die_if_unmatched ()
> }
>
> #
> +# Print a submodule configuration setting
> +#
> +# $1 = submodule name
> +# $2 = option name
> +# $3 = default value
> +#
> +# Checks in the usual git-config places first (for overrides),
> +# otherwise it falls back on .gitmodules. This allows you to
> +# distribute project-wide defaults in .gitmodules, while still
> +# customizing individual repositories if necessary. If the option is
> +# not in .gitmodules either, print a default value.
> +#
> +get_submodule_config()
> +{
style (see CodingGuidelines):
get_submodule_config () {
> + name="$1"
> + option="$2"
> + default="$3"
> + value=$(git config submodule."$name"."$option")
This will get unwieldy quickly once we have submodule.$name.$var
that takes a boolean option, as there are different ways to spell
boolean and "git config --bool" is the way to ask for canonicalized
"true" or "false".
If we never query any boolean via this helper function, it is
obviously not an issue, though.
> + if test -z "$value"
> + then
> + value=$(git config -f .gitmodules submodule."$name"."$option")
> + fi
> + printf '%s' "${value:-$default}"
> +}
> +
> +
> +#
> # Map submodule path to submodule name
> #
> # $1 = path
^ permalink raw reply
* Re: [PATCH v2 1/4] git-svn: Document branches with at-sign(@).
From: Junio C Hamano @ 2012-12-03 19:28 UTC (permalink / raw)
To: Sebastian Leske; +Cc: git, Michael J Gruber, Eric Wong
In-Reply-To: <67e9db6f948315f3c733dda0ad970e6257c075af.1354324110.git.Sebastian.Leske@sleske.name>
Sebastian Leske <Sebastian.Leske@sleske.name> writes:
> git svn will sometimes create branches with an at-sign in the name
It may be just me but "git svn sometimes creates" without "will"
reads much better to me (there is the same phrasing in the patch
text as well).
> (branchname@revision). These branches confuse many users and it is a FAQ
> why they are created. Document when git svn will create them.
>
> Signed-off-by: Sebastian Leske <sebastian.leske@sleske.name>
> ---
> Documentation/git-svn.txt | 38 ++++++++++++++++++++++++++++++++++++++
> 1 file changed, 38 insertions(+)
>
> diff --git a/Documentation/git-svn.txt b/Documentation/git-svn.txt
> index 8b0d3ad..824bf82 100644
> --- a/Documentation/git-svn.txt
> +++ b/Documentation/git-svn.txt
> @@ -881,6 +881,44 @@ different name spaces. For example:
> branches = stable/*:refs/remotes/svn/stable/*
> branches = debug/*:refs/remotes/svn/debug/*
>
> +If 'git svn' is configured to fetch branches (and --follow-branches
> +is in effect), it will sometimes create multiple branches for one SVN
> +branch, where the addtional branches have names of the form
> +'branchname@nnn' (with nnn an SVN revision number). These additional
> +branches are created if 'git svn' cannot find a parent commit for the
> +first commit in an SVN branch, to connect the branch to the history of
> +the other branches. Normally, the first commit in an SVN branch consists
> +of a copy operation. 'git svn' will read this commit to get the SVN
> +revision the branch was created (copied) from. It will then try to find the
> +git commit that corresponds to this SVN revision, and use that as the
> +parent of the branch. However, it is possible that there is no suitable
> +git commit to serve as parent. This will happen, among other reasons,
> +if the SVN branch is a copy of a revision that was not fetched by 'git
> +svn' (e.g. because it is an old revision that was skipped with
> +'--revision'), or if in SVN a directory was copied that is not tracked
> +by 'git svn' (such as a branch that is not tracked at all, or a
> +subdirectory of a tracked branch). In these cases, 'git svn' will still
> +create a git branch, but instead of using an existing git commit as the
> +parent of the branch, it will read the SVN history of the directory the
> +branch was copied from and create appropriate git commits (this is
> +indicated by the message "Initializing parent: <branchname>").
> +Additionally, it will create a special branch named
> +'<branchname>@<SVN-Revision>', where <SVN-Revision> is the SVN revision
> +number the branch was copied from. This branch will point to the newly
> +created parent commit of the branch. If in SVN the branch was deleted
> +and later recreated from a different version, there will be multiple
> +such branches with an '@'.
> +Note that this may mean that multiple git commits are created for a
> +single SVN revision. An example: In an SVN repository with a standard
> +trunk/tags/branches layout, a directory trunk/sub is created in r.100.
> +In r.200, trunk/sub is branched by copying it to branches/. 'git svn
> +clone -s' will then create a branch 'sub'. It will also create new git
> +commits for r.100 through r.199 and use these as the history of branch
> +'sub'. Thus there will be two git commits for each revision from r.100
> +to r.199 (one containing trunk/, one containing trunk/sub/). Finally,
> +it will create a branch 'sub@200' pointing to the new parent commit of
> +branch 'sub' (i.e. the commit for r.200 and trunk/sub/).
> +
Have you looked at the formatted result? This is quite detailed and
long, and may deserve to be split into a few paragraphs. I'd
probably suggest a paragraph break before "Normally, the first...",
"Additionally", "Note that", and "An example:"
^ permalink raw reply
* Re: [PATCH v6 0/8] push: update remote tags only with force
From: Junio C Hamano @ 2012-12-03 18:53 UTC (permalink / raw)
To: Chris Rorvick
Cc: git, Angelo Borsotti, Drew Northup, Michael Haggerty,
Philip Oakley, Johannes Sixt, Kacper Kornet, Jeff King,
Felipe Contreras
In-Reply-To: <1354239700-3325-1-git-send-email-chris@rorvick.com>
Thanks; will queue.
^ permalink raw reply
* Re: [PATCH v6 2/4] submodule update: add --remote for submodule's upstream changes
From: W. Trevor King @ 2012-12-03 18:38 UTC (permalink / raw)
To: Junio C Hamano
Cc: Git, Heiko Voigt, Jeff King, Phil Hord, Shawn Pearce,
Jens Lehmann, Nahor
In-Reply-To: <20121203181519.GC14981@odin.tremily.us>
[-- Attachment #1: Type: text/plain, Size: 1209 bytes --]
As an example to make this clearer:
$ cat .gitmodules
[submodule "sub1"]
path = sub1
url = git://example.com/sub1.git
remote = remote1
branch = branch1
update-source = submodule-upstream
update = rebase
[submodule "sub2"]
...
Means that `git submodule update sub1` will fetch remote1 and rebase
the current sub1 checkout against the tip of remote1/branch1. The
git://example.com/sub1.git URL is not actually used during this
update. Presumably the user setup remote1 intentionally in the
submodule, and wants to use the URL they've configured there.
Perhaps I need to ammend my
submodule update: add submodule.<name>.remote config option
patch (#4) to adjust the remote that has it's URL changed by `sync`?
I may also want to append some form of the following commit (from my
submodule.<name>.active proposal):
submodule add: configure existing submodule url if not set [1]
Cheers,
Trevor
[1]: https://github.com/wking/git/commit/b045c16cffe6eb86c157a6c7397166a46e147442
--
This email may be signed or encrypted with GnuPG (http://www.gnupg.org).
For more information, see http://en.wikipedia.org/wiki/Pretty_Good_Privacy
[-- Attachment #2: OpenPGP digital signature --]
[-- Type: application/pgp-signature, Size: 836 bytes --]
^ permalink raw reply
page: next (older) | prev (newer) | latest
- recent:[subjects (threaded)|topics (new)|topics (active)]
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox