added branch to the branches that trigger the docker action

This commit is contained in:
2025-10-24 23:29:52 +02:00
parent 98e11b9da1
commit 4d545ff7c5

View File

@@ -1,32 +1,29 @@
name: Docker
on:
push:
branches: [ "main" ]
paths:
- 'Cargo.toml'
pull_request:
branches: [ "main" ]
push:
branches: ["main", "feature/docker"]
pull_request:
branches: ["main"]
env:
CARGO_TERM_COLOR: always
CARGO_TERM_COLOR: always
jobs:
build:
build:
runs-on: ubuntu-latest
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- name: Build Docker image
run: |
apt install -y nu
version=$(nu -c "cargo metadata --format-version=1 --no-deps | from json | get packages | first | get version")
echo $version
- name: Run tests
run: cargo test --verbose
- name: Publish to crates.io
env:
CARGO_REGISTRY_TOKEN: ${{ secrets.CRATES_IO_TOKEN }}
run: |
cargo publish --verbose
steps:
- uses: actions/checkout@v4
- name: Build Docker image
run: |
apt install -y nu
version=$(nu -c "cargo metadata --format-version=1 --no-deps | from json | get packages | first | get version")
echo $version
- name: Run tests
run: cargo test --verbose
- name: Publish to crates.io
env:
CARGO_REGISTRY_TOKEN: ${{ secrets.CRATES_IO_TOKEN }}
run: |
cargo publish --verbose