From 3361b8b3a75a2d12c6c36f502d4317161b0d4330 Mon Sep 17 00:00:00 2001 From: ahuston-0 Date: Wed, 12 Mar 2025 23:08:59 -0400 Subject: [PATCH 1/3] replace file reader Signed-off-by: ahuston-0 --- .github/workflows/flake-update.yml | 17 ++++++++--------- 1 file changed, 8 insertions(+), 9 deletions(-) diff --git a/.github/workflows/flake-update.yml b/.github/workflows/flake-update.yml index 4c26304..fb99e9c 100644 --- a/.github/workflows/flake-update.yml +++ b/.github/workflows/flake-update.yml @@ -94,14 +94,13 @@ jobs: run: nix ./utils/eval-to-drv.sh post - name: Calculate diff run: nix ./utils/diff-evals.sh - - name: Read diff into environment - run: | - delimiter="$(openssl rand -hex 8)" - { - echo "POSTDIFF<<${delimiter}" - cat post-diff - echo "${delimiter}" - } >> $GITHUB_ENV + - name: Read file contents + id: read_file + uses: andstor/file-reader-action@v1 + with: + path: "post-diff" + - name: File contents + run: echo "${ steps.read_file.outputs.contents }" - name: Write PR body template uses: https://github.com/DamianReeves/write-file-action@v1.3 with: @@ -114,7 +113,7 @@ jobs: ``` ``` - {{ env.POSTDIFF }} + {{ steps.read_file.outputs.contents }} ``` Auto-generated by [update.yml][1] with the help of -- 2.48.1 From 19486ca3665d584c2fd08af5fec1e7736a3c32c4 Mon Sep 17 00:00:00 2001 From: ahuston-0 Date: Wed, 12 Mar 2025 23:10:49 -0400 Subject: [PATCH 2/3] heh get rid of that thank you --- .github/workflows/flake-update.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/flake-update.yml b/.github/workflows/flake-update.yml index fb99e9c..88c2285 100644 --- a/.github/workflows/flake-update.yml +++ b/.github/workflows/flake-update.yml @@ -61,7 +61,7 @@ jobs: # automated update_lockfile: runs-on: ubuntu-latest - if: github.ref == 'refs/heads/main' # ensure workflow_dispatch only runs on main + #if: github.ref == 'refs/heads/main' # ensure workflow_dispatch only runs on main steps: - name: Checkout repository uses: actions/checkout@v4 -- 2.48.1 From ec4a97375fd59da5a2e8282353dd4520531ee195 Mon Sep 17 00:00:00 2001 From: ahuston-0 Date: Wed, 12 Mar 2025 23:11:52 -0400 Subject: [PATCH 3/3] remove createPullRequest Signed-off-by: ahuston-0 --- .github/workflows/flake-update.yml | 54 ------------------------------ 1 file changed, 54 deletions(-) diff --git a/.github/workflows/flake-update.yml b/.github/workflows/flake-update.yml index 88c2285..c9a1e9c 100644 --- a/.github/workflows/flake-update.yml +++ b/.github/workflows/flake-update.yml @@ -5,60 +5,6 @@ on: schedule: - cron: "00 12 * * *" jobs: - createPullRequest: - runs-on: ubuntu-latest - steps: - - uses: actions/checkout@v4 - # - name: Login to Docker Hub - # uses: docker/login-action@v3 - # with: - # username: ${{ secrets.DOCKERHUB_USERNAME }} - # password: ${{ secrets.DOCKERHUB_TOKEN }} - - name: Install Nix - uses: cachix/install-nix-action@v24 - with: - extra_nix_config: | - experimental-features = nix-command flakes auto-allocate-uids configurable-impure-env - - name: Calculate pre-drv - run: nix run git+https://nayeonie.com/ahuston-0/flake-update-diff -- --build . - # - name: Pull latest docker images - # run: nix ./utils/fetch-docker.sh - - name: Update flake.lock (part 1) - run: nix flake update - - name: Calculate post-drv - run: nix run git+https://nayeonie.com/ahuston-0/flake-update-diff -- --build . - # - name: Calculate diff - # run: nix ./utils/diff-evals.sh - # - name: Read diff into environment - # run: | - # delimiter="$(openssl rand -hex 8)" - # { - # echo "POSTDIFF<<${delimiter}" - # cat post-diff - # echo "${delimiter}" - # } >> $GITHUB_ENV - - - # - name: Restore flake.lock for next step - # run: git restore flake.lock - # - name: Update flake.lock - # id: update - # uses: DeterminateSystems/update-flake-lock@main - # with: - # token: ${{ secrets.GH_TOKEN_FOR_UPDATES }} - # pr-body: | - # Automated changes by the [update-flake-lock](https://github.com/DeterminateSystems/update-flake-lock) GitHub Action. - - # ``` - # {{ env.GIT_COMMIT_MESSAGE }} - # ``` - - # ``` - # {{ env.POSTDIFF }} - # ``` - # pr-labels: | # Labels to be set on the PR - # dependencies - # automated update_lockfile: runs-on: ubuntu-latest #if: github.ref == 'refs/heads/main' # ensure workflow_dispatch only runs on main -- 2.48.1