#583682 filter-branch: advertise --prefix example better

Package:
git-man
Source:
git
Submitter:
Frédéric Brière
Date:
2015-11-16 08:12:04 UTC
Severity:
wishlist
#583682#5
Date:
2010-05-29 14:59:02 UTC
From:
To:
A few months ago, I needed to rewrite a repo by moving it to a
subdirectory; I ended up (crudely) patching git-filter-branch to add a
--prefix option, doing the opposite of --subdirectory-filter.  I think
this could be useful to other people as well.

I'm attaging the diff for archeological purposes, in case this could be
of help to someone.  It's not a suitable patch, as I lazily removed
git-read-tree's "-m" option (which is incompatible with --prefix)
instead of properly adding yet another if() level.  It was a one-time
job, so I didn't strive for correctness.  :)

#583682#10
Date:
2010-05-29 15:27:34 UTC
From:
To:
tags 583682 + upstream
quit

Hi,

Frédéric Brière wrote:

How does this compare to the example from the man page?

	git filter-branch --index-filter \
		'git ls-files -s | sed "s-\t\"*-&newsubdir/-" |
			GIT_INDEX_FILE=$GIT_INDEX_FILE.new \
				git update-index --index-info &&
		 mv $GIT_INDEX_FILE.new $GIT_INDEX_FILE' HEAD

Thanks :)
Jonathan

#583682#17
Date:
2010-05-29 15:33:16 UTC
From:
To:
Damn.  :)
#583682#22
Date:
2010-05-29 16:36:47 UTC
From:
To:
Frédéric Brière wrote:

Hmm, in that case, how about something like this patch?

diff --git a/Documentation/git-filter-branch.txt b/Documentation/git-filter-branch.txt
index 020028c..1c0194a 100644
--- a/Documentation/git-filter-branch.txt
+++ b/Documentation/git-filter-branch.txt
@@ -158,10 +158,13 @@ to other tags will be rewritten to point to the underlying commit.

#583682#27
Date:
2010-05-29 16:42:27 UTC
From:
To:
Makes sense.
#583682#42
Date:
2015-11-16 08:04:50 UTC
From:
To:
Hello Sir&Madam,
Wishing you a wonderful day.

Do you need wholesale usb flash drives?Our company have been working on the fields of wholesale usb flash drives for 10 years.
www.pzxtech.com


For promote our growth of trade. it has 1 models promotional usb flash drive for special below:
Items:Card shape promotional usb flash drive
Capacity: 1GB/2GB/4GB/8GB/16GB
Unit price: US$1.73/1.81/2.07/2.28/3.81



We have some special Usb flash drive which we developed them by ourselves.
If you required , we could send you E-catalogue and free samples

Kindly reply at your earliest convenience.
Best regards
James
ShenZhen  PengZe Xing Technology  Co.,Ltd


Add:A18C, LongXing   Building,Bulong  Road, longGang,ShenZhen,China


Tel:+86-755-28760211


Email:Sales@pzxtech.com and James@pzxtech.com


Website:www.pzxtech.com




If you no longer wish to receive our emails, you may unsubscribe here by email.Please consider the environment before printing this e-mail.