The previous version has four ways to install:
- Package managers:
- 🌱 Mint. Allows selecting any git reference, cloning it, and building Rugby from
source code. There are two disadvantages. First of all, users should have the right Xcode
version and CLT. It’s not so convenient. Sometimes users have to use older Xcode versions.
And it also limits me from upgrading to the latest version and using the newest features
for development. The second problem is I’m not ready to publish the source code of the new version; - 🍺 Brew. Allows downloading only the latest Rugby binary and only from the default branch.
It’s not suitable for the distribution of pre-release versions. And users can’t get the previous
version if the latest one is broken.
- 🌱 Mint. Allows selecting any git reference, cloning it, and building Rugby from
- W/o package managers:
- 📑 Source. Everybody can clone any git reference without package managers and build Rugby from
the source. There is only one problem — I’m not ready to share the source code of the new version 😅; - 📦 Binary. Everybody can download a zip file, unarchive it and use the Rugby binary.
It’s pretty easy, but still, users have to call a bunch of commands, like adding Rugby location
to the$PATH
environment variable.
- 📑 Source. Everybody can clone any git reference without package managers and build Rugby from
I thought about all these options and decided that there should be a better way to install Rugby.
And I found it. Maybe it’s not ideal, but it’s good enough.
It’s all about downloading binary. The first-time users should install it manually, and after that,
they can use the new command rugby update
for Rugby self-updating. It’s similar to the package manager,
but it's right inside Rugby.
Select your architecture: arm64
or x86_64
. Run the five commands below. I described them in points 1-5:
- Create and change the current directory to
~/.rugby/clt/downloads
(recommended); - Download the specific version of Rugby. E.g.
2.0.0
; - Unzip archive;
- Copy binary from
~/.rugby/clt/downloads/rugby
to~/.rugby/clt
; - Add Rugby path to your
$PATH
environment variable. After this call you can userugby
in your
terminal without passing the whole path~/.rugby/clt
. You need to open a new window or tab in terminal.
mkdir -p ~/.rugby/clt/downloads && cd ~/.rugby/clt/downloads
x86_64 (Intel)
curl -LO https://github.com/swiftyfinch/Rugby/releases/download/2.0.0/x86_64.zip
unzip x86_64.zip
arm64 (M1+)
curl -LO https://github.com/swiftyfinch/Rugby/releases/download/2.0.0/arm64.zip
unzip arm64.zip
cp rugby ~/.rugby/clt
echo '\nexport PATH=$PATH:~/.rugby/clt' >> ~/.zshrc
Open a new window or tab in terminal.
How to keep the first Rugby version (e.g. during beta)
Instead of adding the path to your $PATH
environment variable in the 5th point, use an alias like rugby2
.
echo '\nalias rugby2="~/.rugby/clt/rugby"' >> ~/.zshenv
Open a new window or tab in terminal.
If you already have Rugby, which version is at least 2.0.0b2
, you can use such a command.
But it will work only if you install rugby to ~/.rugby/clt/rugby
path as I recommended above.
Getting the latest version including pre-release ones:
rugby update --beta
If you want to install a specific version:
rugby update --version 2.0.0
If you want to find out which versions are available:
rugby update list
🚀 I hope you successfully installed Rugby!
Contact me if you have any questions.
Now, you can find more information in > Commands Help 📚.
If you used the previous version, there is > Migration Guide 🚏.