Code changes to support the master->main branch switch (#701)
This commit is contained in:
@@ -3,7 +3,7 @@ name: Test
|
|||||||
on:
|
on:
|
||||||
push:
|
push:
|
||||||
branches:
|
branches:
|
||||||
- master
|
- main
|
||||||
pull_request:
|
pull_request:
|
||||||
paths-ignore:
|
paths-ignore:
|
||||||
- 'docs/**'
|
- 'docs/**'
|
||||||
|
|||||||
@@ -27,7 +27,7 @@ jobs:
|
|||||||
private_key: ${{ secrets.CIBUILDWHEEL_BOT_APP_PRIVATE_KEY }}
|
private_key: ${{ secrets.CIBUILDWHEEL_BOT_APP_PRIVATE_KEY }}
|
||||||
|
|
||||||
- name: Create Pull Request
|
- name: Create Pull Request
|
||||||
if: github.ref == 'refs/heads/master' && github.repository == 'pypa/cibuildwheel'
|
if: github.ref == 'refs/heads/main' && github.repository == 'pypa/cibuildwheel'
|
||||||
uses: peter-evans/create-pull-request@v3
|
uses: peter-evans/create-pull-request@v3
|
||||||
with:
|
with:
|
||||||
commit-message: Update dependencies
|
commit-message: Update dependencies
|
||||||
|
|||||||
+1
-1
@@ -4,7 +4,7 @@ language: python
|
|||||||
|
|
||||||
branches:
|
branches:
|
||||||
only:
|
only:
|
||||||
- master
|
- main
|
||||||
|
|
||||||
jobs:
|
jobs:
|
||||||
include:
|
include:
|
||||||
|
|||||||
@@ -4,10 +4,10 @@ cibuildwheel
|
|||||||
[](https://pypi.python.org/pypi/cibuildwheel)
|
[](https://pypi.python.org/pypi/cibuildwheel)
|
||||||
[](https://cibuildwheel.readthedocs.io/en/stable/?badge=stable)
|
[](https://cibuildwheel.readthedocs.io/en/stable/?badge=stable)
|
||||||
[](https://github.com/pypa/cibuildwheel/actions)
|
[](https://github.com/pypa/cibuildwheel/actions)
|
||||||
[](https://travis-ci.com/pypa/cibuildwheel)
|
[](https://travis-ci.com/pypa/cibuildwheel)
|
||||||
[](https://ci.appveyor.com/project/joerick/cibuildwheel/branch/master)
|
[](https://ci.appveyor.com/project/joerick/cibuildwheel/branch/main)
|
||||||
[](https://circleci.com/gh/pypa/cibuildwheel)
|
[](https://circleci.com/gh/pypa/cibuildwheel)
|
||||||
[](https://dev.azure.com/joerick0429/cibuildwheel/_build/latest?definitionId=4&branchName=master)
|
[](https://dev.azure.com/joerick0429/cibuildwheel/_build/latest?definitionId=4&branchName=main)
|
||||||
|
|
||||||
|
|
||||||
[Documentation](https://cibuildwheel.readthedocs.org)
|
[Documentation](https://cibuildwheel.readthedocs.org)
|
||||||
@@ -95,7 +95,7 @@ jobs:
|
|||||||
path: ./wheelhouse/*.whl
|
path: ./wheelhouse/*.whl
|
||||||
```
|
```
|
||||||
|
|
||||||
For more information, including PyPI deployment, and the use of other CI services or the dedicated GitHub Action, check out the [documentation](https://cibuildwheel.readthedocs.org) and the [examples](https://github.com/pypa/cibuildwheel/tree/master/examples).
|
For more information, including PyPI deployment, and the use of other CI services or the dedicated GitHub Action, check out the [documentation](https://cibuildwheel.readthedocs.org) and the [examples](https://github.com/pypa/cibuildwheel/tree/main/examples).
|
||||||
|
|
||||||
Options
|
Options
|
||||||
-------
|
-------
|
||||||
|
|||||||
+2
-2
@@ -15,7 +15,7 @@ init:
|
|||||||
- cmd: set PATH=C:\Python37;C:\Python37\Scripts;%PATH%
|
- cmd: set PATH=C:\Python37;C:\Python37\Scripts;%PATH%
|
||||||
- ps: |
|
- ps: |
|
||||||
$BRANCH = if ($env:APPVEYOR_PULL_REQUEST_HEAD_REPO_BRANCH) { $env:APPVEYOR_PULL_REQUEST_HEAD_REPO_BRANCH } else { $env:APPVEYOR_REPO_BRANCH }
|
$BRANCH = if ($env:APPVEYOR_PULL_REQUEST_HEAD_REPO_BRANCH) { $env:APPVEYOR_PULL_REQUEST_HEAD_REPO_BRANCH } else { $env:APPVEYOR_REPO_BRANCH }
|
||||||
if (-not ($BRANCH -eq 'master' -or $BRANCH.ToLower().StartsWith('appveyor-'))) {
|
if (-not ($BRANCH -eq 'main' -or $BRANCH.ToLower().StartsWith('appveyor-'))) {
|
||||||
$env:PYTEST_ADDOPTS='-k "unit_test or test_0_basic" --suppress-no-test-exit-code'
|
$env:PYTEST_ADDOPTS='-k "unit_test or test_0_basic" --suppress-no-test-exit-code'
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -27,7 +27,7 @@ test_script: python -u ./bin/run_tests.py
|
|||||||
|
|
||||||
branches:
|
branches:
|
||||||
only:
|
only:
|
||||||
- master
|
- main
|
||||||
|
|
||||||
skip_commits:
|
skip_commits:
|
||||||
files:
|
files:
|
||||||
|
|||||||
@@ -40,7 +40,7 @@ def main():
|
|||||||
timestamp = time.strftime("%Y-%m-%dT%H-%M-%S", time.gmtime())
|
timestamp = time.strftime("%Y-%m-%dT%H-%M-%S", time.gmtime())
|
||||||
branch_name = f"update-constraints-{timestamp}"
|
branch_name = f"update-constraints-{timestamp}"
|
||||||
|
|
||||||
shell(f"git checkout -b {branch_name} origin/master", check=True)
|
shell(f"git checkout -b {branch_name} origin/main", check=True)
|
||||||
|
|
||||||
try:
|
try:
|
||||||
shell("bin/update_dependencies.py", check=True)
|
shell("bin/update_dependencies.py", check=True)
|
||||||
@@ -63,7 +63,7 @@ def main():
|
|||||||
"pr",
|
"pr",
|
||||||
"create",
|
"create",
|
||||||
"--repo=pypa/cibuildwheel",
|
"--repo=pypa/cibuildwheel",
|
||||||
"--base=master",
|
"--base=main",
|
||||||
"--title=Update dependencies",
|
"--title=Update dependencies",
|
||||||
f"--body='{body}'",
|
f"--body='{body}'",
|
||||||
],
|
],
|
||||||
|
|||||||
@@ -33,4 +33,4 @@ Obviously, manual steps are for chumps, so we can automate this a little by usin
|
|||||||
|
|
||||||
If you don't need much control over the release of a package, you can set up cibuildwheel to deliver the wheels straight to PyPI. This doesn't require anycloud storage to work - you just need to bump the version and tag it.
|
If you don't need much control over the release of a package, you can set up cibuildwheel to deliver the wheels straight to PyPI. This doesn't require anycloud storage to work - you just need to bump the version and tag it.
|
||||||
|
|
||||||
[`examples/travis-ci-deploy.yml`](https://github.com/pypa/cibuildwheel/blob/master/examples/travis-ci-deploy.yml) and [`examples/github-deploy.yml`](https://github.com/pypa/cibuildwheel/blob/master/examples/github-deploy.yml) are example configurations that automatically upload wheels to PyPI. Also check out [this example repo](https://github.com/pypa/cibuildwheel-autopypi-example) for more detailed instructions on how to set this up.
|
[`examples/travis-ci-deploy.yml`](https://github.com/pypa/cibuildwheel/blob/main/examples/travis-ci-deploy.yml) and [`examples/github-deploy.yml`](https://github.com/pypa/cibuildwheel/blob/main/examples/github-deploy.yml) are example configurations that automatically upload wheels to PyPI. Also check out [this example repo](https://github.com/pypa/cibuildwheel-autopypi-example) for more detailed instructions on how to set this up.
|
||||||
|
|||||||
+2
-2
@@ -96,7 +96,7 @@ Commit this file, and push to GitHub - either to your default branch, or to a PR
|
|||||||
|
|
||||||
For more info on this file, check out the [docs](https://help.github.com/en/actions/reference/workflow-syntax-for-github-actions).
|
For more info on this file, check out the [docs](https://help.github.com/en/actions/reference/workflow-syntax-for-github-actions).
|
||||||
|
|
||||||
[`examples/github-deploy.yml`](https://github.com/pypa/cibuildwheel/blob/master/examples/github-deploy.yml) extends this minimal example with a demonstration of how to automatically upload the built wheels to PyPI.
|
[`examples/github-deploy.yml`](https://github.com/pypa/cibuildwheel/blob/main/examples/github-deploy.yml) extends this minimal example with a demonstration of how to automatically upload the built wheels to PyPI.
|
||||||
|
|
||||||
|
|
||||||
# Azure Pipelines [linux/mac/windows] {: #azure-pipelines}
|
# Azure Pipelines [linux/mac/windows] {: #azure-pipelines}
|
||||||
@@ -127,7 +127,7 @@ Commit this file, enable building of your repo on Travis CI, and push.
|
|||||||
|
|
||||||
Then setup a deployment method by following the [Travis CI deployment docs](https://docs.travis-ci.com/user/deployment/), or see [Delivering to PyPI](deliver-to-pypi.md). For more info on `.travis.yml`, check out the [docs](https://docs.travis-ci.com/).
|
Then setup a deployment method by following the [Travis CI deployment docs](https://docs.travis-ci.com/user/deployment/), or see [Delivering to PyPI](deliver-to-pypi.md). For more info on `.travis.yml`, check out the [docs](https://docs.travis-ci.com/).
|
||||||
|
|
||||||
[`examples/travis-ci-deploy.yml`](https://github.com/pypa/cibuildwheel/blob/master/examples/travis-ci-deploy.yml) extends this minimal example with a demonstration of how to automatically upload the built wheels to PyPI.
|
[`examples/travis-ci-deploy.yml`](https://github.com/pypa/cibuildwheel/blob/main/examples/travis-ci-deploy.yml) extends this minimal example with a demonstration of how to automatically upload the built wheels to PyPI.
|
||||||
|
|
||||||
# AppVeyor [linux/mac/windows] {: #appveyor}
|
# AppVeyor [linux/mac/windows] {: #appveyor}
|
||||||
|
|
||||||
|
|||||||
@@ -64,7 +64,7 @@ jobs:
|
|||||||
name: artifact
|
name: artifact
|
||||||
path: dist
|
path: dist
|
||||||
|
|
||||||
- uses: pypa/gh-action-pypi-publish@master
|
- uses: pypa/gh-action-pypi-publish@main
|
||||||
with:
|
with:
|
||||||
user: __token__
|
user: __token__
|
||||||
password: ${{ secrets.pypi_password }}
|
password: ${{ secrets.pypi_password }}
|
||||||
|
|||||||
@@ -1,7 +1,7 @@
|
|||||||
# In this configuration, the package is tested against multiple versions of python
|
# In this configuration, the package is tested against multiple versions of python
|
||||||
# on Linux and on one version of Python on Windows. If and only if all tests pass
|
# on Linux and on one version of Python on Windows. If and only if all tests pass
|
||||||
# will the wheels be built and deployed. Further, deployment is only initiated if
|
# will the wheels be built and deployed. Further, deployment is only initiated if
|
||||||
# the current branch is "master", the current commit is tagged, and the current
|
# the current branch is "main", the current commit is tagged, and the current
|
||||||
# repo is yours (e.g. it won't run on a Pull Request). For convenience, a source
|
# repo is yours (e.g. it won't run on a Pull Request). For convenience, a source
|
||||||
# distribution is also created.
|
# distribution is also created.
|
||||||
|
|
||||||
|
|||||||
+2
-2
@@ -11,8 +11,8 @@ project_with_ssl_tests = test_projects.new_c_project(
|
|||||||
|
|
||||||
context = ssl.SSLContext(ssl.PROTOCOL_TLSv1_2)
|
context = ssl.SSLContext(ssl.PROTOCOL_TLSv1_2)
|
||||||
data = urlopen("https://www.nist.gov", context=context)
|
data = urlopen("https://www.nist.gov", context=context)
|
||||||
data = urlopen("https://raw.githubusercontent.com/pypa/cibuildwheel/master/CI.md", context=context)
|
data = urlopen("https://raw.githubusercontent.com/pypa/cibuildwheel/main/CI.md", context=context)
|
||||||
data = urlopen("https://raw.githubusercontent.com/pypa/cibuildwheel/master/CI.md")
|
data = urlopen("https://raw.githubusercontent.com/pypa/cibuildwheel/main/CI.md")
|
||||||
"""
|
"""
|
||||||
)
|
)
|
||||||
)
|
)
|
||||||
|
|||||||
Reference in New Issue
Block a user