Remove .github
This commit is contained in:
14
.github/dependabot.yaml
vendored
14
.github/dependabot.yaml
vendored
@@ -1,14 +0,0 @@
|
|||||||
version: 2
|
|
||||||
updates:
|
|
||||||
- package-ecosystem: github-actions
|
|
||||||
directory: /
|
|
||||||
schedule:
|
|
||||||
interval: weekly
|
|
||||||
time: "07:00"
|
|
||||||
timezone: "Asia/Tokyo"
|
|
||||||
- package-ecosystem: cargo
|
|
||||||
directory: /
|
|
||||||
schedule:
|
|
||||||
interval: weekly
|
|
||||||
time: "07:00"
|
|
||||||
timezone: "Asia/Tokyo"
|
|
||||||
31
.github/workflows/audit.yaml
vendored
31
.github/workflows/audit.yaml
vendored
@@ -1,31 +0,0 @@
|
|||||||
name: Security audit
|
|
||||||
|
|
||||||
on:
|
|
||||||
schedule:
|
|
||||||
- cron: "0 0 */3 * *"
|
|
||||||
|
|
||||||
push:
|
|
||||||
branches: [main]
|
|
||||||
paths:
|
|
||||||
- "**/Cargo.toml"
|
|
||||||
- "**/Cargo.lock"
|
|
||||||
|
|
||||||
pull_request:
|
|
||||||
paths:
|
|
||||||
- "**/Cargo.toml"
|
|
||||||
- "**/Cargo.lock"
|
|
||||||
|
|
||||||
jobs:
|
|
||||||
audit:
|
|
||||||
name: Audit
|
|
||||||
runs-on: ubuntu-latest
|
|
||||||
steps:
|
|
||||||
- uses: actions/checkout@8e8c483db84b4bee98b60c0593521ed34d9990e8 # v6.0.1
|
|
||||||
|
|
||||||
- name: Install cargo-audit
|
|
||||||
uses: taiki-e/install-action@30eab0fabba9ea3f522099957e668b21876aa39e # v2.66.6
|
|
||||||
with:
|
|
||||||
tool: cargo-audit
|
|
||||||
|
|
||||||
- name: Run audit
|
|
||||||
run: cargo audit
|
|
||||||
39
.github/workflows/benchmark.yaml
vendored
39
.github/workflows/benchmark.yaml
vendored
@@ -1,39 +0,0 @@
|
|||||||
name: Benchmark
|
|
||||||
on:
|
|
||||||
push:
|
|
||||||
branches:
|
|
||||||
- main
|
|
||||||
paths:
|
|
||||||
- '**/*.rs'
|
|
||||||
- '**/Cargo.toml'
|
|
||||||
- '**/Cargo.lock'
|
|
||||||
- '.github/workflows/benchmark.yaml'
|
|
||||||
|
|
||||||
permissions:
|
|
||||||
contents: write
|
|
||||||
deployments: write
|
|
||||||
|
|
||||||
jobs:
|
|
||||||
benchmark:
|
|
||||||
name: Run Rust benchmark example
|
|
||||||
runs-on: ubuntu-latest
|
|
||||||
steps:
|
|
||||||
- uses: actions/checkout@8e8c483db84b4bee98b60c0593521ed34d9990e8 # v6.0.1
|
|
||||||
- name: Toolchain setup
|
|
||||||
run: rustup toolchain update nightly && rustup default nightly
|
|
||||||
- name: Run benchmark
|
|
||||||
run: cargo +nightly bench | tee output.txt
|
|
||||||
|
|
||||||
- name: Store benchmark result
|
|
||||||
uses: benchmark-action/github-action-benchmark@4bdcce38c94cec68da58d012ac24b7b1155efe8b # v1.20.7
|
|
||||||
with:
|
|
||||||
name: Rust Benchmark
|
|
||||||
tool: 'cargo'
|
|
||||||
output-file-path: output.txt
|
|
||||||
github-token: ${{ secrets.GITHUB_TOKEN }}
|
|
||||||
auto-push: true
|
|
||||||
# Show alert with commit comment on detecting possible performance regression
|
|
||||||
alert-threshold: '200%'
|
|
||||||
comment-on-alert: true
|
|
||||||
fail-on-alert: true
|
|
||||||
benchmark-data-dir-path: docs
|
|
||||||
97
.github/workflows/ci.yaml
vendored
97
.github/workflows/ci.yaml
vendored
@@ -1,97 +0,0 @@
|
|||||||
name: Rust CI
|
|
||||||
|
|
||||||
on:
|
|
||||||
push:
|
|
||||||
branches: [main]
|
|
||||||
paths:
|
|
||||||
- '**/*.rs'
|
|
||||||
- '**/Cargo.toml'
|
|
||||||
- '**/Cargo.lock'
|
|
||||||
- '.github/workflows/ci.yaml'
|
|
||||||
|
|
||||||
pull_request:
|
|
||||||
paths:
|
|
||||||
- '**/*.rs'
|
|
||||||
- '**/Cargo.toml'
|
|
||||||
- '**/Cargo.lock'
|
|
||||||
- '.github/workflows/ci.yaml'
|
|
||||||
|
|
||||||
env:
|
|
||||||
CARGO_TERM_COLOR: always
|
|
||||||
|
|
||||||
concurrency:
|
|
||||||
group: ${{ github.workflow }}-${{ github.ref }}
|
|
||||||
cancel-in-progress: true
|
|
||||||
|
|
||||||
jobs:
|
|
||||||
check:
|
|
||||||
name: Check
|
|
||||||
strategy:
|
|
||||||
matrix:
|
|
||||||
os: [ubuntu-latest, macos-latest, windows-latest]
|
|
||||||
runs-on: ${{ matrix.os }}
|
|
||||||
steps:
|
|
||||||
- uses: actions/checkout@8e8c483db84b4bee98b60c0593521ed34d9990e8 # v6.0.1
|
|
||||||
with:
|
|
||||||
fetch-depth: 0
|
|
||||||
|
|
||||||
- uses: actions-rust-lang/setup-rust-toolchain@1780873c7b576612439a134613cc4cc74ce5538c # v1.15.2
|
|
||||||
with:
|
|
||||||
components: rustfmt, clippy
|
|
||||||
cache-shared-key: setup-rust-${{ runner.os }}-${{ runner.arch }}-${{ hashFiles('**/Cargo.lock') }}
|
|
||||||
|
|
||||||
- name: Install reviewdog
|
|
||||||
uses: reviewdog/action-setup@d8a7baabd7f3e8544ee4dbde3ee41d0011c3a93f # v1.5.0
|
|
||||||
|
|
||||||
- name: Check format
|
|
||||||
run: |
|
|
||||||
cargo fmt --all -- --check
|
|
||||||
|
|
||||||
- uses: giraffate/clippy-action@13b9d32482f25d29ead141b79e7e04e7900281e0 # v1.0.1
|
|
||||||
with:
|
|
||||||
reporter: 'github-pr-review'
|
|
||||||
github_token: ${{ secrets.GITHUB_TOKEN }}
|
|
||||||
fail_on_error: true
|
|
||||||
filter_mode: nofilter
|
|
||||||
|
|
||||||
- name: Build
|
|
||||||
run: cargo build
|
|
||||||
|
|
||||||
test:
|
|
||||||
name: Test
|
|
||||||
strategy:
|
|
||||||
matrix:
|
|
||||||
os: [ubuntu-latest, macos-latest, windows-latest]
|
|
||||||
runs-on: ${{ matrix.os }}
|
|
||||||
permissions:
|
|
||||||
contents: write
|
|
||||||
pull-requests: write
|
|
||||||
steps:
|
|
||||||
- uses: actions/checkout@8e8c483db84b4bee98b60c0593521ed34d9990e8 # v6.0.1
|
|
||||||
with:
|
|
||||||
fetch-depth: 0
|
|
||||||
|
|
||||||
- uses: actions-rust-lang/setup-rust-toolchain@1780873c7b576612439a134613cc4cc74ce5538c # v1.15.2
|
|
||||||
with:
|
|
||||||
components: llvm-tools-preview
|
|
||||||
cache-shared-key: setup-rust-${{ runner.os }}-${{ runner.arch }}-${{ hashFiles('**/Cargo.lock') }}
|
|
||||||
|
|
||||||
- name: Install tools
|
|
||||||
uses: taiki-e/install-action@30eab0fabba9ea3f522099957e668b21876aa39e # v2.66.6
|
|
||||||
with:
|
|
||||||
tool: cargo-llvm-cov, cargo-nextest
|
|
||||||
|
|
||||||
- name: Run test
|
|
||||||
if: runner.os != 'Linux'
|
|
||||||
run: |
|
|
||||||
cargo nextest run
|
|
||||||
|
|
||||||
- name: Generate coverage
|
|
||||||
if: runner.os == 'Linux'
|
|
||||||
run: cargo llvm-cov nextest --lcov --output-path lcov.info
|
|
||||||
|
|
||||||
- name: Upload coverage
|
|
||||||
if: runner.os == 'Linux'
|
|
||||||
uses: k1LoW/octocov-action@73d561f65d59e66899ed5c87e4621a913b5d5c20 # v1.5.0
|
|
||||||
with:
|
|
||||||
github-token: ${{ secrets.GITHUB_TOKEN }}
|
|
||||||
34
.github/workflows/dependabot-auto-merge.yaml
vendored
34
.github/workflows/dependabot-auto-merge.yaml
vendored
@@ -1,34 +0,0 @@
|
|||||||
name: Dependabot Auto-merge
|
|
||||||
|
|
||||||
on:
|
|
||||||
pull_request:
|
|
||||||
types:
|
|
||||||
- opened
|
|
||||||
- synchronize
|
|
||||||
- reopened
|
|
||||||
|
|
||||||
permissions:
|
|
||||||
contents: write
|
|
||||||
pull-requests: write
|
|
||||||
|
|
||||||
jobs:
|
|
||||||
dependabot-automation:
|
|
||||||
runs-on: ubuntu-latest
|
|
||||||
if: ${{ github.actor == 'dependabot[bot]' }}
|
|
||||||
timeout-minutes: 13
|
|
||||||
steps:
|
|
||||||
- name: Dependabot metadata
|
|
||||||
id: metadata
|
|
||||||
uses: dependabot/fetch-metadata@21025c705c08248db411dc16f3619e6b5f9ea21a # v2.5.0
|
|
||||||
with:
|
|
||||||
github-token: ${{ secrets.GITHUB_TOKEN }}
|
|
||||||
- name: Approve & enable auto-merge for Dependabot PR
|
|
||||||
if: |
|
|
||||||
steps.metadata.outputs.update-type == 'version-update:semver-patch' ||
|
|
||||||
steps.metadata.outputs.update-type == 'version-update:semver-minor'
|
|
||||||
run: |
|
|
||||||
gh pr merge --auto -s "$PR_URL"
|
|
||||||
env:
|
|
||||||
PR_URL: ${{ github.event.pull_request.html_url }}
|
|
||||||
PR_TITLE: ${{ github.event.pull_request.title }}
|
|
||||||
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
|
|
||||||
134
.github/workflows/release.yaml
vendored
134
.github/workflows/release.yaml
vendored
@@ -1,134 +0,0 @@
|
|||||||
name: Release
|
|
||||||
|
|
||||||
on:
|
|
||||||
push:
|
|
||||||
tags:
|
|
||||||
- 'v*'
|
|
||||||
workflow_dispatch:
|
|
||||||
|
|
||||||
permissions:
|
|
||||||
contents: write
|
|
||||||
|
|
||||||
jobs:
|
|
||||||
build:
|
|
||||||
name: Build - ${{ matrix.target }}
|
|
||||||
strategy:
|
|
||||||
matrix:
|
|
||||||
include:
|
|
||||||
- target: x86_64-unknown-linux-gnu
|
|
||||||
runner: ubuntu-latest
|
|
||||||
os: Linux
|
|
||||||
arch: x86_64
|
|
||||||
ext: tar.gz
|
|
||||||
- target: aarch64-unknown-linux-gnu
|
|
||||||
runner: ubuntu-24.04-arm
|
|
||||||
os: Linux
|
|
||||||
arch: arm64
|
|
||||||
ext: tar.gz
|
|
||||||
- target: x86_64-apple-darwin
|
|
||||||
runner: macos-15-intel
|
|
||||||
os: Darwin
|
|
||||||
arch: x86_64
|
|
||||||
ext: tar.gz
|
|
||||||
- target: aarch64-apple-darwin
|
|
||||||
runner: macos-latest
|
|
||||||
os: Darwin
|
|
||||||
arch: arm64
|
|
||||||
ext: tar.gz
|
|
||||||
- target: x86_64-pc-windows-msvc
|
|
||||||
runner: windows-latest
|
|
||||||
os: Windows
|
|
||||||
arch: x86_64
|
|
||||||
ext: zip
|
|
||||||
runs-on: ${{ matrix.runner }}
|
|
||||||
steps:
|
|
||||||
- name: Checkout
|
|
||||||
uses: actions/checkout@8e8c483db84b4bee98b60c0593521ed34d9990e8 # v6.0.1
|
|
||||||
|
|
||||||
- name: Setup sccache
|
|
||||||
uses: mozilla-actions/sccache-action@7d986dd989559c6ecdb630a3fd2557667be217ad # v0.0.9
|
|
||||||
|
|
||||||
- name: Setup environment variables for sccache
|
|
||||||
shell: bash
|
|
||||||
run: |
|
|
||||||
echo "SCCACHE_GHA_ENABLED=true" >> "$GITHUB_ENV"
|
|
||||||
echo "RUSTC_WRAPPER=sccache" >> "$GITHUB_ENV"
|
|
||||||
|
|
||||||
- name: Setup Rust
|
|
||||||
uses: actions-rust-lang/setup-rust-toolchain@1780873c7b576612439a134613cc4cc74ce5538c # v1.15.2
|
|
||||||
with:
|
|
||||||
rustflags: ""
|
|
||||||
|
|
||||||
- name: Get project name
|
|
||||||
id: project
|
|
||||||
shell: bash
|
|
||||||
run: |
|
|
||||||
name=$(cargo metadata --format-version 1 --no-deps | jq -r '.packages[0].name')
|
|
||||||
echo "name=$name" >> "$GITHUB_OUTPUT"
|
|
||||||
|
|
||||||
- name: Build
|
|
||||||
run: cargo build --release
|
|
||||||
|
|
||||||
- name: Create archive (Unix)
|
|
||||||
if: matrix.os != 'Windows'
|
|
||||||
shell: bash
|
|
||||||
run: |
|
|
||||||
name="${{ steps.project.outputs.name }}"
|
|
||||||
archive_name="${name}_${{ matrix.os }}_${{ matrix.arch }}.tar.gz"
|
|
||||||
tar -czvf "$archive_name" -C target/release "$name"
|
|
||||||
echo "archive_name=$archive_name" >> "$GITHUB_ENV"
|
|
||||||
|
|
||||||
- name: Create archive (Windows)
|
|
||||||
if: matrix.os == 'Windows'
|
|
||||||
shell: pwsh
|
|
||||||
run: |
|
|
||||||
$name = "${{ steps.project.outputs.name }}"
|
|
||||||
$archiveName = "${name}_${{ matrix.os }}_${{ matrix.arch }}.zip"
|
|
||||||
Compress-Archive -Path "target/release/${name}.exe" -DestinationPath $archiveName
|
|
||||||
echo "archive_name=$archiveName" >> $env:GITHUB_ENV
|
|
||||||
|
|
||||||
- name: Upload artifact
|
|
||||||
uses: actions/upload-artifact@b7c566a772e6b6bfb58ed0dc250532a479d7789f # v6.0.0
|
|
||||||
with:
|
|
||||||
name: ${{ steps.project.outputs.name }}_${{ matrix.os }}_${{ matrix.arch }}
|
|
||||||
path: ${{ env.archive_name }}
|
|
||||||
if-no-files-found: error
|
|
||||||
|
|
||||||
release:
|
|
||||||
name: Release
|
|
||||||
needs: build
|
|
||||||
runs-on: ubuntu-latest
|
|
||||||
steps:
|
|
||||||
- name: Checkout
|
|
||||||
uses: actions/checkout@8e8c483db84b4bee98b60c0593521ed34d9990e8 # v6.0.1
|
|
||||||
with:
|
|
||||||
fetch-depth: 0
|
|
||||||
|
|
||||||
- name: Download all artifacts
|
|
||||||
uses: actions/download-artifact@37930b1c2abaa49bbe596cd826c3c89aef350131 # v7.0.0
|
|
||||||
with:
|
|
||||||
path: artifacts
|
|
||||||
merge-multiple: true
|
|
||||||
|
|
||||||
- name: Generate changelog
|
|
||||||
id: changelog
|
|
||||||
run: |
|
|
||||||
# Get the previous tag
|
|
||||||
prev_tag=$(git describe --tags --abbrev=0 HEAD^ 2>/dev/null || echo "")
|
|
||||||
|
|
||||||
if [ -n "$prev_tag" ]; then
|
|
||||||
echo "## Changes since $prev_tag" > changelog.md
|
|
||||||
echo "" >> changelog.md
|
|
||||||
git log --pretty=format:"- %s" "$prev_tag"..HEAD >> changelog.md
|
|
||||||
else
|
|
||||||
echo "## Initial Release" > changelog.md
|
|
||||||
fi
|
|
||||||
|
|
||||||
- name: Create release
|
|
||||||
env:
|
|
||||||
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
|
|
||||||
run: |
|
|
||||||
gh release create "${{ github.ref_name }}" \
|
|
||||||
--title "${{ github.ref_name }}" \
|
|
||||||
--notes-file changelog.md \
|
|
||||||
artifacts/*
|
|
||||||
Reference in New Issue
Block a user