Skip to content

Commit

Permalink
Change: mimic AB github/conda worflow
Browse files Browse the repository at this point in the history
  • Loading branch information
Pan6ora committed Mar 24, 2023
1 parent 87442da commit bc8e904
Show file tree
Hide file tree
Showing 5 changed files with 54 additions and 18 deletions.
17 changes: 0 additions & 17 deletions .github/workflows/deploy.yaml

This file was deleted.

39 changes: 39 additions & 0 deletions .github/workflows/release.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,39 @@
name: stable release
on:
push:
tags:
- '*'

jobs:
release:
runs-on: ubuntu-latest
defaults:
run:
shell: bash -l {0}
steps:
- uses: actions/checkout@v2
- name: Patch ab env with run requirements from stable recipe
uses: mikefarah/yq@master
with:
cmd: |
yq eval-all -i 'select(fi == 0).dependencies += select(fi == 1).requirements.run | select(fi == 0)' ci/conda-envs/ab.yml ci/recipe/stable/meta.yaml
- name: Create github release
uses: ncipollo/release-action@v1
with:
artifacts: 'ci/conda-envs/ab.yml'
commit: main
token: ${{ secrets.GITHUB_TOKEN }}
- name: Set up conda-build environment
uses: conda-incubator/setup-miniconda@v2
with:
python-version: 3.8
activate-environment: build
environment-file: ci/conda-envs/build.yml
- name: Build activity-browser stable
run: |
conda build ci/recipe/stable
- name: Upload to anaconda.org
run: |
anaconda -t ${{ secrets.CONDA_UPLOAD_TOKEN }} upload \
/usr/share/miniconda/envs/build/conda-bld/noarch/*.tar.bz2
anaconda -t ${{ secrets.CONDA_UPLOAD_TOKEN }} upload ci/conda-envs/ab.yml
6 changes: 6 additions & 0 deletions ci/conda-envs/ab.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
name: ab
channels:
- pan6ora
- conda-forge
dependencies:
- activity-browser
8 changes: 8 additions & 0 deletions ci/conda-envs/build.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,8 @@
name: build
channels:
- pan6ora
- conda-forge
dependencies:
- conda-build
- anaconda-client
- conda-verify
2 changes: 1 addition & 1 deletion conda/meta.yaml → ci/recipe/stable/meta.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@ requirements:
- setuptools
- conda-verify
run:
- python >=3.8,<3.10
- activity-browser =2.7

about:
home: https://github.com/Pan6ora/activity-browser-plugin-template
Expand Down

0 comments on commit bc8e904

Please sign in to comment.