diff --git a/.goreleaser.yml b/.goreleaser.yml index 3808fd1..8a091a3 100644 --- a/.goreleaser.yml +++ b/.goreleaser.yml @@ -1,33 +1,54 @@ +builds: + - goos: + - darwin + - linux + - windows +archives: + - format: zip brews: - - tap: + - name: aztx + url_template: "https://github.com/riweston/aztx/releases/download/{{ .Tag }}/{{ .ArtifactName }}" + repository: owner: riweston name: homebrew-aztx - # Optionally a token can be provided, if it differs from the token provided to GoReleaser token: "{{ .Env.HOMEBREW }}" - url_template: "https://github.com/riweston/aztx/releases/download/{{ .Tag }}/{{ .ArtifactName }}" commit_author: name: goreleaserbot email: goreleaser@riweston.io homepage: "https://github.com/riweston/aztx" description: "This tool is a helper for azure-cli that leverages fzf for a nice interface to switch between subscription contexts." - license: "Apache" + license: "MIT" dependencies: - name: azure-cli - name: fzf -builds: - - goos: - - darwin - - linux - - windows -scoop: - bucket: - owner: riweston - name: scoop-bucket - token: "{{ .Env.HOMEBREW }}" - url_template: "https://github.com/riweston/aztx/releases/download/{{ .Tag }}/{{ .ArtifactName }}" - commit_author: - name: goreleaserbot - email: goreleaser@riweston.io - homepage: "https://github.com/riweston/aztx" - description: "This tool is a helper for azure-cli that leverages fzf for a nice interface to switch between subscription contexts." - license: "Apache" +scoops: + - name: aztx + url_template: "https://github.com/riweston/aztx/releases/download/{{ .Tag }}/{{ .ArtifactName }}" + repository: + owner: riweston + name: scoop-bucket + token: "{{ .Env.HOMEBREW }}" + commit_author: + name: goreleaserbot + email: goreleaser@riweston.io + homepage: "https://github.com/riweston/aztx" + description: "This tool is a helper for azure-cli that leverages fzf for a nice interface to switch between subscription contexts." + license: "MIT" + depends: + - azure-cli + - fzf +winget: + - name: aztx + url_template: "https://github.com/riweston/aztx/releases/download/{{ .Tag }}/{{ .ArtifactName }}" + package_identifier: "riweston.aztx" + repository: + owner: riweston + name: winget-aztx + token: "{{ .Env.HOMEBREW }}" + commit_author: + name: goreleaserbot + email: goreleaser@riweston.io + homepage: "https://github.com/riweston/aztx" + short_description: "This tool is a helper for azure-cli that leverages fzf for a nice interface to switch between subscription contexts." + license: "MIT" + publisher: "Richard Weston" diff --git a/README.md b/README.md index 7e1f24a..2365a73 100644 --- a/README.md +++ b/README.md @@ -1,86 +1,63 @@ -

aztx

-

- Version - - - Documentation - - - Maintenance - - - License: MIT - -

+## README This tool is a helper for azure-cli that leverages fzf for a nice interface to switch between subscription contexts. -Additionally it can also be used to quickly switch back to a previous subscription context using the `aztx -` command in a similar way to `cd -` in bash. +Additionally, it can also be used to quickly switch back to a previous subscription context using the `aztx -` command in a similar way to `cd -` in bash. -### 🏠 [Homepage](https://github.com/riweston/aztx#readme) - -### ✨ Demo +### Demo [![asciicast](https://asciinema.org/a/Rk36acdIGN9K6w5WO5Rx74NwA.svg)](https://asciinema.org/a/Rk36acdIGN9K6w5WO5Rx74NwA) -## Prerequisites +### Prerequisites + +> [!NOTE] +> This tool is built on top of the azure-cli and fzf and requires them to be installed and configured. +> If you use the Brew or Scoop package managers, these pre-requisites should be handled during the installation. - go >=1.16.6 - azure-cli >= 2.22.1 - fzf >= 0.20.0 -## Install +### Installation Options -### Brew (Linux/Mac) +#### [Brew](https://brew.sh/) (Mac/Linux) ```sh -brew tap riweston/aztx -brew install aztx +$ brew tap riweston/aztx +$ brew install aztx ``` -### Scoop (Windows) +#### [Scoop](https://scoop.sh/) (Windows) ```sh -scoop bucket add riweston https://github.com/riweston/scoop-bucket.git -scoop update -scoop install riweston/aztx +$ scoop bucket add riweston https://github.com/riweston/scoop-bucket.git +$ scoop update +$ scoop install riweston/aztx ``` -### Manual +#### Download a prebuilt binary (Linux/Mac/Windows) -Grab a release from the repo and install it. +Download the latest release from the [releases page](https://github.com/riweston/aztx/releases) and add it to your PATH. -### Build from source +#### Install from source (Linux/Mac/Windows) ```sh -go install github.com/riweston/aztx +$ go install github.com/riweston/aztx ``` ## Usage ```sh -aztx +# Run the tool in interactive mode +$ aztx +# Switch back to the previous subscription context +$ aztx - +Switched to "Test Subscription 1" (xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx) +# Switch back again to the previous subscription context +$ aztx - +Switched to "Test Subscription 2" (yyyyyyyy-yyyy-yyyy-yyyy-yyyyyyyyyyyy) ``` -## Author - -👤 **Richard Weston** - -* Github: [@riweston](https://github.com/riweston) -* LinkedIn: [@riweston](https://linkedin.com/in/riweston) - -## 🤝 Contributing - -Contributions, issues and feature requests are welcome!
Feel free to check [issues page](https://github.com/riweston/aztx/issues). - -## Show your support +### Show your support Give a ⭐️ if this project helped you! - -## 📝 License - -Copyright © 2021 [Richard Weston](https://github.com/riweston).
-This project is [MIT](https://github.com/riweston/aztx/blob/master/LICENSE) licensed. - -*** -_This README was generated with ❤️ by [readme-md-generator](https://github.com/kefranabg/readme-md-generator)_