Skip to content

Commit 43e3432

Browse files
authored
migrate to new publish method, always run report (#1126)
👍
1 parent fee92ee commit 43e3432

File tree

1 file changed

+25
-18
lines changed

1 file changed

+25
-18
lines changed

azure-pipelines.yml

Lines changed: 25 additions & 18 deletions
Original file line numberDiff line numberDiff line change
@@ -78,6 +78,7 @@ jobs:
7878

7979
- job: report_coverage
8080
pool: {vmImage: 'Ubuntu 16.04'}
81+
condition: always()
8182
dependsOn:
8283
- windows_py37
8384
- windows_py36
@@ -169,21 +170,27 @@ jobs:
169170
displayName: publish code climate
170171
condition: succeededOrFailed()
171172
172-
- job: publish
173-
dependsOn:
174-
- report_coverage
175-
- linux_fix_lint
176-
- linux_docs
177-
- linux_package_description
178-
condition: and(succeeded(), startsWith(variables['Build.SourceBranch'], 'refs/tags/'))
179-
pool: {vmImage: 'Ubuntu 16.04'}
180-
steps:
181-
- task: UsePythonVersion@0
182-
displayName: setup python3.7
183-
inputs: {versionSpec: '3.7'}
184-
- task: PyPIPublisher@0
185-
displayName: Package and publish to PyPI
186-
inputs:
187-
pypiConnection: pypi-conn
188-
packageDirectory: $(System.DefaultWorkingDirectory)
189-
alsoPublishWheel: true
173+
- ${{ if startsWith(variables['Build.SourceBranch'], 'refs/tags/') }}:
174+
- job: publish
175+
dependsOn:
176+
- report_coverage
177+
- linux_fix_lint
178+
- linux_docs
179+
- linux_package_description
180+
condition: succeeded()
181+
pool: {vmImage: 'Ubuntu 16.04'}
182+
steps:
183+
- task: UsePythonVersion@0
184+
displayName: setup python3.7
185+
inputs: {versionSpec: '3.7'}
186+
- task: TwineAuthenticate@0
187+
inputs:
188+
externalFeeds: 'toxdev'
189+
- script: 'python3.7 -m pip install -U twine pip tox'
190+
displayName: "acquire build tools"
191+
- script: 'python3.7 -m pip wheel -w "$(System.DefaultWorkingDirectory)/w" --no-deps .'
192+
displayName: "build wheel"
193+
- script: 'python3.7 -m tox -e py --sdistonly'
194+
displayName: "build sdist"
195+
- script: 'python3.7 -m twine upload -r pypi-toxdev --config-file $(PYPIRC_PATH) $(System.DefaultWorkingDirectory)/w/* .tox/dist/*'
196+
displayName: "upload sdist and wheel to PyPi"

0 commit comments

Comments
 (0)