-
Notifications
You must be signed in to change notification settings - Fork 2
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
GH: Add basic GH Actions workflow for code quality #6
Conversation
This repo will probably want to be outfitted with hcp-checks, which includes a linter.
I was going to include the linter, but I imagine this repo should be outfitted with |
I'm going to let @dadgar weigh in before we merge this. |
@briancain lets not use |
.github/workflows/go.yml
Outdated
# Disabling linter for now. Will enable when project is finished, so | ||
# all of the errors can be fixed in a single pass | ||
#- name: golangci-lint | ||
# uses: golangci/golangci-lint-action@v3 | ||
# with: | ||
# # Optional: version of golangci-lint to use in form of v1.2 or v1.2.3 or `latest` to use the latest version | ||
# version: latest | ||
# args: --build-tags="$GOTAGS" --concurrency 2 --timeout 10m |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
There is a make target for the linter we can use: https://github.com/hashicorp/hcp/blob/main/Makefile#L15
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Yep yep, I had added it originally, but the GH runner doesn't have the go tool installed to use that. There should be a way to add it
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I opted to go for the official GH action instead, much easier! Also there are linter errors on this repo so it rightfully is failing right now.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Nice this works! I assume this was the plan but can we delete this comment block then
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Yep! Just pushed a commit to remove this comment block ✨
.github/workflows/go.yml
Outdated
# Disabling linter for now. Will enable when project is finished, so | ||
# all of the errors can be fixed in a single pass | ||
#- name: golangci-lint | ||
# uses: golangci/golangci-lint-action@v3 | ||
# with: | ||
# # Optional: version of golangci-lint to use in form of v1.2 or v1.2.3 or `latest` to use the latest version | ||
# version: latest | ||
# args: --build-tags="$GOTAGS" --concurrency 2 --timeout 10m |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Nice this works! I assume this was the plan but can we delete this comment block then
…a-repo GH: Add basic GH Actions workflow for code quality
Fixes #5