I thought of naming it Kotlinist
. But then, living in Berlin and realizing how much the short name of the infamous
Kottbusser Tor can sound like a play on word with Kotlin, I decided to call the project: Kotti
.
This is basically a library I am creating to assemble all the little utility classes, extension methods and DSLs I do find useful when developing in Kotlin. Instead of copying parts of code from one project to the other, I decided to group them here and have my applicative project depend on it.
In time, I am open to other contributors and maintainers, especially to have discussion about what to include and what not to. It's easier to achieve a better designed library when not only one set of opinion is involved.
-- Adeynack
General extensions to the Kotlin base library.
Tools and assertion utilities useful for testing.
Tools and assertion utilities for the Kovenant Promises library.
Extensions and DSL for developing Swing GUI applications.
To execute the tests from all components:
./gradlew test
Deploying to the local Maven repository (on the development machine) allows other projects to use the library in its
development state. It is suggested, to avoid confusion, to append -SNAPSHOT
to PUBLISH_VERSION
in the
root build.gradle file.
./gradlew publishToMavenLocal
That also allows quick development of production software while adding and debugging features to Kotti
locally.
Project using this library from local publishing need to include this in their Gradle file:
repositories {
mavenLocal()
}
dependencies {
compile "com.github.adeynack:kotti-core:0.1-SNAPSHOT"
}
DISCLAIMER: This is a first iteration of the process. Not the best way. Not bulletproof. But it is a start. This will evolve over time.
- Create an issue in GitHub with the name
Publish version 0.1
(where0.1
is the version you are about to publish). - Check out a clean version of
master
git checkout master git pull
- Create a branch with your issue number (ie:
19-publish-0.1
is the issue number is19
)git checkout -b 19-publish-version-0.1
- Check what the current version being worked on is in the Gradle project file. Per instance:
That means the current version that is about to be published is
def PUBLISH_VERSION = 0.1
0.1
. Make sure no-SNAPSHOT
suffix is present. - Add release notes for the current version.
- Add a new version at the BEGINNING of the list (so they are sorted by reverse date order)
- A new version starts with the version number and the date. ie:
## 0.1 - 2017-06-09
- Group changes by modules (
core
,swing
,tests
, etc.) - Describe briefly what was added, modified or deleted.
- Commit in that branch
git add CHANGELOG.md && git commit -m "#19 Release notes for version 0.1"
- Tag the current commit as the end of the current version.
git tag 0.1 && git push --tags
- Publish to BinTray using the instructions in the Manual publishing to BinTray section of this document.
- Bump up the version number (usually, the 2nd digit) in the Gradle file for having in the
master
branch afterwards the next version to be published (useful when developing and publishing locally, to keep dependencies in client projects working). - Commit in that branch
git add build.gradle && git commit -m "#19 Published version 0.1"
- Create a pull request for this branch. Be careful in doing that during a "relative code-freeze" (make sure noone merges between the moment you tag and the moment you merge this pull request).
The end result is:
- there is a GIT tag pointing at the exact status when published, with the right version number and the release notes.
- the binaries, docs and sources are published to BinTray.
- the master branch now points at the next version to be published.
- Make sure you are exporting the following environment variables.
BINTRAY_USER
containing your user name on BinTrayBINTRAY_API_KEY
containing your API key for BinTray. Go get your API key:- Go to Edit your profile on BinTray
- Click API Key
- Click Copy to clipboard (an icon with 2 overlapping squares)
- Make sure the version number (variable
PUBLISH_VERSION
in kotti.gradle) is set to the exact version you want to publish.def PUBLISH_VERSION = 0.1
- Manually execute the Gradle task for publishing to BinTray.
./gradlew clean bintrayUpload
- Log to BinTray and go to the Kotti repository
- Go to the Versions section and click on the version number you just published.
- Make sure all expected files in all components are present.
Example with
kotti-core
:kotti-core-0.2-javadoc.jar
kotti-core-0.2-sources.jar
kotti-core-0.2.jar
kotti-core-0.2.pom
- In the the Kotti repository, in the Notice (look for a gray bell), click Publish