diff --git a/.github/workflows/docs.yaml b/.github/workflows/docs.yaml index fccd11f..232a47f 100644 --- a/.github/workflows/docs.yaml +++ b/.github/workflows/docs.yaml @@ -4,6 +4,7 @@ on: push: branches: - master + - main paths: - 'mkdocs.yml' - 'docs/**' @@ -43,7 +44,7 @@ jobs: - name: Deploy uses: peaceiris/actions-gh-pages@v3 - if: ${{ github.ref == 'refs/heads/master' }} + if: ${{ github.ref == 'refs/heads/main' }} with: github_token: ${{ secrets.GITHUB_TOKEN }} publish_dir: ./site diff --git a/Makefile b/Makefile index 2781d96..e5ddc18 100644 --- a/Makefile +++ b/Makefile @@ -29,3 +29,9 @@ build: .PHONY: test test: $(GO) test -v ./... + +.PHONY: docs +docs: + @python3 -m pip install --upgrade pip + @python3 -m pip install -r ./docs/requirements.txt + @python3 -m mkdocs serve diff --git a/docs/getting-started.md b/docs/getting-started.md index c1dd5dd..60496e1 100644 --- a/docs/getting-started.md +++ b/docs/getting-started.md @@ -6,10 +6,33 @@ You can install the pre-compiled binary (in several different ways), compile fro Below you can find the steps for each of them. +### bash script + +bash installer has been provided so you can install afx by running this one command at your own risk. + +=== "Latest" + + ```bash + curl -sL https://raw.githubusercontent.com/b4b4r07/afx/HEAD/hack/install | bash + ``` + +=== "Version" + + ```bash + curl -sL https://raw.githubusercontent.com/b4b4r07/afx/HEAD/hack/install | AFX_VERSION=v0.1.24 bash + ``` + +env | description | default +---|---|--- +`AFX_VERSION` | afx version, available versions are on [releases](https://github.com/b4b4r07/afx/releases) | `latest` +`AFX_BIN_DIR` | Path to install | `~/bin` + ### go install -```sh -$ go install github.com/b4b4r07/afx@latest +For Go developers. + +```bash +go install github.com/b4b4r07/afx@latest ``` ### manually diff --git a/docs/links.md b/docs/links.md index ae9a0fd..26e3a48 100644 --- a/docs/links.md +++ b/docs/links.md @@ -2,7 +2,7 @@ Examples on afx config: -- [b4b4r07/dotfiles](https://github.com/b4b4r07/dotfiles/tree/master/.config/afx) +- [b4b4r07/dotfiles](https://github.com/b4b4r07/dotfiles/tree/HEAD/.config/afx) Similar projects: diff --git a/go.mod b/go.mod index 7f91a95..fa56bdc 100644 --- a/go.mod +++ b/go.mod @@ -11,15 +11,13 @@ require ( github.com/deckarep/golang-set v1.8.0 github.com/fatih/color v1.14.1 github.com/go-playground/validator/v10 v10.11.2 - github.com/goccy/go-yaml v1.10.0 + github.com/goccy/go-yaml v1.9.8 github.com/google/go-cmp v0.5.9 github.com/h2non/filetype v1.1.3 github.com/hashicorp/go-multierror v1.1.1 github.com/hashicorp/go-version v1.6.0 github.com/hashicorp/logutils v1.0.0 github.com/inconshreveable/go-update v0.0.0-20160112193335-8152e7eb6ccf - github.com/k0kubun/pp v3.0.1+incompatible - github.com/k0kubun/pp/v3 v3.2.0 github.com/liggitt/tabwriter v0.0.0-20181228230101-89fcab3d43de github.com/mattn/go-isatty v0.0.17 github.com/mattn/go-shellwords v1.0.12 @@ -51,7 +49,6 @@ require ( github.com/hashicorp/go-retryablehttp v0.7.2 // indirect github.com/inconshreveable/mousetrap v1.0.1 // indirect github.com/jbenet/go-context v0.0.0-20150711004518-d14ea06fba99 // indirect - github.com/k0kubun/colorstring v0.0.0-20150214042306-9440f1994b88 // indirect github.com/kballard/go-shellquote v0.0.0-20180428030007-95032a82bc51 // indirect github.com/kevinburke/ssh_config v0.0.0-20190725054713-01f96b0aa0cd // indirect github.com/leodido/go-urn v1.2.1 // indirect diff --git a/go.sum b/go.sum index 99e7c66..eedb474 100644 --- a/go.sum +++ b/go.sum @@ -55,8 +55,8 @@ github.com/go-playground/universal-translator v0.18.1/go.mod h1:xekY+UJKNuX9WP91 github.com/go-playground/validator/v10 v10.4.1/go.mod h1:nlOn6nFhuKACm19sB/8EGNn9GlaMV7XkbRSipzJ0Ii4= github.com/go-playground/validator/v10 v10.11.2 h1:q3SHpufmypg+erIExEKUmsgmhDTyhcJ38oeKGACXohU= github.com/go-playground/validator/v10 v10.11.2/go.mod h1:NieE624vt4SCTJtD87arVLvdmjPAeV8BQlHtMnw9D7s= -github.com/goccy/go-yaml v1.10.0 h1:rBi+5HGuznOxx0JZ+60LDY85gc0dyIJCIMvsMJTKSKQ= -github.com/goccy/go-yaml v1.10.0/go.mod h1:h/18Lr6oSQ3mvmqFoWmQ47KChOgpfHpTyIHl3yVmpiY= +github.com/goccy/go-yaml v1.9.8 h1:5gMyLUeU1/6zl+WFfR1hN7D2kf+1/eRGa7DFtToiBvQ= +github.com/goccy/go-yaml v1.9.8/go.mod h1:JubOolP3gh0HpiBc4BLRD4YmjEjHAmIIB2aaXKkTfoE= github.com/golang/protobuf v1.3.1/go.mod h1:6lQm79b+lXiMfvg/cZm0SGofjICqVBUtrP5yJMmIC1U= github.com/golang/protobuf v1.3.2/go.mod h1:6lQm79b+lXiMfvg/cZm0SGofjICqVBUtrP5yJMmIC1U= github.com/golang/protobuf v1.5.0/go.mod h1:FsONVRAS9T7sI+LIUmWTfcYkHO4aIWwzhcaSAoJOfIk= @@ -100,13 +100,7 @@ github.com/inconshreveable/mousetrap v1.0.1/go.mod h1:vpF70FUmC8bwa3OWnCshd2FqLf github.com/jbenet/go-context v0.0.0-20150711004518-d14ea06fba99 h1:BQSFePA1RWJOlocH6Fxy8MmwDt+yVQYULKfN0RoTN8A= github.com/jbenet/go-context v0.0.0-20150711004518-d14ea06fba99/go.mod h1:1lJo3i6rXxKeerYnT8Nvf0QmHCRC1n8sfWVwXF2Frvo= github.com/jessevdk/go-flags v1.4.0/go.mod h1:4FA24M0QyGHXBuZZK/XkWh8h0e1EYbRYJSGM75WSRxI= -github.com/k0kubun/colorstring v0.0.0-20150214042306-9440f1994b88 h1:uC1QfSlInpQF+M0ao65imhwqKnz3Q2z/d8PWZRMQvDM= -github.com/k0kubun/colorstring v0.0.0-20150214042306-9440f1994b88/go.mod h1:3w7q1U84EfirKl04SVQ/s7nPm1ZPhiXd34z40TNz36k= github.com/k0kubun/go-ansi v0.0.0-20180517002512-3bf9e2903213/go.mod h1:vNUNkEQ1e29fT/6vq2aBdFsgNPmy8qMdSay1npru+Sw= -github.com/k0kubun/pp v3.0.1+incompatible h1:3tqvf7QgUnZ5tXO6pNAZlrvHgl6DvifjDrd9g2S9Z40= -github.com/k0kubun/pp v3.0.1+incompatible/go.mod h1:GWse8YhT0p8pT4ir3ZgBbfZild3tgzSScAn6HmfYukg= -github.com/k0kubun/pp/v3 v3.2.0 h1:h33hNTZ9nVFNP3u2Fsgz8JXiF5JINoZfFq4SvKJwNcs= -github.com/k0kubun/pp/v3 v3.2.0/go.mod h1:ODtJQbQcIRfAD3N+theGCV1m/CBxweERz2dapdz1EwA= github.com/kballard/go-shellquote v0.0.0-20180428030007-95032a82bc51 h1:Z9n2FFNUXsshfwJMBgNA0RU6/i7WVaAegv3PtuIHPMs= github.com/kballard/go-shellquote v0.0.0-20180428030007-95032a82bc51/go.mod h1:CzGEWj7cYgsdH8dAjBGEr58BoE7ScuLd+fwFZ44+/x8= github.com/kevinburke/ssh_config v0.0.0-20190725054713-01f96b0aa0cd h1:Coekwdh0v2wtGp9Gmz1Ze3eVRAWJMLokvN3QjdzCHLY=