Skip to content

Commit

Permalink
ci: test ci
Browse files Browse the repository at this point in the history
  • Loading branch information
ValuedMammal committed Aug 21, 2024
1 parent 50f1865 commit 7394203
Show file tree
Hide file tree
Showing 4 changed files with 9 additions and 7 deletions.
11 changes: 6 additions & 5 deletions .github/workflows/cron-update-rustc.yml
Original file line number Diff line number Diff line change
Expand Up @@ -14,10 +14,10 @@ jobs:
run: |
set -x
# Extract the date from whatever version of the compiler dtolnay/rust-toolchain gives us.
RUSTC_DATE=$(rustc --verbose --version | sed -ne 's/^commit-date: //p')
RUSTC_VERSION=$(rustc --verbose --version | sed -ne 's/^release: //p')
# Update the version in the reference file.
echo "stable-${RUSTC_DATE}" > rustc-stable-version
echo "rustc_date=${RUSTC_DATE}" >> $GITHUB_ENV
echo "${RUSTC_VERSION}" > rustc-version
echo "rustc_version=${RUSTC_VERSION}" >> $GITHUB_ENV
# In case of no new version don't make an empty PR.
if ! git diff --exit-code > /dev/null; then
echo "Updated rustc. Opening PR."
Expand All @@ -30,10 +30,11 @@ jobs:
if: env.changes_made == 'true'
uses: peter-evans/create-pull-request@v6
with:
token: ${{ secrets.CREATE_PR_TOKEN }}
author: Update Rustc Bot <bot@example.com>
committer: Update Rustc Bot <bot@example.com>
title: Automated weekly update to rustc (to stable-${{ env.rustc_date }})
title: Automated weekly update to rustc (to ${{ env.rustc_version }})
body: |
Automated update to Github CI workflow `rust.yml` by [create-pull-request](https://github.com/peter-evans/create-pull-request) GitHub action
commit-message: Automated update to Github CI to rustc stable-${{ env.rustc_date }}
commit-message: Automated update to Github CI to rustc ${{ env.rustc_version }}
branch: create-pull-request/weekly-stable-update
3 changes: 2 additions & 1 deletion .github/workflows/rust.yml
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,7 @@ jobs:
uses: actions/checkout@v4
- name: "Read rustc version"
id: read_toolchain
run: echo "rustc_version=$(cat rustc-stable-version)" >> $GITHUB_OUTPUT
run: echo "rustc_version=$(cat rustc-version)" >> $GITHUB_OUTPUT

Build:
runs-on: ubuntu-latest
Expand All @@ -32,6 +32,7 @@ jobs:
run: cargo build

Clippy:
needs: Prepare
runs-on: ubuntu-latest
steps:
- name: "Checkout"
Expand Down
1 change: 0 additions & 1 deletion rustc-stable-version

This file was deleted.

1 change: 1 addition & 0 deletions rustc-version
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
1.78.0

0 comments on commit 7394203

Please sign in to comment.