-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
* feat: IsHelpCmd * fix: test job name * fix: lint errors * fix: lint errors * fix: lint errors * fix: lint errors * fix: lint errors * fix: lint errors
- Loading branch information
Showing
25 changed files
with
398 additions
and
1,049 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,45 @@ | ||
name: Bug Report | ||
description: Tell us about a problem you are experiencing | ||
labels: [bug, triage] | ||
assignees: | ||
- shipengqi | ||
body: | ||
- type: markdown | ||
attributes: | ||
value: | | ||
Thanks for taking the time to fill out this bug report! Please fill the form below. | ||
- type: textarea | ||
id: what-happened | ||
attributes: | ||
label: What happened? | ||
description: Also tell us, what did you expect to happen? | ||
validations: | ||
required: true | ||
- type: textarea | ||
id: reproducible | ||
attributes: | ||
label: How can we reproduce this? | ||
description: Please share a public repository that reproduces the issue, or an example config file. | ||
validations: | ||
required: true | ||
- type: textarea | ||
id: golib-version | ||
attributes: | ||
label: golib version | ||
render: bash | ||
validations: | ||
required: true | ||
- type: checkboxes | ||
id: search | ||
attributes: | ||
label: Search | ||
options: | ||
- label: I did search for other open and closed issues before opening this | ||
required: true | ||
- type: textarea | ||
id: ctx | ||
attributes: | ||
label: Additional context | ||
description: Anything else you would like to add | ||
validations: | ||
required: false |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1 @@ | ||
blank_issues_enabled: false |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,38 @@ | ||
name: Feature Request | ||
description: Request a new feature and/or enhancement to an existing feature | ||
labels: [enhancement, triage] | ||
assignees: | ||
- shipengqi | ||
body: | ||
- type: markdown | ||
attributes: | ||
value: | | ||
Thanks for taking the time to fill out this feature request! Please fill the form below. | ||
- type: textarea | ||
id: is-it-a-problem | ||
attributes: | ||
label: Is your feature request related to a problem? Please describe. | ||
description: A clear and concise description of what the problem is. Ex. I'm always frustrated when [...] | ||
validations: | ||
required: true | ||
- type: textarea | ||
id: solution | ||
attributes: | ||
label: Describe the solution you'd like | ||
description: A clear and concise description of what you want to happen. | ||
validations: | ||
required: true | ||
- type: checkboxes | ||
id: search | ||
attributes: | ||
label: Search | ||
options: | ||
- label: I did search for other open and closed issues before opening this | ||
required: true | ||
- type: textarea | ||
id: ctx | ||
attributes: | ||
label: Additional context | ||
description: Anything else you would like to add | ||
validations: | ||
required: false |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,28 @@ | ||
# Works with https://github.com/actions/labeler/ | ||
# Below this line, the keys are labels to be applied, and the values are the file globs to match against. | ||
# Anything in the `design` directory gets the `Design` label. | ||
design: | ||
- design/* | ||
|
||
example: | ||
- example/* | ||
- examples/* | ||
|
||
documentation: | ||
- docs/**/* | ||
|
||
dependencies: | ||
- go.mod | ||
- go.sum | ||
|
||
hack: | ||
- hack/* | ||
|
||
unit-tests: | ||
- "pkg/**/*_test.go" | ||
- "cmd/**/*_test.go" | ||
- "config/**/*_test.go" | ||
- "internal/**/*_test.go" | ||
|
||
e2e-tests: | ||
- "test/e2e/**/*" |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,11 @@ | ||
Thank you for contributing to golib! | ||
|
||
# Please add a summary of your change | ||
|
||
# Does your change fix a particular issue? | ||
|
||
Fixes #(issue) | ||
|
||
**Check list:** | ||
- [ ] Mark if documentation changes are required. | ||
- [ ] Mark if tests were added or updated to cover the changes. |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,21 @@ | ||
name: "Auto Label" | ||
# pull_request_target means that this will run on pull requests, but in the context of the base repo. | ||
# This should mean PRs from forks are supported. | ||
# Because it includes the `synchronize` parameter, any push of a new commit to the HEAD ref of a pull request | ||
# will trigger this process. | ||
|
||
on: | ||
pull_request_target: | ||
types: [opened, reopened, synchronize, ready_for_review] | ||
|
||
jobs: | ||
# Automatically labels PRs based on file globs in the change. | ||
triage: | ||
runs-on: ubuntu-latest | ||
permissions: | ||
contents: read | ||
pull-requests: write | ||
steps: | ||
- uses: actions/labeler@v4 | ||
with: | ||
repo-token: ${{ secrets.PAT }} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,12 @@ | ||
name: dependency-review | ||
on: [pull_request] | ||
permissions: | ||
contents: read | ||
jobs: | ||
dependency-review: | ||
runs-on: ubuntu-latest | ||
steps: | ||
- uses: actions/checkout@v3 | ||
- uses: actions/dependency-review-action@v3 | ||
with: | ||
allow-licenses: BSD-2-Clause, BSD-3-Clause, MIT, Apache-2.0, MPL-1.0, MPL-1.1, MPL-2.0 |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,18 @@ | ||
name: gitleaks | ||
on: | ||
push: | ||
branches: ['main'] | ||
tags: ['v*'] | ||
pull_request: | ||
permissions: | ||
contents: read | ||
jobs: | ||
gitleaks: | ||
runs-on: ubuntu-latest | ||
steps: | ||
- uses: actions/checkout@v3 | ||
with: | ||
fetch-depth: 0 | ||
- uses: gitleaks/gitleaks-action@v2 | ||
env: | ||
GITHUB_TOKEN: ${{ secrets.PAT }} |
This file was deleted.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,20 @@ | ||
name: "grype" | ||
on: | ||
push: | ||
branches: ['main'] | ||
tags: ['v*'] | ||
pull_request: | ||
jobs: | ||
scan-source: | ||
name: scan-source | ||
runs-on: ubuntu-latest | ||
permissions: | ||
security-events: write | ||
actions: read | ||
contents: read | ||
steps: | ||
- uses: actions/checkout@v3 | ||
- uses: anchore/scan-action@v3 | ||
with: | ||
path: "." | ||
fail-build: true |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,32 @@ | ||
name: golangci-lint | ||
on: | ||
push: | ||
tags: | ||
- v* | ||
branches: | ||
- main | ||
pull_request: | ||
permissions: | ||
contents: read | ||
|
||
jobs: | ||
golangci: | ||
strategy: | ||
matrix: | ||
go: [ '1.20', '1.21' ] | ||
os: [ ubuntu-latest, windows-latest ] | ||
permissions: | ||
contents: read # for actions/checkout to fetch code | ||
pull-requests: read # for golangci/golangci-lint-action to fetch pull requests | ||
name: lint | ||
runs-on: ubuntu-latest | ||
steps: | ||
- uses: actions/checkout@v3 | ||
- uses: actions/setup-go@v4 | ||
with: | ||
go-version: stable # get the latest stable version from the go-versions repository manifest. | ||
cache: false | ||
- name: golangci-lint | ||
uses: golangci/golangci-lint-action@v3 | ||
with: | ||
args: --timeout=10m |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,22 @@ | ||
name: Close inactive issues | ||
on: | ||
schedule: | ||
- cron: "30 1 * * *" | ||
|
||
jobs: | ||
close-issues: | ||
runs-on: ubuntu-latest | ||
permissions: | ||
issues: write | ||
pull-requests: write | ||
steps: | ||
- uses: actions/stale@v5 | ||
with: | ||
days-before-issue-stale: 30 | ||
days-before-issue-close: 14 | ||
stale-issue-label: "stale" | ||
stale-issue-message: "This issue is stale because it has been open for 30 days with no activity." | ||
close-issue-message: "This issue was closed because it has been inactive for 14 days since being marked as stale." | ||
days-before-pr-stale: -1 | ||
days-before-pr-close: -1 | ||
repo-token: ${{ secrets.PAT }} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,24 @@ | ||
name: test | ||
|
||
on: | ||
push: | ||
branches: [ main ] | ||
pull_request: | ||
branches: [ main ] | ||
|
||
jobs: | ||
unit-test: | ||
runs-on: ubuntu-latest | ||
steps: | ||
- uses: actions/checkout@v3 | ||
- uses: actions/setup-go@v4 | ||
with: | ||
go-version: stable | ||
- name: unit test | ||
run: CI=true go test -v -coverprofile=coverage.out ./... | ||
- name: codecov | ||
uses: codecov/codecov-action@v3 | ||
with: | ||
flags: unittests | ||
fail_ci_if_error: true | ||
files: coverage.out |
Oops, something went wrong.