Skip to content
Permalink

Comparing changes

Choose two branches to see what’s changed or to start a new pull request. If you need to, you can also or learn more about diff comparisons.

Open a pull request

Create a new pull request by comparing changes across two branches. If you need to, you can also . Learn more about diff comparisons here.
base repository: NixOS/cabal2nix
Failed to load repositories. Confirm that selected base ref is valid, then try again.
Loading
base: 11a103bdb960
Choose a base ref
...
head repository: NixOS/cabal2nix
Failed to load repositories. Confirm that selected head ref is valid, then try again.
Loading
compare: d19490223d91
Choose a head ref
  • 1 commit
  • 1 file changed
  • 1 contributor

Commits on Nov 13, 2020

  1. Copy the full SHA
    d194902 View commit details
Showing with 4 additions and 4 deletions.
  1. +4 −4 update-stackage.sh
8 changes: 4 additions & 4 deletions update-stackage.sh
Original file line number Diff line number Diff line change
@@ -8,8 +8,8 @@ tmpfile=$(mktemp "update-stackage.XXXXXXX")
# shellcheck disable=SC2064
trap "rm ${tmpfile} ${tmpfile}.new" 0

curl -L -s "https://stackage.org/lts/cabal.config" >"$tmpfile"
version=$(sed -rn "s/^--.*http:..(www.)?stackage.org.snapshot.lts-//p" "$tmpfile")
curl -L -s "https://stackage.org/nightly/cabal.config" >"$tmpfile"
version=$(sed -rn "s/^--.*http:..(www.)?stackage.org.snapshot.nightly-//p" "$tmpfile")

# Create a simple yaml version of the file.
sed -r \
@@ -44,10 +44,10 @@ sed -r \

# Drop the previous configuration ...
# shellcheck disable=SC1004
sed -e '/ # LTS Haskell/,/^$/c \TODO\
sed -e '/ # Stackage Nightly/,/^$/c \TODO\
' -i nixpkgs/pkgs/development/haskell-modules/configuration-hackage2nix.yaml

# ... and replace it with the new one.
sed -e "/TODO/r $tmpfile" \
-e "s/TODO/ # LTS Haskell $version/" \
-e "s/TODO/ # Stackage Nightly $version/" \
-i nixpkgs/pkgs/development/haskell-modules/configuration-hackage2nix.yaml