From: Bill Lear <rael@zopyra.com>
To: git@vger.kernel.org
Subject: Question on git-filter-branch
Date: Tue, 16 Oct 2007 19:57:23 -0500 [thread overview]
Message-ID: <18197.24051.863751.436705@lisa.zopyra.com> (raw)
I'm testing out git-filter-branch, as I would like to use it to remove
proprietary information from our repository.
I created a test repo with "sensitive information" in a file 'A', some
other "plain" information, more sensitive stuff in file 'D', a subdirectory
of sensitive information (some of this added on a branch 'branch_1',
some added on master):
% ls -F sensitive
A B C D sensitive_stuff/
I then cloned this repo and tried the filter:
% git clone sensitive sensitive.clone
% cd sensitive.clone
% git filter-branch --index-filter 'git update-index --remove A' HEAD
Rewrite 5dd7d5f2d7d3a5f43c242188ac96294628267673 (7/7)
Ref 'refs/heads/master' was rewritten
These refs were rewritten:
% ls
A B C D sensitive_stuff
Ok, so it doesn't list the refs, so I do git status:
% git status
# On branch master
# Changes to be committed:
# (use "git reset HEAD <file>..." to unstage)
#
# new file: A
#
So, it seems to have done something to A, but I don't know what to do
next.
The man page says: "Now, you will get the rewritten history saved in
the branch newbranch (your current branch is left untouched)." Well,
I don't see any new branch created:
% git branch -a
* master
origin/HEAD
origin/branch_1
origin/master
Then next part of the man page counsels that "To set a commit ...",
but I'm not sure if that is what I want to do (I think it is).
However, I'm not sure what the 'graft-id' refers to, or if I'm
supposed to type in the command as specified, especially since this is
followed by this caution: "if the parent string is empty - which
happens when we are dealing with the initial commit - add graftcommit
as a parent". Here, I'm unsure what graftcommit is, most especially
since the use of 'graft' first appears as 'graft-id'...
Could someone help, please?
Bill
next reply other threads:[~2007-10-17 0:57 UTC|newest]
Thread overview: 11+ messages / expand[flat|nested] mbox.gz Atom feed top
2007-10-17 0:57 Bill Lear [this message]
2007-10-17 2:22 ` [PATCH 1/2] fix filter-branch documentation Johannes Schindelin
2007-10-17 2:23 ` [PATCH 2/2] filter-branch: update current branch when rewritten Johannes Schindelin
2007-10-18 12:43 ` Bill Lear
2007-10-19 0:06 ` Shawn O. Pearce
-- strict thread matches above, loose matches on Subject: below --
2007-11-01 12:55 Question on git-filter-branch Bill Lear
2007-11-01 12:58 ` Mike Hommey
2007-11-01 13:19 ` Bill Lear
2007-11-01 13:34 ` Mike Hommey
2007-11-01 13:54 ` Bill Lear
2007-11-01 14:20 ` Alex Riesen
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
List information: http://vger.kernel.org/majordomo-info.html
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=18197.24051.863751.436705@lisa.zopyra.com \
--to=rael@zopyra.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.
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).