forked from kubernetes-client/python
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request kubernetes-client#820 from scottilee/docs
Correct inconsistent spacing and typos
- Loading branch information
Showing
6 changed files
with
36 additions
and
37 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -6,4 +6,3 @@ approvers: | |
- lavalamp | ||
- yliaog | ||
- roycaihw | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,20 +1,20 @@ | ||
# Release process | ||
|
||
Release process of python client involve creating (or updating) a release | ||
branch, update release tags, create distribution packages and upload them to | ||
pip. | ||
The release process of the python client involves creating (or updating) a release | ||
branch, updating release tags, and creating distribution packages and uploading them to | ||
pypi. | ||
|
||
## Change logs | ||
Make sure changes logs are up to date [here](https://github.com/kubernetes-client/python/blob/master/CHANGELOG.md). | ||
If they are not, follow commits added after last release and update/commit | ||
Make sure the change logs are up to date [here](https://github.com/kubernetes-client/python/blob/master/CHANGELOG.md). | ||
If they are not, follow commits added after the last release and update/commit | ||
the change logs to master. | ||
|
||
Then based on the release, follow one of next two steps. | ||
|
||
## Update pre-release branch | ||
|
||
Release branch name should have release-x.x format. All minor and pre-releases | ||
should be on the same branch. To update an existing branch with master(only for | ||
The release branch name should have release-x.x format. All minor and pre-releases | ||
should be on the same branch. To update an existing branch with master (only for | ||
latest pre-release): | ||
|
||
```bash | ||
|
@@ -37,8 +37,8 @@ cherry pick first: | |
scripts/cherry_pick_pull.sh | ||
``` | ||
|
||
Do not merge master into an stable releast branch. Run the script without | ||
parameters and follow its instruction to create cherry pick PR and get the | ||
Do not merge master into a stable release branch. Run the script without | ||
parameters and follow its instructions to create a cherry pick PR. Get the | ||
PR merged then update your local branch: | ||
|
||
```bash | ||
|
@@ -49,26 +49,27 @@ git rebase upstream/$RELEASE_BRANCH | |
``` | ||
|
||
## Sanity check generated client | ||
We need to make sure there is no API changes after running update client | ||
scripts. Such changes should be committed to master branch first. Run this | ||
|
||
We need to make sure there are no API changes after running update client | ||
scripts. Such changes should be committed to the master branch first. Run this | ||
command: | ||
|
||
```bash | ||
scripts/update-client.sh | ||
``` | ||
|
||
And make sure there is no API change (version number changes should be fine | ||
as they will be updated in next step anyway). Do not commit any changes at | ||
this step and go back to master branch if there is any API changes. | ||
as they will be updated in the next step anyway). Do not commit any changes at | ||
this step and go back to the master branch if there are any API changes. | ||
|
||
## Update release tags | ||
|
||
Release tags are in scripts/constants.py file. These are the constants you may | ||
Release tags are in the "scripts/constants.py" file. These are the constants you may | ||
need to update: | ||
|
||
CLIENT_VERSION: Client version should follow x.y.zDn where x,y,z are version | ||
numbers (integers) and D is one of "a" for alpha or "b" for beta and n is the | ||
pre-release number. For a final release, "Dn" part should be omitted. Examples: | ||
pre-release number. For a final release, the "Dn" part should be omitted. Examples: | ||
1.0.0a1, 2.0.1b2, 1.5.1. | ||
|
||
DEVELOPMENT_STATUS: Update it to one of the values of "Development Status" | ||
|
@@ -89,8 +90,9 @@ git push upstream $RELEASE_BRANCH | |
``` | ||
|
||
## Make distribution packages | ||
|
||
First make sure you are using a clean version of python. Use virtualenv and | ||
pyenv packages, make sure you are using python 2.7.12. I would normally do this | ||
pyenv packages. Make sure you are using python 2.7.12. I would normally do this | ||
on a clean machine: | ||
|
||
(install [pyenv](https://github.com/yyuu/pyenv#installation)) | ||
|
@@ -128,9 +130,9 @@ python setup.py bdist_wheel --universal | |
ls dist/ | ||
``` | ||
|
||
You should see two files in dist folder. kubernetes\*.whl and kubernetes\*.tar.gz. | ||
You should see two files in dist folder: "kubernetes\*.whl" and "kubernetes\*.tar.gz". | ||
|
||
TODO: We need a dry-run option an some way to test package upload process to pypi. | ||
TODO: We need a dry-run option and some way to test the package upload process to pypi. | ||
|
||
If everything looks good, run this command to upload packages to pypi: | ||
|
||
|
@@ -142,13 +144,13 @@ twine upload dist/* | |
|
||
Create a gihub release by starting from | ||
[this page](https://github.com/kubernetes-client/python/releases). | ||
Click Deaft new release button. Name the tag the same as CLIENT_VERSION. Change | ||
Click the `Draft a new release button`. Name the tag the same as CLIENT_VERSION. Change | ||
the target branch to "release-x.y". If the release is a pre-release, check the | ||
`This is a pre-release` option. | ||
|
||
|
||
## Announcement | ||
Send an announcement email to [email protected] with the subject [ANNOUNCE] kubernetes python-client $VERSION is released | ||
|
||
Send an announcement email to [email protected] with the subject: [ANNOUNCE] kubernetes python-client $VERSION is released | ||
|
||
## Cleanup | ||
|
||
|
@@ -159,5 +161,4 @@ rm -rf .release | |
|
||
TODO: Convert steps in this document to an (semi-) automated script. | ||
|
||
|
||
ref: https://packaging.python.org/distributing/ |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,27 +1,29 @@ | ||
# Submodules | ||
|
||
To comply with [client library structure requirement](https://github.com/kubernetes/community/blob/master/contributors/design-proposals/api-machinery/csi-client-structure-proposal.md), | ||
python client base utilities is moved into kubernetes-client/python-base repo. `git submodules` is being used to handle dependency to that repo. | ||
This document will provide basic steps to get submodules work. | ||
python client base utilities is moved into the [kubernetes-client/python-base](https://github.com/kubernetes-client/python-base) repo. `git submodules` is being used to handle dependency to that repo. | ||
This document will provide basic steps to get submodules working. | ||
|
||
# Clone repo | ||
To clone repo, you need to pass `recursive` parameter to make the clone also get submodules: | ||
|
||
To clone the repo, you need to pass the `recursive` parameter to make the clone also get submodules: | ||
|
||
```bash | ||
git clone --recursive https://github.com/kubernetes-client/python.git | ||
``` | ||
|
||
if you already clone repo with no `--recursive` option, you can run this command to get submodules: | ||
if you have already cloned the repo with no `--recursive` option, you can run this command to get submodules: | ||
|
||
```bash | ||
git submodule update --init | ||
``` | ||
|
||
# Update submodule | ||
If you changed kubernetes-client/python-base and want to pull your changes into this repo run this command: | ||
|
||
If you changed [kubernetes-client/python-base](https://github.com/kubernetes-client/python-base) and want to pull your changes into this repo run this command: | ||
|
||
```bash | ||
git submodule update --remote | ||
``` | ||
|
||
Once updated, you should create a new PR to commit changes to the repository. | ||
|