Skip to content

Commit

Permalink
Update the CLI version on pushes to homebrew
Browse files Browse the repository at this point in the history
  • Loading branch information
trasch committed Aug 7, 2024
1 parent 5d53983 commit aa05ec5
Show file tree
Hide file tree
Showing 3 changed files with 6 additions and 1 deletion.
4 changes: 4 additions & 0 deletions .github/workflows/homebrew.yml
Original file line number Diff line number Diff line change
Expand Up @@ -15,6 +15,10 @@ jobs:
- uses: actions/checkout@v3
with:
ref: ${{ inputs.tag_name }}
- name: Update the CLI version
run: echo "public let cliVersion = \"${CLI_VERSION}\"" > Sources/MVTCLI/Version.swift
env:
CLI_VERSION: ${{ inputs.tag_name }}
- name: Build the executable for release
run: swift build -c release --arch arm64 --arch x86_64 --product mvt
- name: Compress the archive
Expand Down
2 changes: 1 addition & 1 deletion Sources/MVTCLI/CLI.swift
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@ struct CLI: AsyncParsableCommand {
static let configuration = CommandConfiguration(
commandName: "mvt",
abstract: "A utility for inspecting and working with vector tiles.",
version: "1.5.0",
version: cliVersion,
subcommands: [Dump.self, Info.self, Merge.self, Query.self, Export.self, Import.self],
defaultSubcommand: Dump.self)

Expand Down
1 change: 1 addition & 0 deletions Sources/MVTCLI/Version.swift
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
public let cliVersion = "v1.7.0"

0 comments on commit aa05ec5

Please sign in to comment.