Skip to content

Commit

Permalink
Merge pull request #69 from SylvainCorlay/minimamba
Browse files Browse the repository at this point in the history
Mambaforge!
  • Loading branch information
isuruf authored Dec 6, 2020
2 parents 82e82f8 + 14711fb commit 88a8a86
Show file tree
Hide file tree
Showing 6 changed files with 114 additions and 13 deletions.
66 changes: 64 additions & 2 deletions .github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -14,63 +14,125 @@ jobs:
MINIFORGE_NAME: "Miniforge3"
OS_NAME: "Windows"

- os: windows-latest
ARCH: x86_64
MINIFORGE_NAME: "Mambaforge"
OS_NAME: "Windows"

- os: macos-latest
ARCH: arm64
MINIFORGE_NAME: "Miniforge3"
OS_NAME: "MacOSX"

- os: macos-latest
ARCH: arm64
MINIFORGE_NAME: "Mambaforge"
OS_NAME: "MacOSX"

- os: macos-latest
ARCH: x86_64
MINIFORGE_NAME: "Miniforge-pypy3"
OS_NAME: "MacOSX"

- os: macos-latest
ARCH: x86_64
MINIFORGE_NAME: "Mambaforge-pypy3"
OS_NAME: "MacOSX"

- os: macos-latest
ARCH: x86_64
MINIFORGE_NAME: "Miniforge3"
OS_NAME: "MacOSX"

- os: macos-latest
ARCH: x86_64
MINIFORGE_NAME: "Mambaforge"
OS_NAME: "MacOSX"

- os: ubuntu-latest
ARCH: aarch64
DOCKER_ARCH: arm64v8
DOCKERIMAGE: condaforge/linux-anvil-aarch64
MINIFORGE_NAME: "Miniforge3"
OS_NAME: "Linux"

- os: ubuntu-latest
ARCH: aarch64
DOCKER_ARCH: arm64v8
DOCKERIMAGE: condaforge/linux-anvil-aarch64
MINIFORGE_NAME: "Mambaforge"
OS_NAME: "Linux"

- os: ubuntu-latest
ARCH: x86_64
DOCKER_ARCH: amd64
DOCKERIMAGE: condaforge/linux-anvil-comp7
MINIFORGE_NAME: "Miniforge3"
OS_NAME: "Linux"

- os: ubuntu-latest
ARCH: x86_64
DOCKER_ARCH: amd64
DOCKERIMAGE: condaforge/linux-anvil-comp7
MINIFORGE_NAME: "Mambaforge"
OS_NAME: "Linux"

- os: ubuntu-latest
ARCH: ppc64le
DOCKER_ARCH: ppc64le
DOCKERIMAGE: condaforge/linux-anvil-ppc64le
MINIFORGE_NAME: "Miniforge3"
OS_NAME: "Linux"

- os: ubuntu-latest
ARCH: ppc64le
DOCKER_ARCH: ppc64le
DOCKERIMAGE: condaforge/linux-anvil-ppc64le
MINIFORGE_NAME: "Mambaforge"
OS_NAME: "Linux"

- os: ubuntu-latest
ARCH: aarch64
DOCKER_ARCH: arm64v8
DOCKERIMAGE: condaforge/linux-anvil-aarch64
MINIFORGE_NAME: "Miniforge-pypy3"
OS_NAME: "Linux"

- os: ubuntu-latest
ARCH: aarch64
DOCKER_ARCH: arm64v8
DOCKERIMAGE: condaforge/linux-anvil-aarch64
MINIFORGE_NAME: "Mambaforge-pypy3"
OS_NAME: "Linux"

- os: ubuntu-latest
ARCH: x86_64
DOCKER_ARCH: amd64
DOCKERIMAGE: condaforge/linux-anvil-comp7
MINIFORGE_NAME: "Miniforge-pypy3"
OS_NAME: "Linux"

- os: ubuntu-latest
ARCH: x86_64
DOCKER_ARCH: amd64
DOCKERIMAGE: condaforge/linux-anvil-comp7
MINIFORGE_NAME: "Mambaforge-pypy3"
OS_NAME: "Linux"

- os: ubuntu-latest
ARCH: ppc64le
DOCKER_ARCH: ppc64le
DOCKERIMAGE: condaforge/linux-anvil-ppc64le
MINIFORGE_NAME: "Miniforge-pypy3"
OS_NAME: "Linux"

- os: ubuntu-latest
ARCH: ppc64le
DOCKER_ARCH: ppc64le
DOCKERIMAGE: condaforge/linux-anvil-ppc64le
MINIFORGE_NAME: "Mambaforge-pypy3"
OS_NAME: "Linux"

steps:
- name: Checkout code
uses: actions/checkout@v2
Expand Down Expand Up @@ -100,8 +162,8 @@ jobs:
EXT=sh
fi
if [[ "$OS_NAME" == "Windows" ]]; then
source /c/Miniconda3/Scripts/activate
bash build_miniforge_win.sh
source /c/Miniconda3/Scripts/activate;
source build_miniforge_win.sh;
EXT=exe
fi
# Copy for latest release
Expand Down
11 changes: 8 additions & 3 deletions Miniforge3/construct.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -19,12 +19,17 @@ keep_pkgs: True
license_file: ../LICENSE

specs:
{% if name == "Miniforge3" %}
{% if name.endswith("pypy3") %}
- python 3.6.* *_pypy
{% else %}
- python 3.8.* # [not (osx and arm64)]
- python 3.9.* # [osx and arm64]
{% elif name == "Miniforge-pypy3" %}
- python 3.6.* *_pypy
{% endif %}

