From 05bd9f3198b37c0ae577b652cfe9b8977d5b92ad Mon Sep 17 00:00:00 2001 From: Mateusz Urbanek Date: Wed, 2 Aug 2023 11:00:02 +0200 Subject: [PATCH] fix: streamlined names Signed-off-by: Mateusz Urbanek --- .github/labels.yaml | 4 ++ .github/workflows/conventional-changelog.yaml | 10 ----- .github/workflows/conventional-commit.yaml | 2 +- .github/workflows/labels.yaml | 43 ++++++++++--------- .github/workflows/linters.yaml | 4 +- .github/workflows/tests.yaml | 4 +- README.md | 8 ++++ renovate.json | 3 +- 8 files changed, 41 insertions(+), 37 deletions(-) diff --git a/.github/labels.yaml b/.github/labels.yaml index dc5ad32..7fc5700 100644 --- a/.github/labels.yaml +++ b/.github/labels.yaml @@ -1,3 +1,7 @@ +area/dependency: + name: area/dependency + color: '#0052cc' + description: Issues or PRs related to dependency changes. good first issue: name: good first issue color: '#7057ff' diff --git a/.github/workflows/conventional-changelog.yaml b/.github/workflows/conventional-changelog.yaml index 1848202..3995fbc 100644 --- a/.github/workflows/conventional-changelog.yaml +++ b/.github/workflows/conventional-changelog.yaml @@ -17,25 +17,15 @@ jobs: name: Generate changelog and publish a release runs-on: ubuntu-latest steps: - - name: Check if this is full release - id: check-tag - run: | - regex='^(v)(0|[1-9]\d*)\.(0|[1-9]\d*)\.(0|[1-9]\d*)(?:\+([0-9a-zA-Z-]+(?:\.[0-9a-zA-Z-]+)*))?$' - if echo ${{ github.ref_name }} | grep -qE $regex ; then - echo "match=true" >> $GITHUB_OUTPUT - fi - name: Checkout Code - if: steps.check-tag.outputs.match == 'true' uses: actions/checkout@v3 - name: Update CHANGELOG id: changelog - if: steps.check-tag.outputs.match == 'true' uses: requarks/changelog-action@v1 with: token: ${{ github.token }} tag: ${{ github.ref_name }} - name: Create Release - if: steps.check-tag.outputs.match == 'true' uses: ncipollo/release-action@v1.12.0 with: allowUpdates: true diff --git a/.github/workflows/conventional-commit.yaml b/.github/workflows/conventional-commit.yaml index 0890db4..b28b53d 100644 --- a/.github/workflows/conventional-commit.yaml +++ b/.github/workflows/conventional-commit.yaml @@ -4,7 +4,7 @@ # OR # - pull request is open to the main; -name: Lint commit messages +name: Conventional commit on: push: diff --git a/.github/workflows/labels.yaml b/.github/workflows/labels.yaml index 9f386c5..e4fd3ae 100644 --- a/.github/workflows/labels.yaml +++ b/.github/workflows/labels.yaml @@ -1,4 +1,4 @@ -name: Upload labels +name: Labels on: push: @@ -13,25 +13,26 @@ env: jobs: upload-labels: + name: Upload labels runs-on: ubuntu-latest steps: - - uses: actions/checkout@v3 - with: - fetch-depth: 0 - - id: labels-changed - run: | - if git diff --name-only HEAD~1 HEAD | grep -q ".github/labels.yaml"; then - echo "changed=true" >> $GITHUB_OUTPUT - else - echo "changed=false" >> $GITHUB_OUTPUT - fi - - uses: actions/setup-go@v4 - if: steps.labels-changed.outputs.changed == 'true' - with: - go-version: '1.20' - - if: steps.labels-changed.outputs.changed == 'true' - run: go install github.com/shanduur/labeler/cmd/labeler@main - - if: steps.labels-changed.outputs.changed == 'true' - run: labeler upload --owner ${{ env.OWNER }} --repo ${{ env.REPO }} ./.github/labels.yaml - env: - LABELER_TOKEN: ${{ secrets.LABELER_TOKEN }} + - uses: actions/checkout@v3 + with: + fetch-depth: 0 + - id: labels-changed + run: | + if git diff --name-only HEAD~1 HEAD | grep -q ".github/labels.yaml"; then + echo "changed=true" >> $GITHUB_OUTPUT + else + echo "changed=false" >> $GITHUB_OUTPUT + fi + - uses: actions/setup-go@v4 + if: steps.labels-changed.outputs.changed == 'true' + with: + go-version: '1.20' + - if: steps.labels-changed.outputs.changed == 'true' + run: go install github.com/shanduur/labeler/cmd/labeler@main + - if: steps.labels-changed.outputs.changed == 'true' + run: labeler upload --owner ${{ env.OWNER }} --repo ${{ env.REPO }} ./.github/labels.yaml + env: + LABELER_TOKEN: ${{ secrets.LABELER_TOKEN }} diff --git a/.github/workflows/linters.yaml b/.github/workflows/linters.yaml index 2ad1c11..971c04e 100644 --- a/.github/workflows/linters.yaml +++ b/.github/workflows/linters.yaml @@ -1,7 +1,7 @@ # This workflow run linters. # It is supposed to be run on each push to main branch, as well as for each. -name: linters +name: Linters on: push: @@ -14,7 +14,7 @@ permissions: jobs: golangci-lint: - name: golangci-lint + name: Run golangci-lint runs-on: ubuntu-latest steps: - uses: actions/checkout@v3 diff --git a/.github/workflows/tests.yaml b/.github/workflows/tests.yaml index 8a87a62..14b636f 100644 --- a/.github/workflows/tests.yaml +++ b/.github/workflows/tests.yaml @@ -1,7 +1,7 @@ # This workflow run tests. # It is supposed to be run on each push to main branch, as well as for each. -name: tests +name: Tests on: push: @@ -14,7 +14,7 @@ permissions: jobs: tests: - name: run tests and upload coverage report + name: Run tests and upload coverage report runs-on: ubuntu-latest steps: - uses: actions/checkout@v3 diff --git a/README.md b/README.md index 51476d1..4c3e5d5 100644 --- a/README.md +++ b/README.md @@ -1,5 +1,13 @@ # must +[![Contributor Covenant](https://img.shields.io/badge/Contributor%20Covenant-2.1-4baaaa.svg)](CODE_OF_CONDUCT.md) [![GitHub](https://img.shields.io/github/license/doomshrine/must)](LICENSE.txt) +[![Go Report Card](https://goreportcard.com/badge/github.com/doomshrine/must)](https://goreportcard.com/report/github.com/doomshrine/must) +[![codecov](https://codecov.io/gh/doomshrine/must/branch/main/graph/badge.svg?token=6MH0T7CI24)](https://codecov.io/gh/doomshrine/must) +[![GitHub Workflow Status (with event)](https://img.shields.io/github/actions/workflow/status/doomshrine/must/tests.yaml)](https://github.com/shanduur/must/actions/workflows/tests.yaml) `must` is a dead simple library that includes (for now) single function - Do. + +## Contributing + +You want to contibute? Hop into the [CONTRIBUTING.md](CONTRIBUTING.md) and find how you can help the project! diff --git a/renovate.json b/renovate.json index afdfacc..b2c9f46 100644 --- a/renovate.json +++ b/renovate.json @@ -3,5 +3,6 @@ "extends": [ "config:base" ], - "automerge": true + "automerge": true, + "labels": [ "area/dependency" ] }