Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

14 set up automated conda release #35

Closed
wants to merge 5 commits into from
Closed
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
17 changes: 17 additions & 0 deletions .conda/meorg_client_dev.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,17 @@
name: meorg_client_dev

channels:
- conda-forge
- accessnri
- coecms
- defaults

dependencies:
- python=>3.9
- pip
- requests
- pytest
- black
- ruff
- pip:
- -r mkdocs-requirements.txt
28 changes: 28 additions & 0 deletions .conda/meta.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,28 @@
{% set data = load_setup_py_data() %}
{% set version = data.get('version') %}

package:
name: meorg_client
version: {{ version }}

source:
path: ..


build:
script: {{ PYTHON }} -m pip install --no-deps --ignore-installed .
noarch: python
# number: {{ GIT_DESCRIBE_NUMBER }}


requirements:
host:
- python >=3.9
- pip
run:
- python >=3.9
- requests

test:
imports:
- meorg_client
28 changes: 28 additions & 0 deletions .github/workflows/cd.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,28 @@
name: Conda Publish

on:
release:
types: [released]

jobs:
conda_deployment:

runs-on: ubuntu-latest

steps:
- uses: actions/checkout@v3
- uses: conda-incubator/setup-miniconda@v2
with:
python-version: '3.9'
environment-file: .conda/build_env.yaml
auto-update-conda: false
auto-activate-base: false
show-channel-urls: true
- name: Build and upload the conda packages
uses: uibcdf/[email protected]
with:
python-version: '3.9'
meta_yaml_dir: .conda
user: bschroeter
label: main
token: ${{ secrets.ANACONDA_TOKEN_BEN }}
1 change: 1 addition & 0 deletions meorg_client/cli.py
Original file line number Diff line number Diff line change
Expand Up @@ -75,6 +75,7 @@ def _call(func, **kwargs):
@click.group(context_settings=dict(
help_option_names=['-h', '--help']
))
@click.version_option()
def cli():
"""
ModelEvaluation.org client utility.
Expand Down
Loading