Skip to content

Commit cc8d8ff

Browse files
microsoft-identity-broker: fix the hash (#340811)
2 parents 6ff7ec3 + caee0fe commit cc8d8ff

File tree

2 files changed

+7
-3
lines changed

2 files changed

+7
-3
lines changed

pkgs/by-name/mi/microsoft-identity-broker/package.nix

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -16,7 +16,7 @@ stdenv.mkDerivation rec {
1616

1717
src = fetchurl {
1818
url = "https://packages.microsoft.com/ubuntu/22.04/prod/pool/main/m/microsoft-identity-broker/microsoft-identity-broker_${version}_amd64.deb";
19-
hash = "sha256-O9zbImSWMrRsaOozj5PsCRvQ3UsaJzLfoTohmLZvLkM=";
19+
hash = "sha256-I4Q6ucT6ps8/QGiQTNbMXcKxq6UMcuwJ0Prcqvov56M=";
2020
};
2121

2222
nativeBuildInputs = [ dpkg makeWrapper openjdk11 zip ];

pkgs/by-name/mi/microsoft-identity-broker/update.sh

Lines changed: 6 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -12,15 +12,19 @@ echo "$index_file" | while read -r line; do
1212
if [[ "$line" =~ ^Version:[[:space:]]*(.*) ]]; then
1313
Version="${BASH_REMATCH[1]}"
1414
fi
15+
if [[ "$line" =~ ^SHA256:[[:space:]]*(.*) ]]; then
16+
SHA256="${BASH_REMATCH[1]}"
17+
fi
1518

1619
if ! [[ "$line" ]] && [[ "${Package}" == "microsoft-identity-broker" ]]; then
1720
if ( dpkg --compare-versions ${Version} gt ${latest_version} ); then
1821
latest_version="${Version}"
22+
sri_hash=$(nix-hash --to-sri --type sha256 "$SHA256")
1923

20-
echo $latest_version
24+
echo $latest_version $sri_hash
2125
fi
2226

2327
Package=""
2428
Version=""
2529
fi
26-
done | tail -n 1 | (read version; update-source-version microsoft-identity-broker $version)
30+
done | tail -n 1 | (read version hash; update-source-version microsoft-identity-broker $version $hash)

0 commit comments

Comments
 (0)