{% if name.startswith("Mambaforge") %}
- mamba
{% endif %}
- conda {{ version.split("-")[0] }}

- pip
- bzip2
22 changes: 20 additions & 2 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -30,7 +30,25 @@ Latest installers with pypy3.6 in the base environment
- [`linux-x86_64`](https://github.com/conda-forge/miniforge/releases/latest/download/Miniforge-pypy3-Linux-x86_64.sh)
- [`osx-x86_64`](https://github.com/conda-forge/miniforge/releases/latest/download/Miniforge-pypy3-MacOSX-x86_64.sh)

Follow the `aarch64` and `ppc64le` migration status here: https://conda-forge.org/status/
#### Mambaforge

Latest installers with mamba in the base environment

- [`linux-aarch64`](https://github.com/conda-forge/miniforge/releases/latest/download/Mambaforge-Linux-aarch64.sh) (also called `arm64`)
- [`linux-ppc64le`](https://github.com/conda-forge/miniforge/releases/latest/download/Mambaforge-Linux-ppc64le.sh) (also called `POWER8/9`)
- [`linux-x86_64`](https://github.com/conda-forge/miniforge/releases/latest/download/Mambaforge-Linux-x86_64.sh) (also called `amd64`)
- [`osx-x86_64`](https://github.com/conda-forge/miniforge/releases/latest/download/Mambaforge-MacOSX-x86_64.sh)
- [`osx-arm64`](https://github.com/conda-forge/miniforge/releases/latest/download/Mambaforge-MacOSX-arm64.sh) (Apple Silicon)
- [`win-x86_64`](https://github.com/conda-forge/miniforge/releases/latest/download/Mambaforge-Windows-x86_64.exe)

#### Mambaforge-pypy3

Latest installers with mamba and pypy3.6 in the base environment

- [`linux-aarch64`](https://github.com/conda-forge/miniforge/releases/latest/download/Mambaforge-pypy3-Linux-aarch64.sh)
- [`linux-ppc64le`](https://github.com/conda-forge/miniforge/releases/latest/download/Mambaforge-pypy3-Linux-ppc64le.sh)
- [`linux-x86_64`](https://github.com/conda-forge/miniforge/releases/latest/download/Mambaforge-pypy3-Linux-x86_64.sh)
- [`osx-x86_64`](https://github.com/conda-forge/miniforge/releases/latest/download/Mambaforge-pypy3-MacOSX-x86_64.sh)

## Install

Expand Down Expand Up @@ -92,7 +110,7 @@ To release a new version of Miniforge:
1. One installer with the version name
2. One installer without the version name
3. The SHA256
- At the time of writing, the is a sum of 27 artifacts, and with the two sources, we expect a grand total of 29 artifacts.
- At the time of writing, the is a sum of 60 artifacts, and with the two sources, we expect a grand total of 62 artifacts.
- Mark the pre-release as a release

NOTE: using a pre-release is important to make sure the latest links work.
Expand Down
4 changes: 2 additions & 2 deletions build_miniforge_win.sh
Original file line number Diff line number Diff line change
@@ -1,3 +1,3 @@
conda install posix --yes
scripts/build.sh
scripts/test.sh
source scripts/build.sh
source scripts/test.sh
16 changes: 13 additions & 3 deletions scripts/build.sh
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,11 @@ pip install git+git://github.com/conda/constructor@8c0121d3b81846de42973b52f1313
conda list

echo "***** Make temp directory *****"
TEMP_DIR=$(mktemp -d)
if [[ "$(uname)" == MINGW* ]]; then
TEMP_DIR=$(mktemp -d --tmpdir=C:/Users/RUNNER~1/AppData/Local/Temp/);
else
TEMP_DIR=$(mktemp -d);
fi

echo "***** Copy file for installer construction *****"
cp -R Miniforge3 $TEMP_DIR/
Expand All @@ -41,8 +45,13 @@ constructor $TEMP_DIR/Miniforge3/ --output-dir $TEMP_DIR $EXTRA_CONSTRUCTOR_ARGS

echo "***** Generate installer hash *****"
cd $TEMP_DIR
# This line ill break if there is more than one installer in the folder.
INSTALLER_PATH=$(find . -name "Miniforge*.sh" -or -name "Miniforge*.exe" | head -n 1)
if [[ "$(uname)" == MINGW* ]]; then
EXT=exe;
else
EXT=sh;
fi
# This line will break if there is more than one installer in the folder.
INSTALLER_PATH=$(find . -name "M*forge*.$EXT" | head -n 1)
HASH_PATH="$INSTALLER_PATH.sha256"
sha256sum $INSTALLER_PATH > $HASH_PATH

Expand All @@ -52,3 +61,4 @@ mv $INSTALLER_PATH $CONSTRUCT_ROOT/build/
mv $HASH_PATH $CONSTRUCT_ROOT/build/

echo "***** Done: Building Miniforge installer *****"
cd $CONSTRUCT_ROOT
8 changes: 7 additions & 1 deletion scripts/test.sh
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,13 @@ CONSTRUCT_ROOT="${CONSTRUCT_ROOT:-$PWD}"
cd ${CONSTRUCT_ROOT}

echo "***** Get the installer *****"
INSTALLER_PATH=$(find build/ -name "Miniforge*.sh" -or -name "Miniforge*.exe"| head -n 1)
ls build/
if [[ "$(uname)" == MINGW* ]]; then
EXT=exe;
else
EXT=sh;
fi
INSTALLER_PATH=$(find build/ -name "*forge*.$EXT" | head -n 1)

echo "***** Run the installer *****"
chmod +x $INSTALLER_PATH
Expand Down

0 comments on commit 88a8a86

Please sign in to comment.