34 lines
831 B
Bash
Executable File
34 lines
831 B
Bash
Executable File
#!/bin/bash
|
|
|
|
echo "Removing non-existent dependencies..."
|
|
|
|
# List of deps that don't exist or have wrong versions
|
|
REMOVE_DEPS=(
|
|
"gcp-sdk"
|
|
"azure-sdk"
|
|
"alibaba-cloud-sdk"
|
|
"torchvision-bindgen"
|
|
"torchaudio-bindgen"
|
|
"torchtext-bindgen"
|
|
"medical-imaging-toolkit"
|
|
"approx-float"
|
|
"byzantine-generals"
|
|
"custom-stream-cache"
|
|
)
|
|
|
|
for dep in "${REMOVE_DEPS[@]}"; do
|
|
echo "Removing: $dep"
|
|
find crates -name "Cargo.toml" -exec sed -i "/$dep/d" {} \;
|
|
done
|
|
|
|
# Fix features that depend on removed deps
|
|
find crates -name "Cargo.toml" -exec sed -i \
|
|
-e 's/, "dep:gcp-sdk"//g' \
|
|
-e 's/"dep:gcp-sdk", //g' \
|
|
-e 's/, "dep:azure-sdk"//g' \
|
|
-e 's/"dep:azure-sdk", //g' \
|
|
-e 's/, "dep:alibaba-cloud-sdk"//g' \
|
|
-e 's/"dep:alibaba-cloud-sdk", //g' \
|
|
{} \;
|
|
|
|
echo "Cleanup complete!" |