Skip to content

Evaluation workflow

Evaluation workflow #9

Workflow file for this run

name: "Evaluate mainnet scripts"
# on:
# schedule:
# - cron: "0 0 * * 5" # Run every Friday at midnight
on:
pull_request:
jobs:
build:
name: Build
runs-on: [plutus-script-evaluation-ci, self-hosted]
strategy:
fail-fast: false
steps:
- name: Checkout this Repo
uses: actions/checkout@main
with:
path: temp
- name: Add plutus SRP to the cabal.project
id: update_cabal_project
run: |
REPO="IntersectMBO/plutus"
REPO_URL="https://github.com/$REPO"
PREFETCHED=$(nix-shell -p nix-prefetch-git --run "nix-prefetch-git --quiet --url $REPO_URL --no-deepClone")
LAST_COMMIT=$(echo $PREFETCHED | jq -r .sha)
NIX_SHA=$(echo $PREFETCHED | jq -r .hash)
# Create the new section to append
read -r -d '' NEW_SECTION << EOM
source-repository-package
type: git
location: $REPO_URL
tag: $LAST_COMMIT
--sha256: $NIX_SHA
subdir:
plutus-tx
plutus-core
plutus-ledger-api
EOM
# Append to cabal.project
echo "$NEW_SECTION" >> cabal.project
# Output the values for potential later use
echo "commit=$LAST_COMMIT" >> $GITHUB_OUTPUT
echo "sha256=$NIX_SHA" >> $GITHUB_OUTPUT
- name: Evaluate
run: |
nix develop --no-warn-dirty --accept-flake-config \
--command bash -c 'cabal clean && cabal update && evaluate'