diff --git a/.github/workflows/main.yml b/.github/workflows/main.yml index 060bd9860..7f31c0e20 100644 --- a/.github/workflows/main.yml +++ b/.github/workflows/main.yml @@ -5,25 +5,6 @@ on: name: Main jobs: - docs: - name: 'Build Docs' - runs-on: ubuntu-latest - steps: - - uses: actions/checkout@v2 - with: - token: ${{ secrets.NUMARY_GITHUB_TOKEN }} - - run: | - wget https://github.com/swaggo/swag/releases/download/v1.7.4/swag_1.7.4_Linux_x86_64.tar.gz - tar -zxvf swag_1.7.4_Linux_x86_64.tar.gz - - run: ./swag init - - uses: actions/upload-artifact@v2 - with: - name: docs-dist - path: ./docs/** - - uses: stefanzweifel/git-auto-commit-action@v4 - with: - commit_message: "[skip ci] Update docs" - file_pattern: docs/docs.go docs/*.go build_control: name: 'Build Control' runs-on: ubuntu-latest @@ -46,7 +27,6 @@ jobs: name: 'Build' needs: - build_control - - docs runs-on: ${{ matrix.os }} strategy: matrix: @@ -78,11 +58,6 @@ jobs: with: name: control-dist path: cmd/control/ - - name: fetch docs - uses: actions/download-artifact@v2 - with: - name: docs-dist - path: docs/ - name: OSXCross for CGO Support if: matrix.os == 'ubuntu-latest' run: | diff --git a/.github/workflows/pr_open.yml b/.github/workflows/pr_open.yml index c677ff1f5..001e45f03 100644 --- a/.github/workflows/pr_open.yml +++ b/.github/workflows/pr_open.yml @@ -3,19 +3,6 @@ on: pull_request: types: [assigned, opened, synchronize, reopened] jobs: - docs: - name: 'Build Docs' - runs-on: ubuntu-latest - steps: - - uses: actions/checkout@v2 - - run: | - wget https://github.com/swaggo/swag/releases/download/v1.7.4/swag_1.7.4_Linux_x86_64.tar.gz - tar -zxvf swag_1.7.4_Linux_x86_64.tar.gz - - run: ./swag init - - uses: actions/upload-artifact@v2 - with: - name: docs-dist - path: ./docs/** build_control: name: 'Build Control' runs-on: ubuntu-latest @@ -39,7 +26,6 @@ jobs: runs-on: ubuntu-latest needs: - build_control - - docs steps: - uses: actions/setup-go@v2 with: @@ -69,7 +55,6 @@ jobs: runs-on: ubuntu-latest needs: - build_control - - docs services: postgres: image: postgres:13-alpine @@ -111,103 +96,6 @@ jobs: NUMARY_STORAGE_POSTGRES_CONN_STRING: "postgresql://ledger:ledger@127.0.0.1/ledger" - name: Upload coverage to Codecov run: bash <(curl -s https://codecov.io/bash) -# Bench_sqlite: -# name: 'Bench - SQLite' -# runs-on: ubuntu-latest -# needs: -# - build_control -# - docs -# steps: -# - uses: actions/setup-go@v2 -# with: -# go-version: '1.16' -# - uses: actions/checkout@v2 -# - uses: actions/cache@v2 -# with: -# path: | -# ~/.cache/go-build -# ~/go/pkg/mod -# key: ${{ runner.os }}-go-${{ hashFiles('**/go.sum') }} -# restore-keys: | -# ${{ runner.os }}-go- -# - name: get deps -# run: go mod download -# - name: fetch numary control -# uses: actions/download-artifact@v2 -# with: -# name: control-dist -# path: cmd/control/ -# - name: run benchs -# run: go test -bench=Benchmark -run=^a ./... | tee output.txt -# - name: Store benchmark result -# uses: benchmark-action/github-action-benchmark@v1 -# with: -# name: Leger Bench for SQLite -# tool: 'go' -# output-file-path: output.txt -# fail-on-alert: true -# github-token: ${{ secrets.GITHUB_TOKEN }} -# comment-on-alert: true -# benchmark-data-dir-path: dev/bench-sqlite -# auto-push: false -# comment-always: true -# Bench_postgres: -# name: 'Bench - PostgreSQL' -# runs-on: ubuntu-latest -# needs: -# - build_control -# - docs -# services: -# postgres: -# image: postgres:13-alpine -# env: -# POSTGRES_USER: ledger -# POSTGRES_PASSWORD: ledger -# POSTGRES_DB: ledger -# ports: -# - 5432:5432 -# options: >- -# --health-cmd pg_isready -# --health-interval 10s -# --health-timeout 5s -# --health-retries 5 -# steps: -# - uses: actions/setup-go@v2 -# with: -# go-version: '1.16' -# - uses: actions/checkout@v2 -# - uses: actions/cache@v2 -# with: -# path: | -# ~/.cache/go-build -# ~/go/pkg/mod -# key: ${{ runner.os }}-go-${{ hashFiles('**/go.sum') }} -# restore-keys: | -# ${{ runner.os }}-go- -# - name: get deps -# run: go mod download -# - name: fetch numary control -# uses: actions/download-artifact@v2 -# with: -# name: control-dist -# path: cmd/control/ -# - name: run tests -# run: go test -bench=Benchmark -run=^a ./... | tee output.txt -# env: -# NUMARY_STORAGE_DRIVER: "postgres" -# NUMARY_STORAGE_POSTGRES_CONN_STRING: "postgresql://ledger:ledger@127.0.0.1/ledger" -# - name: Store benchmark result -# uses: benchmark-action/github-action-benchmark@v1 -# with: -# name: Leger Bench for PostgreSQL -# tool: 'go' -# output-file-path: output.txt -# fail-on-alert: true -# github-token: ${{ secrets.GITHUB_TOKEN }} -# comment-on-alert: true -# benchmark-data-dir-path: dev/bench-pgsql -# auto-push: false -# comment-always: true Lint: name: 'Lint' runs-on: ubuntu-latest @@ -266,11 +154,6 @@ jobs: with: name: control-dist path: cmd/control/ - - name: fetch docs - uses: actions/download-artifact@v2 - with: - name: docs-dist - path: docs/ - name: OSXCross for CGO Support if: matrix.os == 'ubuntu-latest' run: | diff --git a/.github/workflows/release.yml b/.github/workflows/release.yml index 22f050972..cb33de771 100644 --- a/.github/workflows/release.yml +++ b/.github/workflows/release.yml @@ -5,19 +5,6 @@ on: permissions: contents: write jobs: - docs: - name: 'Build Docs' - runs-on: ubuntu-latest - steps: - - uses: actions/checkout@v2 - - run: | - wget https://github.com/swaggo/swag/releases/download/v1.7.4/swag_1.7.4_Linux_x86_64.tar.gz - tar -zxvf swag_1.7.4_Linux_x86_64.tar.gz - - run: ./swag init - - uses: actions/upload-artifact@v2 - with: - name: docs-dist - path: ./docs/** build_control: name: 'Build Control' runs-on: ubuntu-latest @@ -40,7 +27,6 @@ jobs: name: 'Build Binary' needs: - build_control - - docs runs-on: ${{ matrix.os }} strategy: matrix: @@ -68,11 +54,6 @@ jobs: with: name: control-dist path: cmd/control/ - - name: fetch docs - uses: actions/download-artifact@v2 - with: - name: docs-dist - path: docs/ - name: OSXCross for CGO Support if: matrix.os == 'ubuntu-latest' run: | @@ -97,7 +78,6 @@ jobs: runs-on: ubuntu-latest needs: - build_control - - docs steps: - uses: actions/checkout@v2 - name: fetch numary control @@ -105,11 +85,6 @@ jobs: with: name: control-dist path: cmd/control/ - - name: fetch docs - uses: actions/download-artifact@v2 - with: - name: docs-dist - path: docs/ - name: Set up QEMU uses: docker/setup-qemu-action@v1 - name: Set up Docker Buildx diff --git a/.gitignore b/.gitignore index 39b471cb4..cdc07224c 100644 --- a/.gitignore +++ b/.gitignore @@ -4,7 +4,5 @@ coverage.out cmd/control/* !cmd/control/gitkeep .DS_Store -docs/swagger.json -docs/swagger.yaml .idea vendor