Codebase list rust-stfu8 / e90fc455-bec3-446e-ae9d-315313ec46c7/main dev / list-remaining-deps.sh
e90fc455-bec3-446e-ae9d-315313ec46c7/main

Tree @e90fc455-bec3-446e-ae9d-315313ec46c7/main (Download .tar.gz)

list-remaining-deps.sh @e90fc455-bec3-446e-ae9d-315313ec46c7/main

2e78543
 
b0d909c
 
2e78543
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
e8aca34
2e78543
#!/bin/sh

abort() { local x=$1; shift; for i in "$@"; do echo >&2 "$0: abort: $i"; done; exit "$x"; }

echo >&2 "Note, this script is not very accurate and may print out redundant stuff,"
echo >&2 "e.g. dependencies of crates that we already patched away in Debian."

if [ -n "$DEBCARGO" ]; then
	true
elif which debcargo >/dev/null; then
	DEBCARGO=$(which debcargo)
elif [ -f "$HOME/.cargo/bin/debcargo" ]; then
	DEBCARGO="$HOME/.cargo/bin/debcargo"
else
	abort 1 "debcargo not found, run \`cargo install debcargo\` or set DEBCARGO to point to it"
fi

if [ -d ../debcargo ]; then
	DEBCARGO_SRC=../debcargo
else
	abort 1 "debcargo.git not found, set DEBCARGO_SRC and try again"
fi

export DEBCARGO
for c in "$@"; do \
  "$DEBCARGO_SRC"/tests/sh/cargo-tree-deb-rec "$c"; done \
| sed -e 's/ v/ /g' \
| dev/filter-semver.sh \
| awk '!x[$0]++' \
| dev/filter-crate-in-debian.sh \
| sed -nre 's/(.*) 0$/\1/gp'