* Warning during 'git stash push'
@ 2021-04-10 4:58 Yuri
2021-04-10 6:50 ` Junio C Hamano
0 siblings, 1 reply; 2+ messages in thread
From: Yuri @ 2021-04-10 4:58 UTC (permalink / raw)
To: Git Mailing List
What did you do before the bug happened? (Steps to reproduce your issue)
Tried to stash a particular subdirectory
What did you expect to happen? (Expected behavior)
Directory should be stashed, obviously,
What happened instead? (Actual behavior)
git stash push -- x11-toolkits/fltk
Saved working directory and index state WIP on main: 4c2cc95952a6
graphics/mesa-devel: update to 21.0.b.4390
<stdin>:83: space before tab in indent.
LIBS="$LIBS -lX11 $X_EXTRA_LIBS"
<stdin>:84: space before tab in indent.
CFLAGS="$CFLAGS $X_CFLAGS"
<stdin>:85: space before tab in indent.
CXXFLAGS="$CXXFLAGS $X_CFLAGS"
<stdin>:88: space before tab in indent.
DSOFLAGS="$X_LIBS $DSOFLAGS"
<stdin>:89: space before tab in indent.
$as_echo "#define USE_X11 1" >>confdefs.h
warning: squelched 40 whitespace errors
warning: 45 lines add whitespace errors.
What's different between what you expected and what actually happened?
unexpected warnings
Anything else you want to add:
I did this from w/in of the FreeBSD ports directory, trying to stash
only my work in one of subdirectories: x11-toolkits/fltk
Please review the rest of the bug report below.
You can delete any lines you don't wish to share.
[System Info]
git version:
git version 2.31.0
cpu: amd64
no commit associated with this build
sizeof-long: 8
sizeof-size_t: 8
shell-path: /bin/sh
uname: FreeBSD 12.2-STABLE FreeBSD 12.2-STABLE #0 r369528M: Mon Mar 29
05:18:24 PDT 2021
unknown@nohost.com:/disk-samsung/sys/usr/src/amd64.amd64/sys/GENERIC amd64
compiler info: clang: 10.0.1 (git@github.com:llvm/llvm-project.git
llvmorg-10.0.1-0-gef32c611aa2)
libc info: no libc information available
$SHELL (typically, interactive shell): /usr/local/bin/bash
[Enabled Hooks]
^ permalink raw reply [flat|nested] 2+ messages in thread
* Re: Warning during 'git stash push'
2021-04-10 4:58 Warning during 'git stash push' Yuri
@ 2021-04-10 6:50 ` Junio C Hamano
0 siblings, 0 replies; 2+ messages in thread
From: Junio C Hamano @ 2021-04-10 6:50 UTC (permalink / raw)
To: Yuri; +Cc: Git Mailing List
Yuri <yuri@rawbw.com> writes:
> What did you do before the bug happened? (Steps to reproduce your issue)
> Tried to stash a particular subdirectory
>
> What did you expect to happen? (Expected behavior)
> Directory should be stashed, obviously,
>
> What happened instead? (Actual behavior)
> git stash push -- x11-toolkits/fltk
> Saved working directory and index state WIP on main: 4c2cc95952a6
> graphics/mesa-devel: update to 21.0.b.4390
> <stdin>:83: space before tab in indent.
> LIBS="$LIBS -lX11 $X_EXTRA_LIBS"
> <stdin>:84: space before tab in indent.
> CFLAGS="$CFLAGS $X_CFLAGS"
> <stdin>:85: space before tab in indent.
> CXXFLAGS="$CXXFLAGS $X_CFLAGS"
> <stdin>:88: space before tab in indent.
> DSOFLAGS="$X_LIBS $DSOFLAGS"
> <stdin>:89: space before tab in indent.
> $as_echo "#define USE_X11 1" >>confdefs.h
> warning: squelched 40 whitespace errors
> warning: 45 lines add whitespace errors.
Thanks for a report.
I wonder if this is one of those regressions introduced during the
rewrite.
Not even compile tested, but I think the following patch may be a
good starting point to help somebody who wants to fix it (it is too
late at night for me ;-).
builtin/stash.c | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
diff --git c/builtin/stash.c w/builtin/stash.c
index d68ed784d2..c65685de29 100644
--- c/builtin/stash.c
+++ w/builtin/stash.c
@@ -1510,7 +1510,7 @@ static int do_push_stash(const struct pathspec *ps, const char *stash_msg, int q
cp_apply.git_cmd = 1;
strvec_pushl(&cp_apply.args, "apply", "--index",
- "-R", NULL);
+ "-R", "--whitespace=nowarn", NULL);
if (pipe_command(&cp_apply, out.buf, out.len, NULL, 0,
NULL, 0)) {
ret = -1;
@@ -1547,7 +1547,7 @@ static int do_push_stash(const struct pathspec *ps, const char *stash_msg, int q
struct child_process cp = CHILD_PROCESS_INIT;
cp.git_cmd = 1;
- strvec_pushl(&cp.args, "apply", "-R", NULL);
+ strvec_pushl(&cp.args, "apply", "-R", "--whitespace=nowarn", NULL);
if (pipe_command(&cp, patch.buf, patch.len, NULL, 0, NULL, 0)) {
if (!quiet)
^ permalink raw reply related [flat|nested] 2+ messages in thread
end of thread, other threads:[~2021-04-10 6:51 UTC | newest]
Thread overview: 2+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2021-04-10 4:58 Warning during 'git stash push' Yuri
2021-04-10 6:50 ` Junio C Hamano
Code repositories for project(s) associated with this public inbox
https://80x24.org/mirrors/git.git
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).