incu6us / goimports-reviser

Right imports sorting & code formatting tool (goimports alternative)
MIT License
607 stars 72 forks source link

Could not support mac m1 (arm) #72

Closed azureskies closed 2 years ago

azureskies commented 2 years ago

MacBook-Pro librdkafka % brew tap incu6us/homebrew-tap brew install incu6us/homebrew-tap/goimports-reviser ==> Tapping incu6us/tap Cloning into '/opt/homebrew/Library/Taps/incu6us/homebrew-tap'... remote: Enumerating objects: 172, done. remote: Counting objects: 100% (172/172), done. remote: Compressing objects: 100% (127/127), done. remote: Total 172 (delta 41), reused 0 (delta 0), pack-reused 0 Receiving objects: 100% (172/172), 21.90 KiB | 3.13 MiB/s, done. Resolving deltas: 100% (41/41), done. Error: Invalid formula: /opt/homebrew/Library/Taps/incu6us/homebrew-tap/Formula/goimports-reviser.rb formulae require at least a URL Error: Cannot tap incu6us/tap: invalid syntax in tap! ==> Tapping incu6us/tap Cloning into '/opt/homebrew/Library/Taps/incu6us/homebrew-tap'... remote: Enumerating objects: 172, done. remote: Counting objects: 100% (172/172), done. remote: Compressing objects: 100% (127/127), done. remote: Total 172 (delta 41), reused 0 (delta 0), pack-reused 0 Receiving objects: 100% (172/172), 21.90 KiB | 3.13 MiB/s, done. Resolving deltas: 100% (41/41), done. Error: Invalid formula: /opt/homebrew/Library/Taps/incu6us/homebrew-tap/Formula/goimports-reviser.rb formulae require at least a URL Error: Cannot tap incu6us/tap: invalid syntax in tap!

zhuxubin01 commented 2 years ago

the same problem

james-d-elliott commented 2 years ago

Try go install github.com/incu6us/goimports-reviser/v2@latest and then try to run it from the bin folder of the GOPATH?

daregod commented 2 years ago

A package installed this way does not support the -version flag

daregod commented 2 years ago

A package installed this way does not support the -version flag

Ok, this can be solved with GOBIN=/usr/local/bin go install -ldflags="-X 'main.Tag=v2.5.1'" github.com/incu6us/goimports-reviser/v2@v2.5.1

azureskies commented 2 years ago

A package installed this way does not support the -version flag

Ok, this can be solved with GOBIN=/usr/local/bin go install -ldflags="-X 'main.Tag=v2.5.1'" github.com/incu6us/goimports-reviser/v2@v2.5.1

Nice it works for me, thank you very much.