Skip to content

action: mmissing cache added #1

action: mmissing cache added

action: mmissing cache added #1

Workflow file for this run

name: Publish
on:
push:
branches: [release]
env:
CARGO_TERM_COLOR: always
jobs:
publish:
runs-on: ubuntu-latest
permissions: write-all
steps:
- uses: actions/checkout@v3
- name: Extract version
id: extract-version
run: echo "VERSION=$(grep -oP '^version = "\K[^"]+' Cargo.toml | awk '{$1=$1;print}')" >> $GITHUB_OUTPUT
- name: Run clippy
run: cargo clippy --all-features --all-targets -- -D warnings
- name: Run all tests with default features
run: cargo test
- name: Run tests with all features
run: cargo test --all-features
- name: publish crates dry run
run: |
cargo login ${{ secrets.crates_io }}
cargo publish -p encrypt_config --dry-run
cargo publish -p encrypt_config_derive --dry-run
- name: publish crates
run: |
cargo publish -p encrypt_config
cargo publish -p encrypt_config_derive
- name: Create Tag
uses: actions/github-script@v6
with:
script: |
github.rest.git.createRef({
owner: context.repo.owner,
repo: context.repo.repo,
ref: 'refs/tags/v${{ steps.extract-version.outputs.VERSION }}',
sha: context.sha
})