Skip to content

Commit

Permalink
make-git-snapshot: Use generated cargo vendor config
Browse files Browse the repository at this point in the history
Nowadays it prints the result to stdout, so we can just use that
directly.

In particular, this fixes an issue for me where trying to use
direct `git` dependencies (not via crates.io) needs a separate
config stanza.
  • Loading branch information
cgwalters committed Oct 20, 2021
1 parent 622dbbd commit 26618db
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 11 deletions.
8 changes: 0 additions & 8 deletions cargo-vendor-config

This file was deleted.

6 changes: 3 additions & 3 deletions packaging/make-git-snapshot.sh
Original file line number Diff line number Diff line change
Expand Up @@ -27,7 +27,8 @@ ls -al ${TARFILE_TMP}
tar -A -f ${TARFILE_TMP} submodule.tar
rm submodule.tar
done
tmpd=${TOP}/.dist-tmp
disttmp=.dist-tmp
tmpd=${TOP}/$disttmp
trap cleanup EXIT
function cleanup () {
if test -f ${tmpd}/.tmp; then
Expand All @@ -40,9 +41,8 @@ mkdir ${tmpd} && touch ${tmpd}/.tmp

(cd ${tmpd}
mkdir -p .cargo vendor
(cd ${TOP} && cargo vendor ${tmpd}/vendor)
(cd ${TOP} && cargo vendor ${tmpd}/vendor | sed -e "s,^directory *=.*,directory = './vendor',") > .cargo/config
cp ${TOP}/Cargo.lock .
cp ${TOP}/cargo-vendor-config .cargo/config
# Filter out bundled libcurl and systemd; we always want the pkgconfig ones
for crate_subdir in curl-sys/curl \
libz-sys/src/zlib \
Expand Down

0 comments on commit 26618db

Please sign in to comment.