Skip to content

Instantly share code, notes, and snippets.

@mottosso
Created June 12, 2019 09:49
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save mottosso/b402b63733af027186993d88603ac304 to your computer and use it in GitHub Desktop.
Save mottosso/b402b63733af027186993d88603ac304 to your computer and use it in GitHub Desktop.
11th June 2019 - Ticking Boxes pt. 3

The saga continues, the next issue with Scoop was installing Python 2.7, which it considers not python-2.7, but rather python27 which to Rez is not the same.


Scoop Versions

Scoop doesn't store more than 1 version of each app, which is problematic. To account for this, it hosts a separate repository of packages called Versions, where you'll find packages like python27 and python35. Basically to fill in for the missing notion of versions.

As it happens, to really be complete, we'll need both Python 2 and 3 and therefore must support this additional bucket and poor naming convention.

It took some effort, but I eventually got there.

$ rez env scoopz -- install python27
Initialising Scoop... ok - 0.03s
Reading package lists... ok - 22.29s
Parsing Scoop apps... ok - 0.00s
Discovering existing packages... ok - 0.00s
The following NEW packages will be installed:
  python    2.7.16  platform-windows/arch-AMD64
Packages will be installed to C:\Users\manima\packages
After this operation, 57.83 mb will be used.
Do you want to continue? [Y/n] y
(1/1) Installing python-2.7.16.. ok
Successfully installed 1 packages
Cleaning up.. ok

$ rez env python-2 -- python --version
Python 2.7.16

This, despite the Scoop package being called python27 ends up as a python-2.7.16 Rez package. Win.

The remaining challenge now is doing the same for Linux and yum, but that's for another day! What's important we now have the method and workflow for packaging system-software with Rez.

And with that, we've got Python as-a-package and our environments identical across machines (and continents!).


Powershell

I then had an idea for how to enhance the interactivity from the terminal by integrating Powershell.

These will provide some interesting benefits, like as tab-completion and colors, along with the extensibility of being a fully-fledged scripting (and in fact, programming) language that is C#.


Tomorrow

Ticking boxes? :)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment