Skip to content
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

feat: Version command for CLI based on release builds #36

Merged
merged 1 commit into from
Aug 31, 2023

Conversation

jpmcb
Copy link
Member

@jpmcb jpmcb commented Aug 28, 2023

Description

This PR adds the version command which displays the release build's version metadata.

With a dummy build, this creates the following metadata into the binary

❯ go build -ldflags="-s -w -X 'github.com/open-sauced/pizza-cli/pkg/utils.Version=1.2.3' -X 'github.com/open-sauced/pizza-cli/pkg/utils.Sha=$(git rev-parse HEAD)'" -o build/pizza

❯ ./build/pizza version
Version: 1.2.3
Sha: 146b6b7485a0f33090a4ccefd23624f9aa0df085

What type of PR is this? (check all applicable)

  • 🍕 Feature
  • 🐛 Bug Fix
  • 📝 Documentation Update
  • 🎨 Style
  • 🧑‍💻 Code Refactor
  • 🔥 Performance Improvements
  • ✅ Test
  • 🤖 Build
  • 🔁 CI
  • 📦 Chore (Release)
  • ⏩ Revert

Related Tickets & Documents

Closes #25

Mobile & Desktop Screenshots/Recordings

N/a

Added tests?

  • 👍 yes
  • 🙅 no, because they aren't needed
  • 🙋 no, because I need help

Added to documentation?

  • 📜 README.md
  • 📓 docs.opensauced.pizza
  • 🍕 dev.to/opensauced
  • 📕 storybook
  • 🙅 no documentation needed

[optional] Are there any post-deployment tasks we need to perform?

N/a

[optional] What gif best describes this PR or how it makes you feel?

@jpmcb jpmcb force-pushed the pizza-version branch 2 times, most recently from a771b3b to 67f5476 Compare August 28, 2023 18:17
@jpmcb jpmcb requested a review from Anush008 August 29, 2023 15:03
@jpmcb jpmcb requested a review from OgDev-01 August 30, 2023 21:26
Signed-off-by: John McBride <john@opensauced.pizza>
@jpmcb jpmcb merged commit 9f3eedc into open-sauced:beta Aug 31, 2023
@jpmcb jpmcb deleted the pizza-version branch August 31, 2023 15:06
github-actions bot pushed a commit that referenced this pull request Aug 31, 2023
## [1.0.0-beta.3](v1.0.0-beta.2...v1.0.0-beta.3) (2023-08-31)

### 🍕 Features

* Version command for CLI based on release builds ([#36](#36)) ([9f3eedc](9f3eedc))
open-sauced bot pushed a commit that referenced this pull request Oct 11, 2023
## 1.0.0 (2023-10-11)

### 🤖 Build System

* sematic bin release, npm ([7b4607e](7b4607e))

### 🔁 Continuous Integration

* Update @open-sauced/release@2.2.1 and compliance.yaml ([#33](#33)) ([146b6b7](146b6b7))

### 🐛 Bug Fixes

* Uses correct generated token when checking out cli repo in release ([#44](#44)) ([1e0c9f1](1e0c9f1))

### 🍕 Features

* Add install instructions and script for pizza CLI ([#26](#26)) ([421a429](421a429))
* Add posthog telemetry integration ([#37](#37)) ([9829f49](9829f49))
* cli auth ([#21](#21)) ([34728fb](34728fb))
* GitHub action to build and upload Go artifacts after release created ([#22](#22)) ([ad187a9](ad187a9))
* Http Client for accessing OpenSauced API client ([#23](#23)) ([ec2b357](ec2b357))
* Leverage the GITHUB_APP_TOKEN for releases ([#32](#32)) ([e0a25e0](e0a25e0))
* npm i -g pizza ([73291d1](73291d1))
* Pizza show ([#24](#24)) ([72f21ce](72f21ce))
* provide repository contributors insights ([#30](#30)) ([d16091f](d16091f))
* provide repository insights ([#38](#38)) ([dc148d6](dc148d6))
* repo-query support ([199cfd7](199cfd7))
* update bin name release.yaml ([6b21cb8](6b21cb8))
* Version command for CLI based on release builds ([#36](#36)) ([9f3eedc](9f3eedc))
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Feature: pizza version
3 participants