Skip to content

Commit 9ad946e

Browse files
committed
Merge pull request moby#21098 from kencochrane/fix_vendoring_script_macosx
Fix the vendoring script on MacOS X
2 parents edf3c0f + 94445b2 commit 9ad946e

File tree

1 file changed

+5
-1
lines changed

1 file changed

+5
-1
lines changed

hack/.vendor-helpers.sh

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -141,6 +141,10 @@ clean() {
141141
echo -n 'pruning unused files, '
142142
$find vendor -type f -name '*_test.go' -exec rm -v '{}' ';'
143143

144+
# These are the files that are left over after fix_rewritten_imports is run.
145+
echo -n 'pruning .orig files, '
146+
$find vendor -type f -name '*.orig' -exec rm -v '{}' ';'
147+
144148
echo done
145149
}
146150

@@ -151,5 +155,5 @@ fix_rewritten_imports () {
151155
local target="vendor/src/$pkg"
152156

153157
echo "$pkg: fixing rewritten imports"
154-
$find "$target" -name \*.go -exec sed -i -e "s|\"${remove}|\"|g" {} \;
158+
$find "$target" -name \*.go -exec sed -i'.orig' -e "s|\"${remove}|\"|g" {} \;
155159
}

0 commit comments

Comments
 (0)