Why, hello! 👋 Thank you for your interest in contributing to Boot.
Before reading, please know that we have a friendly and active community. We're generally happy to answer any questions you might have that aren't served by this document. The best places to find us are:
Thank you in advance for your contribution, and for getting in touch with us if you have any questions or problems!
- General Contribution Guidelines
- Asking a Question
- Reporting a Bug
- Contributing a Bug Fix
- Contributing a Feature
- Release Process
We are happy to review and accept contributions of any kind, from anyone, under the provisions of our license, the EPL.
Boot is relatively mature software and a piece of core infrastructure for many organizations. We believe it generally solves the problems we had in mind when we first built it, and hope to efficiently maintain it and to slowly improve it for a very long time. As such, we are careful and deliberate about the contributions we choose to accept.
From our perspective, the best contributions:
- Are GitHub "issues" filed on the project's Issues page and are labeled, if possible.
- Clearly state the motivation for the contribution, enumerate its tradeoffs, and provide relevant examples.
- Refer to any related issues, contributions, or documentation that would help a reviewer further understand the contributor's motivation and the contribution's wider context.
- Include new tests and documentation, as appropriate.
- Include an addition to
CHANGES.md
, as appropriate. - Are backwards compatible.
As a mature project that's already met its high level goals, we're most enthusiastic about accepting bug reports, fixes, and improved documentation.
We still welcome new features and general improvements, but the chances they'll be ultimately accepted are lower, especially if they are not backward compatible.
Boot has no set release schedule, but we generally release every 6-8 months. We
loosely follow semantic versioning with a major.minor.patch
semantic
to our version numbers. The current major
version is 2
, and will be for the
foreseeable future.
Currently, the best place to ask a question and receive feedback quickly is in
the #boot
channel of Clojurians Slack.
An alternative is to create a new issue and label the issue with
question
.
To report a Boot bug, create a new issue and fill in the provided report template.
A bug fix contribution should contain all of the information that a bug report would contain. In addition, it should follow the General Contribution Guidelines.
Features are things like new tasks, new arguments for existing "builtin" tasks, or anything else that changes or augments the behavior of Boot.
We accept these pretty regularly. They're backward-compatible from a naming
perspective because we the Boot maintainers "own" the namespace of argument
names. That is, builtin task arguments are not user-extensible, and so can't
conflict with users' build.boot
files.
However, the number of available argument names for a task is finite, because
arguments are limited to the alphabetic short option character, and there are only 25
available: 26 - 1 for h
.
The best new task arguments:
- Don't change the behavior of any existing argument or combination of
arguments. That is, if an argument
-c
is made available, the meaning of-a -b
should stay the same.-a -b -c
can do something different. - Are clearly documented.
We're least likely to accept these, because from a naming perspective, they can
interfere with names a user creates in boot.user
via build.boot
. All of the
builtin tasks are referred by default into the user's build.boot
, and each
time we make one, we effectively take away a potentially good name from a user.
Of course, the user can ns-unmap
names they don't want to conflict with, but
this requires a build.boot
or ~/.boot/profile
code change on their part. We
try very hard to avoid requiring Boot users to change code because of incidental
changes.
If you have an idea for a task that you'd like to distribute because you think it would be useful to others, you should first consider making your own library that contains that task. It's best to do this when:
- The task doesn't need to run inside Boot: it doesn't influence other builtin tasks or leverage Boot's ownership of the filesystem, classpath, and entry point.
- You want to distribute the task before the next Boot release.
For example, Boot has no built-in new
task. Instead, there is a boot/new
library that provides one. The new
task can be invoked like:
boot -d boot/new new -t app -n my-app
This works because boot/new
exports
the
new
task
in its ns
declaration. The -d
option to Boot looks for exported tasks when
it loads dependencies, and makes them available at the command line.
If you had idea for a better new
task, you could create it, and push it to
Clojars yourself. It would then be accessible to Boot users like this:
boot -d YourName/new new -t app -n my-app
This task is also available to users programmatically. They could use your task via:
(set-env! :dependencies '[[YourName/new "1.0.0"]])
(require '[YourName.new :refer [new]]')
Currently the release process requires that you run everything with Java 7.
-
Run the tests via
make test
-
Ensure the
version.properties
file contains the correct version number -
Running
make deploy
will upload all jars to Clojars -
Boot currently uses GitHub releases to serve an initial jarfile:
- Create a release on Github with the version string from
version.properties
- Attach the file
boot/base/target/base-$NEW_VERSION-jar-with-dependencies.jar
asboot.jar
to the Github release.
- Create a release on Github with the version string from
-
Once that done it's usually a good idea to check that everything uploaded correctly:
$ rm -rf ~/.m2/repository/boot; BOOT_VERSION=$NEW_VERSION boot -h
-
If that works fine it's time to tag the release:
$ git tag $NEW_VERSION
-
Now edit the
version.properties
file to introduce a new release cycle. Usually you should bump the least significant version digit. An example in which you just released Boot10.0.0
:$ cat version.properties version=10.0.0 $ echo "version=10.0.1-SNAPSHOT" > version.properties
-
The changelog should then be updated to have all unreleased changes be part of the new release.
-
Now commit the changes you made to version properties and push everything. Don't forget to push the tag!
$ git push $ git push --tags
-
Run the tests via
make test
-
Ensure that the
version.properties
contains the expected SNAPSHOT version numbers as per the release process for stable versions -
Running
make deploy
will upload all jars to Clojars -
Boot currently uses GitHub releases to serve an initial jarfile:
- Create a release on Github with the version string from
version.properties
- Attach the file
boot/base/target/base-$NEW_VERSION-jar-with-dependencies.jar
asboot.jar
to the Github release.
- Create a release on Github with the version string from
-
Once that is done it's usually a good idea to check that everything uploaded correctly:
$ rm -rf ~/.m2/repository/boot ~/.boot/cache/bin/; BOOT_VERSION=$NEW_VERSION boot -h
-
Since SNAPSHOT releases may change over time there is no need to tag them
-
After you've done all this it's usually a good idea to tell others in
#boot-dev
on Slack so that everyone can help testing