From: Mark Lodato <lodatom@gmail.com>
To: git list <git@vger.kernel.org>
Subject: [BUG] bugs in clean, status, bisect, and send-email
Date: Wed, 24 Feb 2010 22:28:41 -0500 [thread overview]
Message-ID: <ca433831002241928hef29dadu39f93bc1a8460331@mail.gmail.com> (raw)
I noticed the following four bugs but don't have time to investigate
further, let alone make test cases or fix them. If someone else wants
to tackle these, great. If not, I'll try to research them more when I
get free time, which won't be for a while.
All of the following have been tested with git 1.7.0, and the first
three examples use a new, empty repository.
$ mkdir test_dir
$ cd test_dir
$ git init
1. git-clean removes directories when a glob partially matches
If the pathspec given to 'git clean' has the potential to match a file
in a subdirectory (even if no matching file exists in that directory),
the entire directory is removed. In the following example, none of
the commands should try to remove dir/.
$ mkdir dir
$ touch dir/file
$ git clean -nd 'x*'
$ git clean -nd '*.c'
Would remove dir/
$ git clean -nd 'd*j'
Would remove dir/
2. git-status globs only match untracked files, not staged or unmodified
The last command should show that b.c is staged and modified, but
instead it shows absolutely nothing. If this is intended behavior,
it's certainly not what I would expect.
$ touch a.txt b.c
$ git status
# On branch master
#
# Initial commit
#
# Untracked files:
# (use "git add <file>..." to include in what will be committed)
#
# a.txt
# b.c
nothing added to commit but untracked files present (use "git add" to track)
$ git status -- '*.c'
# On branch master
#
# Initial commit
#
# Untracked files:
# (use "git add <file>..." to include in what will be committed)
#
# b.c
nothing added to commit but untracked files present (use "git add" to track)
$ git add b.c
$ echo foo >> b.c
$ git status
# On branch master
#
# Initial commit
#
# Changes to be committed:
# (use "git rm --cached <file>..." to unstage)
#
# new file: b.c
#
# Changed but not updated:
# (use "git add <file>..." to update what will be committed)
# (use "git checkout -- <file>..." to discard changes in working directory)
#
# modified: b.c
#
# Untracked files:
# (use "git add <file>..." to include in what will be committed)
#
# a.txt
$ git status -- '*.c'
# On branch master
#
# Initial commit
#
nothing to commit (create/copy files and use "git add" to track)
3. git-send-email does not accept -h option
All other git sub-commands accept -h, so it would probably be a good
idea to implement it for 'git send-email' as well.
$ git send-email -h
usage: git format-patch [options] [<since> | <revision range>]
-n, --numbered use [PATCH n/m] even with a single patch
-N, --no-numbered use [PATCH] even with multiple patches
-s, --signoff add Signed-off-by:
--stdout print patches to standard out
--cover-letter generate a cover letter
--numbered-files use simple number sequence for output file names
--suffix <sfx> use <sfx> instead of '.patch'
--start-number <n> start numbering patches at <n> instead of 1
--subject-prefix <prefix>
Use [<prefix>] instead of [PATCH]
-o, --output-directory <dir>
store resulting files in <dir>
-k, --keep-subject don't strip/add [PATCH]
--no-binary don't output binary diffs
--ignore-if-in-upstream
don't include a patch matching a commit upstream
-p, --no-stat show patch format instead of default (patch + stat)
Messaging
--add-header <header>
add email header
--cc <email> add Cc: header
--in-reply-to <message-id>
make first mail a reply to <message-id>
--attach[=<boundary>]
attach the patch
--inline[=<boundary>]
inline the patch
--thread[=<style>] enable message threading, styles: shallow, deep
format-patch -o /tmp/ipOBB8AaCU -h: command returned error: 129
4. git-bisect fails if a pathspec is given that matches no commits
It says there are -1 revisions left. I have no idea what it does
after that. The following example uses git.git.
$ git bisect start v1.7.0 v1.6.6 -- 'foobar'
Bisecting: -1 revisions left to test after this (roughly 0 steps)
[f2a37151d4624906e34a9bcafb2ad79d0e8cb7ec] Fix memory leak in helper
method for disconnect
next reply other threads:[~2010-02-25 3:29 UTC|newest]
Thread overview: 3+ messages / expand[flat|nested] mbox.gz Atom feed top
2010-02-25 3:28 Mark Lodato [this message]
2010-02-25 4:09 ` [BUG] bugs in clean, status, bisect, and send-email Junio C Hamano
2010-02-25 7:07 ` Christian Couder
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=ca433831002241928hef29dadu39f93bc1a8460331@mail.gmail.com \
--to=lodatom@gmail.com \
--cc=git@vger.kernel.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).