diff --git a/.github/workflows/build.yml b/.github/workflows/build.yml new file mode 100644 index 0000000..48d9c4d --- /dev/null +++ b/.github/workflows/build.yml @@ -0,0 +1,25 @@ +name: Build + +on: [push, pull_request, workflow_dispatch] + +concurrency: + group: ${{ github.base_ref }}-build + cancel-in-progress: true + +jobs: + + default: + runs-on: ubuntu-latest + + steps: + - uses: actions/checkout@v2 + - name: Deny check + uses: EmbarkStudios/cargo-deny-action@v1 + - name: Format check + run: cargo fmt --check + - name: Lint check + run: cargo clippy --all-targets --all-features --no-deps + - name: Build + run: cargo build + - name: Tests + run: cargo test diff --git a/.github/workflows/doc.yml b/.github/workflows/doc.yml new file mode 100644 index 0000000..ea083fa --- /dev/null +++ b/.github/workflows/doc.yml @@ -0,0 +1,46 @@ +name: Documentation + +on: + push: + branches: [ master ] + workflow_dispatch: + +concurrency: + group: "pages" + cancel-in-progress: true + +jobs: + + tests: + name: tests + + runs-on: ubuntu-latest + + steps: + - uses: actions/checkout@v2 + - name: Generate documentation + run: cargo doc --no-deps + - name: Create index file + run: echo "" > target/doc/index.html + - name: Upload page artifact + uses: actions/upload-pages-artifact@v1 + with: + path: "target/doc/" + + deploy: + name: deploy + needs: tests + + permissions: + pages: write + id-token: write + + environment: + name: github-pages + url: ${{ steps.deployment.output.page_url }} + + runs-on: ubuntu-latest + steps: + - name: Deploy documentation to GitHub Pages + id: deployment + uses: actions/deploy-pages@v1 \ No newline at end of file diff --git a/.github/workflows/release.yml b/.github/workflows/release.yml new file mode 100644 index 0000000..60c04c2 --- /dev/null +++ b/.github/workflows/release.yml @@ -0,0 +1,37 @@ +name: Release + +on: + release: + types: [created] + push: + + +jobs: + release: + name: release ${{ matrix.target }} (with non-required env) + runs-on: ubuntu-latest + if: github.event_name == 'release' + + strategy: + fail-fast: false + matrix: + include: + - target: x86_64-pc-windows-gnu + archive: zip + - target: x86_64-unknown-linux-musl + archive: tar.gz + - target: x86_64-apple-darwin + archive: zip + - target: wasm32-wasi + archive: zip tar.gz + + steps: + - uses: actions/checkout@master + - name: Compile and release + uses: rust-build/rust-build.action@master + env: + GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} + with: + RUSTTARGET: ${{ matrix.target }} + EXTRA_FILES: README.md LICENSE-APACHE LICENSE-MIT + ARCHIVE_TYPES: ${{ matrix.archive }} diff --git a/README.md b/README.md index 0956dad..070b638 100644 --- a/README.md +++ b/README.md @@ -1,3 +1,12 @@ +[![Build][build-badge]][build-link] +[![Documentation][documentation-badge]][documentation-link] + +[build-badge]: https://github.com/RatCornu/efs/workflows/Build/badge.svg +[documentation-badge]: https://github.com/RatCornu/efs/workflows/Documentation/badge.svg + +[build-link]: https://github.com/RatCornu/efs/actions?query=workflow:"Build" +[documentation-link]: https://github.com/RatCornu/efs/actions?query=workflow:"Documentation" + # Extended filesystem An OS and architecture independent implementation of some filesystems in Rust. \ No newline at end of file diff --git a/deny.toml b/deny.toml new file mode 100644 index 0000000..98dfe57 --- /dev/null +++ b/deny.toml @@ -0,0 +1,18 @@ +all-features = true + +[advisories] +notice = "deny" +unmaintained = "deny" +unsound = "deny" +vulnerability = "deny" +yanked = "deny" + +[licenses] +allow-osi-fsf-free = "both" +confidence-threshold = 1 +copyleft = "allow" +default = "deny" +unlicensed = "deny" + +[sources] +unknown-registry = "deny" \ No newline at end of file