Skip to content

Commit 66ff560

Browse files
Alexey Boykoketchoop
Alexey Boyko
authored andcommitted
Closes #11
1 parent f4628c3 commit 66ff560

File tree

5 files changed

+25
-4
lines changed

5 files changed

+25
-4
lines changed

.goreleaser.yml

+15
Original file line numberDiff line numberDiff line change
@@ -12,6 +12,11 @@ builds:
1212
- darwin
1313
- linux
1414

15+
archives:
16+
- files:
17+
- configs/autocomplete/*
18+
- LICENSE
19+
1520
checksum:
1621
name_template: 'checksums.txt'
1722
algorithm: sha256
@@ -28,9 +33,19 @@ brews:
2833
caveats: "flora --help"
2934
homepage: "https://github.com/ketchoop/flora"
3035
description: "Allows to manage and switch between multiple terraform versions"
36+
conflicts:
37+
- terraform
3138
custom_block: |
3239
head "https://github.com/ketchoop/flora.git"
3340
test: |
3441
system "#{bin}/flora", "--help"
3542
install: |
43+
case File.basename(ENV["SHELL"])
44+
when "zsh"
45+
zsh_completion.install "configs/autocomplete/flora_zsh_autocomplete" => "_flora"
46+
when "bash"
47+
url "https://raw.githubusercontent.com/ketchoop/flora/master/configs/autocomplete/flora_bash_autocomplete"
48+
bash_completion.install "configs/autocomplete/flora_bash_autocomplete" => "_flora"
49+
end
50+
3651
bin.install "flora"

README.md

+8-2
Original file line numberDiff line numberDiff line change
@@ -17,15 +17,21 @@ compatible with your **.tf manifests** Terraform binary.
1717

1818
## Install
1919

20+
1. By *brew install*
21+
```
22+
brew install ketchoop/homebrew-tap/flora
23+
24+
mkdir -p ~/flora/.bin
25+
```
2026

21-
1. By *go get*
27+
2. By *go get*
2228
```
2329
go get -u github.com/ketchoop/flora/cmd/flora
2430
2531
mkdir -p ~/flora/.bin
2632
```
2733

28-
2. By install.sh
34+
3. By install.sh
2935
```
3036
curl https://raw.githubusercontent.com/ketchoop/flora/master/install.sh | bash
3137
```

install.sh

+2-2
Original file line numberDiff line numberDiff line change
@@ -16,14 +16,14 @@ function install_autocompletion() {
1616
local zsh_autocomplete_path="/usr/local/share/zsh/site-functions"
1717

1818
pushd "$zsh_autocomplete_path" > /dev/null
19-
curl -sL "https://raw.githubusercontent.com/ketchoop/flora/master/configs/autocomplete/flora_zsh_autcomplete" -o _flora
19+
curl -sL "https://raw.githubusercontent.com/ketchoop/flora/master/configs/autocomplete/flora_zsh_autocomplete" -o _flora
2020
popd
2121
;;
2222
bash)
2323
local bash_autocomplete_path="/etc/bash_completion.d"
2424

2525
pushd "$bash_autocomplete_path" > /dev/null
26-
curl -sLO "https://raw.githubusercontent.com/ketchoop/flora/master/configs/autocomplete/flora_bash_autcomplete"
26+
curl -sLO "https://raw.githubusercontent.com/ketchoop/flora/master/configs/autocomplete/flora_bash_autocomplete"
2727
popd
2828
;;
2929
esac

0 commit comments

Comments
 (0)