kiwiproject / kiwiproject-changelog

Generates change logs
MIT License
1 stars 0 forks source link

Provide an "installation" script #174

Closed sleberknight closed 2 months ago

sleberknight commented 2 months ago

Rather than having to go into the kiwiproject-changelog repository, build the (shaded) JAR, then run the JAR using java -jar /path/to/kiwiproject-changelog/target/changelog-generator-0.10.0.jar <options>, provide a way to "install" the change log generator.]

The installation script should:

Installation options might include:

The installation should also allow updating when a new version is released, which would replace the JAR in an existing installation. If the JAR is named generically, i.e., without the version number, then only the JAR needs to be updated.

The installation directory might look like:

<install-dir>/
    .generate-kiwi-changelog
    kiwi-changelog-generator.jar
    README.txt

For initial installation, usage could look like:

$ ./install.sh -d /home/alice/kiwi-changelog

Or to create a custom script name:

$ ./install.sh -d /home/alice/kiwi-changelog -n generate-changelog

To perform an update, you would simply run the install.sh script again:

$ ./install.sh -d /home/alice/kiwi-changelog

The script should be smart enough to detect an update, and only update the JAR.

Then, to run the change log generator, the usage should be pretty simple, e.g.,:

~/Projects/kiwiproject/kiwi-js $ .generate-kiwi-changelog \
    --repository kiwiproject/kiwi-js \
    --previous-rev v0.5.0 \
    --revision v0.6.0 \
    --output-type GITHUB \
    --close-milestone \
    --create-next-milestone 0.7.0

Or, using the short names:

$ .generate-kiwi-changelog -r kiwiproject/kiwi-js -p v0.5.0 -R v0.6.0 -o GITHUB -C -N 0.7.0
sleberknight commented 2 months ago

On a re-installation, we should update everything, in case other things have changed.