remove debugging output
This commit is contained in:
@@ -36,8 +36,6 @@ for index in "${sources[@]}"; do
|
|||||||
|
|
||||||
remote_sources+=("$index")
|
remote_sources+=("$index")
|
||||||
|
|
||||||
echo "fetching index: $index" >&2
|
|
||||||
|
|
||||||
index_response=$(
|
index_response=$(
|
||||||
if [[ "$index" =~ .*dev\.azure\.com.* ]] && [ -n "$NUGET_PAT" ]; then
|
if [[ "$index" =~ .*dev\.azure\.com.* ]] && [ -n "$NUGET_PAT" ]; then
|
||||||
curl --anyauth -u "user:$NUGET_PAT" --netrc-optional --compressed -fsSL "$index"
|
curl --anyauth -u "user:$NUGET_PAT" --netrc-optional --compressed -fsSL "$index"
|
||||||
@@ -63,7 +61,6 @@ done
|
|||||||
[[ -d "$package" ]] || continue
|
[[ -d "$package" ]] || continue
|
||||||
cd "$package"
|
cd "$package"
|
||||||
for version in *; do
|
for version in *; do
|
||||||
echo "fetching package: $package $version" >&2
|
|
||||||
|
|
||||||
id=$(xmlstarlet sel -t -v /_:package/_:metadata/_:id "$version"/*.nuspec)
|
id=$(xmlstarlet sel -t -v /_:package/_:metadata/_:id "$version"/*.nuspec)
|
||||||
|
|
||||||
@@ -74,7 +71,6 @@ done
|
|||||||
# packages in the nix store should have an empty metadata file
|
# packages in the nix store should have an empty metadata file
|
||||||
# packages installed with 'dotnet tool' may be missing 'source'
|
# packages installed with 'dotnet tool' may be missing 'source'
|
||||||
used_source="$(jq -r 'if has("source") then .source elif has("contentHash") then "__unknown" else "" end' "$version"/.nupkg.metadata)"
|
used_source="$(jq -r 'if has("source") then .source elif has("contentHash") then "__unknown" else "" end' "$version"/.nupkg.metadata)"
|
||||||
echo "used source: $used_source" >&2
|
|
||||||
|
|
||||||
found=false
|
found=false
|
||||||
|
|
||||||
@@ -83,14 +79,11 @@ done
|
|||||||
fi
|
fi
|
||||||
|
|
||||||
for source in "${remote_sources[@]}"; do
|
for source in "${remote_sources[@]}"; do
|
||||||
echo "trying source: $source" >&2
|
|
||||||
|
|
||||||
url="${base_addresses[$source]}$package/$version/$package.$version.nupkg"
|
url="${base_addresses[$source]}$package/$version/$package.$version.nupkg"
|
||||||
echo "full url: $url" >&2
|
|
||||||
|
|
||||||
if [[ "$source" == "$used_source" ]]; then
|
if [[ "$source" == "$used_source" ]]; then
|
||||||
hash="$(nix-hash --type sha256 --flat --sri "$version/$package.$version".nupkg)"
|
hash="$(nix-hash --type sha256 --flat --sri "$version/$package.$version".nupkg)"
|
||||||
echo "hash: $hash" >&2
|
|
||||||
found=true
|
found=true
|
||||||
break
|
break
|
||||||
fi
|
fi
|
||||||
|
|||||||
Reference in New Issue
Block a user