Trendyol Tech
Published in

Trendyol Tech

https://github.com/goreleaser/goreleaser/blob/939f2b002b29d2c8df6efd2d1f1d0b85c4ac5ee0/www/docs/static/logo.png

The fanciest way of releasing Go binaries with GoReleaser 😎

Release Go projects as fast and easily as possible!
https://goreleaser.com

  • 🙅🏻‍♂️ Cross-compile your Go project (Darwin, Linux, Windows) automatically
  • 🚀 Release your project to GitHub, GitLab, and Gitea
  • 📦 Build and Push Docker images, also supports multi-platform Docker images with Docker manifests
  • 💬 Announce new releases on Twitter, Slack, Discord and Microsoft Teams, and many more…
$ goreleaser init
• Generating .goreleaser.yml file
• config created; please edit accordingly to your needs file=.goreleaser.yml
$ vim .goreleaser.yml # after editing save the changes
$ goreleaser check # check the sy
$ git tag -a v0.1.0 -m "My First Release"
$ export GITLAB_TOKEN=""
$ goreleaser release --rm-dist # test with --skip-publish --snapshot
and BOOM!🚀🚀
  1. But, first, how can we use GoReleaser as part of the CI/CD solution (GitLab, in this case)?
  2. How can we distribute our Go binaries for three types of OSs (Linux, Darwin, Windows) using GitLab Releases?
  3. How can we build and push container images to the GitLab Container Registry?
https://gist.github.com/developer-guy/07f8227edfb026de56f2d2f4ea2c7228
https://gist.github.com/developer-guy/30b524339aff44a6c595047fe8a4c65a
https://gist.github.com/developer-guy/c71e1a82387ecf6f2d99d770a67a8b8d
https://gist.github.com/developer-guy/12bd5d1ad53bc02ea6ebf124c382c25b
https://gist.github.com/developer-guy/1accbae945e7216b2faa930f17980746
https://gist.github.com/developer-guy/d3056b6d29e1137e989deb012fe45dbe
https://gist.github.com/developer-guy/c73e5f003193ba120438c15ad0a75cd8

Conclusion

--

--

Get the Medium app

A button that says 'Download on the App Store', and if clicked it will lead you to the iOS App store
A button that says 'Get it on, Google Play', and if clicked it will lead you to the Google Play store
developer-guy

🇹🇷KCD Turkey Organizer🎖Best Sigstore Evangelist🐦SSCS Twitter Community Admin✍️@chainguard_dev Fan📦Container Addict📅Organizer at @cloudnativetr•@devopstr