|
4 | 4 | branches: |
5 | 5 | - main |
6 | 6 | - minor |
| 7 | + - major |
7 | 8 | push: |
8 | 9 | branches: |
9 | 10 | - main |
| 11 | + - major |
10 | 12 |
|
11 | 13 | jobs: |
12 | 14 | patch-test-environment: |
@@ -102,7 +104,7 @@ jobs: |
102 | 104 | needs: |
103 | 105 | - tests |
104 | 106 | # And only on a push event, not a pull_request. |
105 | | - if: ${{ github.event_name == 'push' }} |
| 107 | + if: ${{ github.event_name == 'push' && github.ref == 'refs/heads/main' }} |
106 | 108 | runs-on: ubuntu-latest |
107 | 109 | defaults: |
108 | 110 | run: |
@@ -137,3 +139,46 @@ jobs: |
137 | 139 | run: | |
138 | 140 | anaconda -t ${{ secrets.CONDA_UPLOAD_TOKEN }} upload \ |
139 | 141 | /usr/share/miniconda/envs/build/conda-bld/noarch/*.conda |
| 142 | +
|
| 143 | + deploy-beta: |
| 144 | + # Make sure to only run a deploy if all tests pass. |
| 145 | + needs: |
| 146 | + - tests |
| 147 | + # And only on a push event, not a pull_request. |
| 148 | + if: ${{ github.event_name == 'push' && github.ref == 'refs/heads/major' }} |
| 149 | + runs-on: ubuntu-latest |
| 150 | + defaults: |
| 151 | + run: |
| 152 | + shell: bash -l {0} |
| 153 | + env: |
| 154 | + PKG_NAME: "activity-browser-beta" |
| 155 | + steps: |
| 156 | + - uses: actions/checkout@v3 |
| 157 | + with: |
| 158 | + fetch-depth: "0" |
| 159 | + - name: Build and deploy 3.11 |
| 160 | + uses: conda-incubator/setup-miniconda@v2 |
| 161 | + with: |
| 162 | + python-version: 3.11 |
| 163 | + activate-environment: build |
| 164 | + environment-file: .github/conda-envs/build.yml |
| 165 | + - name: Export version |
| 166 | + run: | |
| 167 | + ID=$(git rev-list 2.11.0..HEAD --count) |
| 168 | + VERSION="3.b.${ID}" |
| 169 | + echo "VERSION=$VERSION" >> $GITHUB_ENV |
| 170 | + - name: Patch recipe with run requirements from stable |
| 171 | + uses: mikefarah/yq@master |
| 172 | + # Adds the run dependencies from the stable recipe to the dev recipe (inplace) |
| 173 | + with: |
| 174 | + cmd: | |
| 175 | + yq eval-all -i 'select(fi == 0).requirements.run += select(fi == 1).requirements.run | select(fi == 0)' .github/dev-recipe/meta.yaml recipe/meta.yaml |
| 176 | + - name: Show patched dev recipe |
| 177 | + run: cat .github/dev-recipe/meta.yaml |
| 178 | + - name: Build beta package |
| 179 | + run: | |
| 180 | + conda build .github/dev-recipe/ |
| 181 | + - name: Upload the activity-browser-dev package |
| 182 | + run: | |
| 183 | + anaconda -t ${{ secrets.CONDA_MRVISSCHER }} upload \ |
| 184 | + /usr/share/miniconda/envs/build/conda-bld/noarch/*.conda |
0 commit comments