Skip to content

chore: pointing to SECURITY.md in CONTRIBUTING.md for security issues #379

chore: pointing to SECURITY.md in CONTRIBUTING.md for security issues

chore: pointing to SECURITY.md in CONTRIBUTING.md for security issues #379

Workflow file for this run

name: Build
on:
push:
branches:
- main
pull_request:
branches:
- main
env:
CARGO_TERM_COLOR: always
RUST_LOG: info
RUST_BACKTRACE: 1
jobs:
test:
name: Lint and test
runs-on: ubuntu-latest
strategy:
fail-fast: false
steps:
- uses: actions/checkout@v4
- uses: dtolnay/rust-toolchain@stable
with:
toolchain: stable
components: clippy, rustfmt
- name: Build prompting-client snap
id: snapcraft-client
uses: snapcore/action-build@v1
- name: Build testing snap
id: snapcraft-testing
uses: snapcore/action-build@v1
with:
path: testing-snap
- name: Setup snapd and snaps
run: |
sudo snap refresh snapd --channel=latest/edge
sudo snap set system experimental.user-daemons=true
sudo snap install --dangerous ${{ steps.snapcraft-client.outputs.snap }}
sudo snap install --dangerous ${{ steps.snapcraft-testing.outputs.snap }}
sudo snap connect prompting-client:snap-interfaces-requests-control
sudo snap set system experimental.apparmor-prompting=true
- name: Install dependencies
run: |
sudo apt-get install protobuf-compiler
- name: Check generated files are up to date
working-directory: ./prompting-client
run: |
cargo clean
cargo build
# Compare generated files with committed files
if ! diff -r ./src/protos ./src/protos; then
echo "Protobuf files are not up-to-date. Please regenerate and commit them."
exit 1
fi
echo "Protobuf files are up-to-date."
- name: Run tests
working-directory: ./prompting-client
run: |
cargo fmt -- --check
cargo clippy -- -D warnings
cargo test