diff --git a/.gitea/workflows/cargo.yaml b/.gitea/workflows/cargo.yaml.disabled similarity index 100% rename from .gitea/workflows/cargo.yaml rename to .gitea/workflows/cargo.yaml.disabled diff --git a/.gitea/workflows/release.yaml b/.gitea/workflows/release.yaml deleted file mode 100644 index 1b978bc..0000000 --- a/.gitea/workflows/release.yaml +++ /dev/null @@ -1,32 +0,0 @@ -name: Release-plz - -permissions: - pull-requests: write - contents: write - -on: - push: - branches: - - master - -jobs: - - # Release unpublished packages. - release-plz-release: - name: Release-plz release - steps: - - name: Checkout repository - uses: actions/checkout@v4 - - name: Install Rust toolchain - uses: https://github.com/dtolnay/rust-toolchain@stable - - name: Manually Install binaries - uses: https://github.com/taiki-e/install-action@v2 - with: - tool: cargo-semver-checks@0.35, release-plz@0.3.102 # hack - - name: Run release-plz - uses: https://github.com/MarcoIeni/release-plz-action@v0.5 - with: - backend: gitea - env: - GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} - CARGO_REGISTRY_TOKEN: ${{ secrets.CARGO_REGISTRY_TOKEN }} diff --git a/.github/dependabot.yaml b/.github/dependabot.yaml new file mode 100644 index 0000000..7ee8cf8 --- /dev/null +++ b/.github/dependabot.yaml @@ -0,0 +1,7 @@ +version: 2 +updates: + - package-ecosystem: "github-actions" + directory: "/" + # Check for updates every Monday + schedule: + interval: "weekly" diff --git a/.github/workflows/cargo.yaml b/.github/workflows/cargo.yaml index 28cecde..404d638 100644 --- a/.github/workflows/cargo.yaml +++ b/.github/workflows/cargo.yaml @@ -1,10 +1,16 @@ -name: cargo devel CI +name: Rust CI on: + pull_request: + branches: + - '**' push: branches: - '**' # - '!master' +env: + CARGO_TERM_COLOR: always + jobs: CI: runs-on: ubuntu-latest @@ -38,10 +44,10 @@ jobs: - name: cargo fmt run: cargo fmt --all - name: cargo test - run: cargo test --all-features --all-targets --workspace && cargo test --all-features --workspace --doc + run: cargo test --all-features --all-targets --workspace - name: commit back to repository uses: stefanzweifel/git-auto-commit-action@v5 with: # Optional. Commit message for the created commit. # Defaults to "Apply automatic changes" - commit_message: "ci: automatic cargo CI changes" + commit_message: "ci: automatic Rust CI changes" diff --git a/.github/workflows/release.yaml b/.github/workflows/release.yaml new file mode 100644 index 0000000..ebc682f --- /dev/null +++ b/.github/workflows/release.yaml @@ -0,0 +1,54 @@ +name: Release-plz + +permissions: + pull-requests: write + contents: write + +on: + push: + branches: + - master + - main + +jobs: + + # Release unpublished packages. + release-plz-release: + name: Release-plz release + runs-on: ubuntu-latest + steps: + - name: Checkout repository + uses: actions/checkout@v4 + with: + fetch-depth: 0 + - name: Install Rust toolchain + uses: dtolnay/rust-toolchain@stable + - name: Run release-plz + uses: MarcoIeni/release-plz-action@v0.5 + with: + command: release + env: + GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} + CARGO_REGISTRY_TOKEN: ${{ secrets.CARGO_REGISTRY_TOKEN }} + + # Create a PR with the new versions and changelog, preparing the next release. + release-plz-pr: + name: Release-plz PR + runs-on: ubuntu-latest + concurrency: + group: release-plz-${{ github.ref }} + cancel-in-progress: false + steps: + - name: Checkout repository + uses: actions/checkout@v4 + with: + fetch-depth: 0 + - name: Install Rust toolchain + uses: dtolnay/rust-toolchain@stable + - name: Run release-plz + uses: MarcoIeni/release-plz-action@v0.5 + with: + command: release-pr + env: + GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} + CARGO_REGISTRY_TOKEN: ${{ secrets.CARGO_REGISTRY_TOKEN }}