Prepare application for GitHub Action#31
Merged
Merged
Conversation
Such images are published when new release is created:
- "mszostok/codeowners-validator:latest"
- "mszostok/codeowners-validator:v{{ .Major }}.{{ .Minor }}.{{ .Patch}}"
- "mszostok/codeowners-validator:v{{ .Major }}.{{ .Minor }}"
Thanks to that the binary size is reduced from ~10MB to ~1.9MB for each platform.
When the .gitingore has no new line thet the ignored pattern was added in the same line and it was not applied by git, so we had false negative.
This feature was need as the GitHub Actions are injecting envs with `INPUT` prefix, e.g. INPUT_CHECKS.
491d2e3 to
8eadaa6
Compare
Change requires also repository name. Because of that the `OWNER_CHECKER_ORGANIZATION_NAME` env was replaced by `OWNER_CHECKER_REPOSITORY`. More information in README.md file. Previously we used: https://developer.github.com/v3/teams/#list-teams Now we are using such query: https://developer.github.com/v3/repos/#list-teams As a result we reduce numbers of queries.
8eadaa6 to
e1a1d13
Compare
This file contains hidden or 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
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Description
Changes proposed in this pull request:
Add support for building docker images
Such images are published when new release is created:
mszostok/codeowners-validator:latestmszostok/codeowners-validator:v{{ .Major }}.{{ .Minor }}.{{ .Patch}}mszostok/codeowners-validator:v{{ .Major }}.{{ .Minor }}Add images compression by
upx --bruteThanks to that the binary size is reduced from ~10MB to ~1.9MB for each platform.
Fix not owned file checker
When the .gitingore has no new line then the ignored pattern was added in the same line and it was not applied by git, so we had false negative.
Add support for defining env prefix
This feature was need as the GitHub Actions are injecting envs with
INPUTprefix, e.g. INPUT_CHECKS.Change requires also repository name. Because of that the
OWNER_CHECKER_ORGANIZATION_NAMEenv was replaced byOWNER_CHECKER_REPOSITORY. More information in README.md file.Previously we used: https://developer.github.com/v3/teams/#list-teams
Now we are using such query: https://developer.github.com/v3/repos/#list-teams