You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: README.md
+94-36Lines changed: 94 additions & 36 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -2,42 +2,91 @@
2
2
3
3
## Overview
4
4
5
-
This repository contains GitHub actions for various conda-related tasks, such as verifying a conda package, and uploading a conda package to Anaconda Cloud.
5
+
This repository contains GitHub actions for common conda package workflows, including installing a package into a test environment, verifying that it imports correctly, removing old packages from Anaconda Cloud, and publishing packages to Anaconda Cloud.
6
6
7
-
These actions primarily assumes that you have built a `<package-name>.conda`,
8
-
and that it is located in a conda-style channel directory (see [conda-index](https://github.com/conda/conda-index)).
7
+
Some actions assume you have already built a `.conda` package. When using a local package artifact, place it in a conda-style channel directory (see [conda-index](https://github.com/conda/conda-index)).
9
8
10
9
Available actions:
11
10
12
-
-[pkg-verify](#pkg-verify): Verify a conda package by installing it with `micromamba` and ensuring it is importable by Python, and that the version reported by conda and python match.
11
+
-[pkg-install](#pkg-install): Create a micromamba environment and install a conda package into it.
12
+
-[pkg-verify](#pkg-verify): Verify an already-installed conda package by importing it in Python and checking that the conda and Python versions match.
13
13
-[pkg-remove](#pkg-remove): Clean up old conda packages from Anaconda Cloud.
14
14
-[publish](#publish): Publish a conda package to Anaconda Cloud.
15
15
16
+
## pkg-install
17
+
18
+
GitHub action to create a micromamba environment, optionally index a local conda channel, and install a conda package.
19
+
20
+
#### Usage
21
+
22
+
Full list of available inputs in [`pkg-install/action.yml`](pkg-install/action.yml).
|`conda_env`| Name of the created conda environment |
38
+
|`conda_install_dir`| Filesystem path of the created env |
39
+
40
+
Example:
41
+
42
+
```yaml
43
+
jobs:
44
+
pkg-install:
45
+
runs-on: ubuntu-latest
46
+
defaults:
47
+
run:
48
+
shell: bash -el {0}
49
+
steps:
50
+
- name: Download conda package artifact
51
+
uses: actions/download-artifact@main
52
+
with:
53
+
name: artifact-conda-package
54
+
path: /tmp/local-channel/linux-64
55
+
56
+
- name: Install Conda Package
57
+
id: install
58
+
uses: neutrons/conda-actions/pkg-install@main
59
+
with:
60
+
local-channel: /tmp/local-channel
61
+
package-name: ${{ env.PKG_NAME }}
62
+
python-version: "3.11"
63
+
extra-channels: mantid neutrons pyoncat
64
+
```
65
+
16
66
## pkg-verify
17
67
18
-
GitHub action to verify a conda package by installing it with `micromamba` and ensuring it is importable by Python, and that the version reported by conda and python match.
68
+
GitHub action to verify a conda package that is already installed in a conda environment. The action imports the package in Python and ensures that the version reported by conda and Python match.
19
69
20
70
#### Usage
21
71
22
-
Full list of available inputs in [`pkg-verify/action.yaml`](#pkg-verify/action.yaml).
72
+
Full list of available inputs in [`pkg-verify/action.yaml`](pkg-verify/action.yaml).
0 commit comments