Skip to content

Instantly share code, notes, and snippets.

Embed
What would you like to do?
Install lokalise based on the official guide: https://docs.lokalise.co/api-and-cli/lokalise-cli-tool
#!/usr/bin/env bash
# fail if any commands fails
set -e
# debug log
set -x
# create a temp dir for the "install"
mkdir /tmp/lokalise
# change the "working directory" into that directory
cd /tmp/lokalise
# download the version you want (link is from: https://docs.lokalise.co/api-and-cli/lokalise-cli-tool )
wget -O ./inst.tgz https://s3-eu-west-1.amazonaws.com/lokalise-assets/cli/lokalise-0.44-linux-amd64.tgz
# uncompress -> there's only a single binary in the tgz file called "lokalise"
tar -xvzf ./inst.tgz
# move the binary into PATH so that it can be accessed from "anywhere"
mv ./lokalise /usr/local/bin/lokalise
# DONE, lokalise can now be used from any step/script/tool
# this can be removed, this is just a test that the binary can be executed from any other dir / tool:
cd $HOME
# print its version
lokalise --version
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment