Skip to content

Commit

Permalink
Rel 0.2.9 / make py versinoing flexible
Browse files Browse the repository at this point in the history
  • Loading branch information
David-OConnor committed Nov 21, 2020
1 parent aa5a6fd commit 6285091
Show file tree
Hide file tree
Showing 7 changed files with 68 additions and 12 deletions.
2 changes: 1 addition & 1 deletion CHANGELOG.md
@@ -1,7 +1,7 @@
# Changelog

## v0.2.9
- Added Python 3.9 support
- Pyflow no longer requires updates to use future versions of python.

## v0.2.8
- Fixed some warnings, and check status codes of every subprocess
Expand Down
2 changes: 1 addition & 1 deletion Cargo.lock

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion Cargo.toml
@@ -1,6 +1,6 @@
[package]
name = "pyflow"
version = "0.2.8"
version = "0.2.9"
authors = ["David O'Connor <david.alan.oconnor@gmail.com>"]
description = "A modern Python installation and dependency manager"
license = "MIT"
Expand Down
16 changes: 8 additions & 8 deletions README.md
Expand Up @@ -32,22 +32,22 @@ and [Pep 518 (pyproject.toml)](https://www.python.org/dev/peps/pep-0518/).

## Installation
- **Windows** - Download and run
[this installer](https://github.com/David-OConnor/pyflow/releases/download/0.2.8/pyflow-0.2.8-x86_64.msi).
[this installer](https://github.com/David-OConnor/pyflow/releases/download/0.2.9/pyflow-0.2.9-x86_64.msi).
Or, if you have [Scoop](https://scoop.sh) installed, run `scoop install pyflow`.

- **Ubuntu, or another Os that uses Snap** - Run `snap install pyflow --classic`.

- **Ubuntu or Debian without Snap** - Download and run
[this deb](https://github.com/David-OConnor/pyflow/releases/download/0.2.8/pyflow_0.2.8_amd64.deb).
[this deb](https://github.com/David-OConnor/pyflow/releases/download/0.2.9/pyflow_0.2.9_amd64.deb).

- **Fedora, CentOs, RedHat, or older versions of SUSE** - Download and run
[this rpm](https://github.com/David-OConnor/pyflow/releases/download/0.2.8/pyflow-0.2.8.x86_64.rpm).
[this rpm](https://github.com/David-OConnor/pyflow/releases/download/0.2.9/pyflow-0.2.9.x86_64.rpm).

- **A different Linux distro** - Download this
[standalone binary](https://github.com/David-OConnor/pyflow/releases/download/0.2.8/pyflow)
[standalone binary](https://github.com/David-OConnor/pyflow/releases/download/0.2.9/pyflow)
and place it somewhere accessible by the PATH. For example, `/usr/bin`.

- **Mac** - Download this [zipped Mac binary](https://github.com/David-OConnor/pyflow/releases/download/0.2.8/pyflow_mac_0.2.8.zip)
- **Mac** - Download this [zipped Mac binary](https://github.com/David-OConnor/pyflow/releases/download/0.2.9/pyflow_mac_0.2.9.zip)
, ance place the file in it somewhere accessible by the PATH. (Props to @russeldavis for building this)

- **With Pip** - Run `pip install pyflow`. The linux install using this method is much larger than
Expand Down Expand Up @@ -190,7 +190,7 @@ Example contents:
[tool.pyflow]
py_version = "3.7"
name = "runcible"
version = "0.2.8"
version = "0.2.9"
authors = ["John Hackworth <jhackworth@vic.org>"]

[tool.pyflow.dependencies]
Expand Down Expand Up @@ -372,7 +372,7 @@ In order to build and publish your project, additional info is needed in
[tool.pyflow]
name = "everythingkiller"
py_version = "3.6"
version = "0.2.8"
version = "0.2.9"
authors = ["Fraa Erasmas <raz@edhar.math>"]
description = "Small, but packs a punch!"
homepage = "https://everything.math"
Expand All @@ -395,7 +395,7 @@ activate = "jeejah:activate"

[tool.pyflow.dependencies]
numpy = "^1.16.4"
manimlib = "0.2.8"
manimlib = "0.2.9"
ipython = {version = "^7.7.0", extras=["qtconsole"]}


Expand Down
15 changes: 15 additions & 0 deletions RELEASE_CHECKLIST.md
Expand Up @@ -43,3 +43,18 @@ users, and binaries built on other OSes appear not to work on these due to OpenS
1. Add a release on [Github](https://github.com/David-OConnor/seed/releases), following the format of previous releases.
1. Upload the following binaries to the release page: zipped Windows binary (This is all `Scoop` needs),
Linux binary, Msi, Deb, Rpm.



Note on buildling python binaries for the Pybin repo:
## Windows:
Install, copy the file from Appdata/Local/programs/python,
and match the filename/compression format with existing entries

## Linux:
Download source. Run these:
```bash
./configure --prefix=$HOME/python_built
make
sudo make install
```
2 changes: 1 addition & 1 deletion snapcraft.yaml
@@ -1,5 +1,5 @@
name: pyflow
version: 0.2.8
version: 0.2.9
license: MIT # todo: This appears to cause the `snapcraft` command to fail.
summary: A Python installation and dependency manager.
description: |
Expand Down
41 changes: 41 additions & 0 deletions src/py_versions.rs
Expand Up @@ -11,6 +11,9 @@ use std::{fmt, fs, io, path::Path, path::PathBuf};
/// Only versions we've built and hosted
#[derive(Clone, Copy, Debug)]
enum PyVers {
V3_12_0, // unreleased
V3_11_0, // unreleased
V3_10_0, // unreleased
V3_9_0, // either Os
V3_8_0, // either Os
V3_7_4, // Either Os
Expand Down Expand Up @@ -80,6 +83,34 @@ impl From<(Version, Os)> for PyVers {
unreachable!()
}
},
9 => match v_o.1 {
Os::Windows | Os::Ubuntu | Os::Centos => Self::V3_9_0,
_ => {
abort_helper("3.9", "Mac");
unreachable!()
}
},
10 => match v_o.1 {
Os::Windows | Os::Ubuntu | Os::Centos => Self::V3_10_0,
_ => {
abort_helper("3.10", "Mac");
unreachable!()
}
},
11 => match v_o.1 {
Os::Windows | Os::Ubuntu | Os::Centos => Self::V3_11_0,
_ => {
abort_helper("3.11", "Mac");
unreachable!()
}
},
12 => match v_o.1 {
Os::Windows | Os::Ubuntu | Os::Centos => Self::V3_12_0,
_ => {
abort_helper("3.12", "Mac");
unreachable!()
}
},
_ => {
util::abort(unsupported);
unreachable!()
Expand All @@ -91,6 +122,9 @@ impl From<(Version, Os)> for PyVers {
impl ToString for PyVers {
fn to_string(&self) -> String {
match self {
Self::V3_12_0 => "3.12.0".into(),
Self::V3_11_0 => "3.11.0".into(),
Self::V3_10_0 => "3.10.0".into(),
Self::V3_9_0 => "3.9.0".into(),
Self::V3_8_0 => "3.8.0".into(),
Self::V3_7_4 => "3.7.4".into(),
Expand All @@ -106,6 +140,9 @@ impl ToString for PyVers {
impl PyVers {
fn to_vers(self) -> Version {
match self {
Self::V3_12_0 => Version::new(3, 12, 0),
Self::V3_11_0 => Version::new(3, 11, 0),
Self::V3_10_0 => Version::new(3, 10, 0),
Self::V3_9_0 => Version::new(3, 9, 0),
Self::V3_8_0 => Version::new(3, 8, 0),
Self::V3_7_4 => Version::new(3, 7, 4),
Expand Down Expand Up @@ -421,6 +458,10 @@ pub fn create_venv(
#[cfg(target_os = "linux")]
{
match py_ver.unwrap().minor {
12 => py_name += ".12",
11 => py_name += ".11",
10 => py_name += ".10",
9 => py_name += ".9",
8 => py_name += ".8",
7 => py_name += ".7",
6 => py_name += ".6",
Expand Down

0 comments on commit 6285091

Please sign in to comment.