Signed-off-by: Simon Heather <32168619+X-Guardian@users.noreply.github.com>
Co-authored-by: Copilot Autofix powered by AI <62310815+github-advanced-security[bot]@users.noreply.github.com>
* Add initial Gitea client structure
* Add various missing config flags
* initial gitea support added
* Fix some post-merge issues
* Replace HidePrevCommandComments by version from @florianbeisel
* Update mocks
* feat: add Webhook Signature Verification
This changes adds support for Gitea Webhook Signatures by wrapping the
function from the Gitea SDK and calling it from `handleGiteaPost()`.
* fix: use release version in go.mod
1.22 as in the previous go.mod is a development version. When referencing
a minimum release version the correct format is 1.22.0
* Set default Gitea url to cloud.gitea.com
* Fix and Add tests for Gitea
* Fix missing copyright header
* Changed comment to reflect no max comment length
Apparently there's no max comment length in Gitea at this point in time.
* Implement GetCloneURL()
* Decode Base64 before passing on downloaded file content
* Enable Gitea client as API Client
* Remove unneded comments
* Remove old redundant file
* fix: invalid version number in go.mod
* fix: remove unnecessary type conversions
* fix: removed unused function
* fix: remove unnecessary type conversion of decodedData
* fix: fixes some tests
* Correct gitea.com URL
* Add Gitea to website docs
* fix: TestPost_UnsupportedGiteaEvent
* revert version downgrades
* docs: add Gitea documentation to Guide section
* docs: fix copy paste mistake
* Update cmd/server_test.go
Co-authored-by: nitrocode <7775707+nitrocode@users.noreply.github.com>
* Clarify usage msg for --gitea-base-url
* Apply suggestions from code review
Co-authored-by: nitrocode <7775707+nitrocode@users.noreply.github.com>
* Turn ebreak number into const with comments
* Add --gitea-page-size server argument
Defaults to 30 based on https://docs.gitea.com/1.18/advanced/config-cheat-sheet#api-api
* Fix broken test
* Fix event parser and comment parser
* Add missing app permission to docs
* Make Gitea client conform to updated interface
* Update server/events/vcs/gitea/client.go
Co-authored-by: Simon Heather <32168619+X-Guardian@users.noreply.github.com>
* Remove no longer needed logger
* Add extra logging statements for Gitea client
* Add debug statements
---------
Co-authored-by: Florian Beisel <florian@pacey.me>
Co-authored-by: Florian Beisel <florian@beisel.it>
Co-authored-by: PePe Amengual <jose.amengual@gmail.com>
Co-authored-by: nitrocode <7775707+nitrocode@users.noreply.github.com>
Co-authored-by: Rui Chen <rui@chenrui.dev>
Co-authored-by: Simon Heather <32168619+X-Guardian@users.noreply.github.com>
* fix(deps): update module github.com/google/go-github/v57 to v58 in go.mod
* Update remaining go-github to v58
---------
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
Co-authored-by: Luke Massa <lmassa@tripadvisor.com>
* Fix Hide Previous Plan Comments
* Update GitLab client tests
* Update GitLab client test
* Update github client test
* Add nolint: errcheck to test
* format github_client.go
* Running 'atlantis unlock' on a PR Causes The Whole Working Directory to be Deleted
* Update events controller tests
* Fix events controller tests
---------
Co-authored-by: PePe Amengual <jose.amengual@gmail.com>
* fix: Previous implementation tried to do comment parsing inside github, and only worked for 'atlantis' command.
This commit improves on that to make it possible to implement reactions in other VCS providers and also reuse the existing comment parsing.
* test: Add negative test to confirm reactions are not added for invalid comments
* test: Add a negative test to confirm invalid commands do not get a reaction
* feat: Basic implementation of github reactions on PRs
Adds eyes whenever it detects an `atlantis` command.
* feat: Make the emoji reaction configurable
* tests: Add a mocked test for EmojiReaction being called in github
* ci: Disable revive linter for stubs
* Adding check for Azure DevOps Test Webhook URL so they aren't processed like real events
* feat: customize vcs comment command executable name
* Altering case on isAzureDevOpsTestRepoURL function
* Altering case on URL parameter
* Altering checks to ensure all Azure DevOps Ignore tests pass
* Extending setup method to support Azure DevOps
* Fixing issue from merge conflict error
* gofmt
* Adding null checks to Test URL checks
* moving azuredevopsTestUrl to const
* Changing azuredevopsTestUrl to azuredevopsTestURL
* Cleaning up return statement
Co-authored-by: Ken Kaizu <k.kaizu38@gmail.com>
---------
Co-authored-by: Ken Kaizu <k.kaizu38@gmail.com>
Co-authored-by: nitrocode <7775707+nitrocode@users.noreply.github.com>
* Adding GetIsDeleted
* Adding test to see if ADO sucessfully passes all ignore statements
* Changing Ignore Passing test to use matcher
* Changing to use setup method
* Adding a check for deleted comments in AzureDevOps event handler
* adding test for ignoring azure devops deleted comments
Co-authored-by: PePe Amengual <jose.amengual@gmail.com>
The io/ioutil package has been deprecated as of Go 1.16, see
https://golang.org/doc/go1.16#ioutil. This commit replaces the existing
io/ioutil functions with their new definitions in io and os packages.
Signed-off-by: Eng Zer Jun <engzerjun@gmail.com>