jumppad-labs/jumppad

Shipyard Version Manager

nicholasjackson opened this issue · 1 comments

Shipyard should be able to automatically install different versions of itself in order to cater for blueprints which may not have been created with the current version.

Example CLI

T

shipyard version

Current Version: v0.14

Other Versions:
  - v0.13.2
  - v0.12.1

Available Commands:
  list         List installable versions
  install    Install a specific Shipyard version  

Blueprint

Blueprints should have the capability to add SemVer to the front matter. The following example would mark a blueprint as working with a version of Shipyard greater or equal to 0.2.0 and less or equal to 0.32.0.

---
shipyard_version: >= 0.20.0 && <= 0.32.0
---

When a blueprint is run with an incompatible version of Shipyard, the user will be presented with the following UX.

This blueprint is incompatible with your current version of Shipyard.
Blueprint Version:  0.20.0 && <= 0.32.0
Your Version: v0.31.1

Would you like to install a version of Shipyard which can run this blueprint, this action will not replace your current Shipyard version.

[y]

Installing ......

Running blueprint...

If there is a version of Shipyard which can handle this blueprint then it would automatically execute.

Managing Versions

Shipyard will never replace the main version when installing another version, instead it downloads the different version from GitHub and stores it in the Shipyard Home.

- .shipyard
-- versions
   -- v0.13.4
      -- shipyard

Shipyard create a sub process which calls the executable of the other version. Installing a new version does not update the main binary or change any aliases, this ensures compatibility with package managers.

This looks super amazing!

I would also love to have an optio to list all locally installed versions of Shipyard.

This should make it easier to see which versions I have and would likely trigger me to update my blueprints to use as few disparate versions as possible.