Skip to content

Commit 45cedef

Browse files
author
Solomon Hykes
committed
hack/vendor.sh: overwrite existing dependencies and remove .git so they can be checked in
1 parent ebee8f2 commit 45cedef

File tree

2 files changed

+7
-4
lines changed

2 files changed

+7
-4
lines changed

.gitignore

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -14,5 +14,6 @@ docs/_templates
1414
.gopath/
1515
.dotcloud
1616
*.test
17-
vendor/
1817
bundles/
18+
.hg/
19+
.git/

hack/vendor.sh

Lines changed: 5 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -12,10 +12,12 @@ git_clone () {
1212
(
1313
set -e
1414
cd $vendor_dir
15-
if [[ ! -d src/$PKG ]]; then
16-
cd $vendor_dir && git clone http://$PKG src/$PKG
15+
if [[ -d src/$PKG ]]; then
16+
echo "src/$PKG already exists. Removing."
17+
rm -fr src/$PKG
1718
fi
18-
cd src/$PKG && git checkout -f $REV
19+
cd $vendor_dir && git clone http://$PKG src/$PKG
20+
cd src/$PKG && git checkout -f $REV && rm -fr .git
1921
)
2022
}
2123

0 commit comments

Comments
 (0)