1
- How to issue an xarray release in 15 easy steps
1
+ How to issue an xarray release in 14 easy steps
2
2
3
3
Time required: about an hour.
4
4
5
5
1 . Ensure your master branch is synced to upstream:
6
- git pull upstream master
6
+ ```
7
+ git pull upstream master
8
+ ```
7
9
2. Look over whats-new.rst and the docs. Make sure "What's New" is complete
8
10
(check the date!) and consider adding a brief summary note describing the
9
11
release at the top.
@@ -12,37 +14,53 @@ Time required: about an hour.
12
14
- Function/method references should include links to the API docs.
13
15
- Sometimes notes get added in the wrong section of whats-new, typically
14
16
due to a bad merge. Check for these before a release by using git diff,
15
- e.g., `` git diff v0.X.Y whats-new.rst` ` where 0.X.Y is the previous
17
+ e.g., `git diff v0.X.Y whats-new.rst` where 0.X.Y is the previous
16
18
release.
17
19
3. If you have any doubts, run the full test suite one final time!
18
- py.test
20
+ ```
21
+ pytest
22
+ ```
19
23
4. On the master branch, commit the release in git:
24
+ ```
20
25
git commit -a -m 'Release v0.X.Y'
26
+ ```
21
27
5. Tag the release:
28
+ ```
22
29
git tag -a v0.X.Y -m 'v0.X.Y'
30
+ ```
23
31
6. Build source and binary wheels for pypi:
32
+ ```
24
33
git clean -xdf # this deletes all uncommited changes!
25
34
python setup.py bdist_wheel sdist
35
+ ```
26
36
7. Use twine to register and upload the release on pypi. Be careful, you can't
27
37
take this back!
38
+ ```
28
39
twine upload dist/xarray-0.X.Y*
40
+ ```
29
41
You will need to be listed as a package owner at
30
42
https://pypi.python.org/pypi/xarray for this to work.
31
43
8. Push your changes to master:
44
+ ```
32
45
git push upstream master
33
46
git push upstream --tags
47
+ ```
34
48
9. Update the stable branch (used by ReadTheDocs) and switch back to master:
49
+ ```
35
50
git checkout stable
36
51
git rebase master
37
52
git push upstream stable
38
53
git checkout master
39
- It's OK to force push to 'stable' if necessary.
40
- We also update the stable branch with `git cherrypick` for documentation
41
- only fixes that apply the current released version.
54
+ ```
55
+ It's OK to force push to 'stable' if necessary. (We also update the stable
56
+ branch with `git cherrypick` for documentation only fixes that apply the
57
+ current released version.)
42
58
10. Add a section for the next release (v.X.(Y+1)) to doc/whats-new.rst.
43
59
11. Commit your changes and push to master again:
44
- git commit -a -m 'Revert to dev version'
60
+ ```
61
+ git commit -a -m 'New whatsnew section'
45
62
git push upstream master
63
+ ```
46
64
You're done pushing to master!
47
65
12. Issue the release on GitHub. Click on "Draft a new release" at
48
66
https://github.com/pydata/xarray/releases. Type in the version number, but
@@ -53,11 +71,22 @@ Time required: about an hour.
53
71
14. Issue the release announcement! For bug fix releases, I usually only email
54
72
[email protected] . For major/feature releases, I will email a broader
55
73
list (no more than once every 3-6 months):
56
-
57
-
58
-
74
+
75
+
76
+
77
+
78
+
79
+
59
80
Google search will turn up examples of prior release announcements (look for
60
81
"ANN xarray").
82
+ You can get a list of contributors with:
83
+ ```
84
+ git log "$(git tag --sort="v:refname" | sed -n 'x;$p').." --format="%aN" | sort -u
85
+ ```
86
+ or by replacing `v0.X.Y` with the _previous_ release in:
87
+ ```
88
+ git log v0.X.Y.. --format="%aN" | sort -u
89
+ ```
61
90
62
91
Note on version numbering:
63
92
0 commit comments