Clone of https://github.com/NixOS/nixpkgs.git (to stress-test knotserver)

update-source-version: Fix regex metacharacter

In sed variety of regexes, '\|' must be used in place of '|'.

+1 -1
+1 -1
pkgs/common-updater/scripts/update-source-version
··· 74 74 if [ -z "$newHash" ]; then 75 75 nix-build --no-out-link -A "$attr.src" 2>"$attr.fetchlog" >/dev/null || true 76 76 # FIXME: use nix-build --hash here once https://github.com/NixOS/nix/issues/1172 is fixed 77 - newHash=$(egrep -v "killing process|dependencies couldn't be built" "$attr.fetchlog" | tail -n2 | sed "s~output path .* has .* hash \(.*\) when .* was expected|fixed-output derivation produced path '.*' with .* hash '\(.*\)' instead of the expected hash '.*'~\1\2~" | head -n1) 77 + newHash=$(egrep -v "killing process|dependencies couldn't be built" "$attr.fetchlog" | tail -n2 | sed "s~output path .* has .* hash \(.*\) when .* was expected\|fixed-output derivation produced path '.*' with .* hash '\(.*\)' instead of the expected hash '.*'~\1\2~" | head -n1) 78 78 fi 79 79 80 80 if [ -z "$newHash" ]; then