Skip to content

Commit

Permalink
Adds RELEASING.md
Browse files Browse the repository at this point in the history
  • Loading branch information
oldergod committed Dec 14, 2023
1 parent 29299c2 commit b9d6a35
Showing 1 changed file with 57 additions and 0 deletions.
57 changes: 57 additions & 0 deletions RELEASING.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,57 @@
Releasing
=========

Cutting a Release
---------------------

1. Update `CHANGELOG.md`.

2. Set versions:

```
export RELEASE_VERSION=X.Y.Z
export NEXT_VERSION=X.Y.Z-SNAPSHOT
```

3. Update versions:

```
sed -i "" \
"s/releaseVersion=.*/releaseVersion=$RELEASE_VERSION/g" \
`find . -name "gradle.properties"`
sed -i "" \
"s/'io.outfoxx:\([^\:]*\):[^']*'/'io.outfoxx:\1:$RELEASE_VERSION'/g" \
`find . -name "README.md"`
sed -i "" \
"s/outfoxx.github.io\/swiftpoet\/[^\/]*\/\(.*\)/outfoxx.github.io\/swiftpoet\/$RELEASE_VERSION\/\1/g" \
`find . -name "README.md"`
sed -i "" \
"s/\<version\>\([^<]*\)\<\/version\>/\<version\>$RELEASE_VERSION\<\/version\>/g" \
`find . -name "README.md"`
```

4. Tag the release and push to GitHub.

```
git commit -am "Prepare for release $RELEASE_VERSION."
git tag -a $RELEASE_VERSION -m "Version $RELEASE_VERSION"
git push && git push --tags
```

5. Wait for [GitHub Actions][github_actions] to start building the release.

6. Prepare for ongoing development and push to GitHub.

```
sed -i "" \
"s/VERSION_NAME=.*/VERSION_NAME=$NEXT_VERSION/g" \
`find . -name "gradle.properties"`
git commit -am "Prepare next development version."
git push
```

7. CI will release the artifact and publish the documentation.

[sonatype_issues]: https://issues.sonatype.org/
[sonatype_nexus]: https://oss.sonatype.org/
[github_actions]: https://github.com/outfoxx/swiftpoet/actions

0 comments on commit b9d6a35

Please sign in to comment.