From 50b40bf06a5008322dddf2f9ee90f7dee4fa6f4e Mon Sep 17 00:00:00 2001 From: Eric Rodrigues Pires Date: Mon, 25 Nov 2024 22:53:44 -0300 Subject: [PATCH] Update README and add validation workflow --- .github/workflows/{docker.yml => build.yml} | 6 ++-- .github/workflows/mdbook.yml | 2 +- .github/workflows/validate.yml | 37 +++++++++++++++++++++ README.md | 3 ++ 4 files changed, 44 insertions(+), 4 deletions(-) rename .github/workflows/{docker.yml => build.yml} (96%) create mode 100644 .github/workflows/validate.yml diff --git a/.github/workflows/docker.yml b/.github/workflows/build.yml similarity index 96% rename from .github/workflows/docker.yml rename to .github/workflows/build.yml index d384276..a5cf77c 100644 --- a/.github/workflows/docker.yml +++ b/.github/workflows/build.yml @@ -1,4 +1,4 @@ -name: docker +name: Build on: push: @@ -9,7 +9,7 @@ permissions: contents: write jobs: - build-docker: + build-docker-images: name: Build Docker images runs-on: ubuntu-latest steps: @@ -58,7 +58,7 @@ jobs: create-release-draft: name: Create release draft if: github.ref_type == 'tag' - needs: build-docker + needs: build-docker-images runs-on: ubuntu-latest steps: - name: Download artifact diff --git a/.github/workflows/mdbook.yml b/.github/workflows/mdbook.yml index ab00738..95d013e 100644 --- a/.github/workflows/mdbook.yml +++ b/.github/workflows/mdbook.yml @@ -1,4 +1,4 @@ -name: mdbook +name: mdBook on: push: diff --git a/.github/workflows/validate.yml b/.github/workflows/validate.yml new file mode 100644 index 0000000..9acba32 --- /dev/null +++ b/.github/workflows/validate.yml @@ -0,0 +1,37 @@ +name: Validate + +on: + push: + branches: ["main"] + pull_request: + +permissions: + contents: read + +jobs: + rustfmt: + name: Check rustfmt formatting + runs-on: ubuntu-latest + steps: + - uses: actions/checkout@v4 + - name: Run rustfmt + run: | + rustup component add rustfmt + cargo fmt --check + clippy: + name: Check Clippy lints + runs-on: ubuntu-latest + steps: + - uses: actions/checkout@v4 + - name: Run Clippy + run: | + rustup component add clippy + cargo clippy -- -D warnings + tests: + name: Tests + runs-on: ubuntu-latest + steps: + - uses: actions/checkout@v4 + - name: Run tests + run: | + cargo test --verbose diff --git a/README.md b/README.md index 953e65b..376b57a 100644 --- a/README.md +++ b/README.md @@ -1,5 +1,8 @@ # sandhole +[![crates.io version](https://img.shields.io/crates/v/sandhole)](https://crates.io/crates/sandhole) +[![GitHub license](https://img.shields.io/github/license/epiceric/sandhole)](https://github.com/EpicEric/sandhole/blob/main/LICENSE) + Expose HTTP/SSH/TCP services through SSH port forwarding. [Check out the Sandhole book.](https://epiceric.github.io/sandhole/) -- knotmirror 0.0.1