Skip to content

Commit

Permalink
Merge pull request pybamm-team#1682 from pybamm-team/main-fix-merge
Browse files Browse the repository at this point in the history
Main fix merge
  • Loading branch information
valentinsulzer authored Oct 4, 2021
2 parents 51ee22a + 7a5a249 commit c737eac
Show file tree
Hide file tree
Showing 3 changed files with 16 additions and 11 deletions.
21 changes: 12 additions & 9 deletions .github/workflows/build_sdist.yml
Original file line number Diff line number Diff line change
@@ -1,13 +1,14 @@
name: "Build and publish python sdist"
name: "Build and publish Python sdist"

on:
push:
branches: main
workflow_dispatch:
inputs:
target:
description: 'Deployment target. Can be "pypi" or "testpypi"'
default: 'pypi'
workflow_run:
workflows: ["Build and publish Python wheels"]
types: [completed]

jobs:
build_sdist:
Expand All @@ -16,7 +17,9 @@ jobs:
strategy:
matrix:
python-version: [3.8]

if: |
${{ github.event.workflow_run.conclusion == 'success' }} ||
github.event_name == 'workflow_dispatch'
steps:
- uses: actions/checkout@v2

Expand All @@ -29,15 +32,13 @@ jobs:
run: pip install wheel

- name: Build sdist
run: python setup.py sdist --formats=gztar,zip
run: python setup.py sdist --formats=gztar

- name: Upload sdist
uses: actions/upload-artifact@v2
with:
name: files
path: |
./dist/*.tar.gz
./dist/*.zip
path: ./dist/*.tar.gz
if-no-files-found: error


Expand All @@ -53,7 +54,9 @@ jobs:
path: sdist

- name: Publish sdist on PyPI
if: github.event.inputs.target == 'pypi'
if: |
github.event.inputs.target == 'pypi' ||
(github.event_name == 'push' && github.ref == 'refs/heads/main')
uses: pypa/gh-action-pypi-publish@master
with:
user: __token__
Expand Down
4 changes: 3 additions & 1 deletion .github/workflows/build_wheels.yml
Original file line number Diff line number Diff line change
Expand Up @@ -81,7 +81,9 @@ jobs:
name: wheels

- name: Publish wheels on PyPI
if: github.event.inputs.target == 'pypi'
if: |
github.event.inputs.target == 'pypi' ||
(github.event_name == 'push' && github.ref == 'refs/heads/main')
uses: pypa/gh-action-pypi-publish@master
with:
user: __token__
Expand Down
2 changes: 1 addition & 1 deletion vcpkg-configuration.json
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
{
"default-registry": {
"kind": "builtin",
"baseline": "642d1ccb276ce13d8a8521b1ef2856f5f7bc9cdd"
"baseline": "e201002b4f4827d7b7b672f0c5c672a77fc3b77d"
},
"registries": [
{
Expand Down

0 comments on commit c737eac

Please sign in to comment.