This documents the steps necessary to release a new version of the IESopt.jl package. Follow these step-by-step, and fix any issues that might arise, before proceeding to the next step:
- Check tests locally
- Check formatting
- Update the changelog
- Update the version number
- Trigger a new release
After entering "package mode" (press ]
), make sure that the IESopt
environment is activated, which shows as
(IESopt) pkg>
(if not execute activate .
), and then run the tests by executing the test
command:
(IESopt) pkg> test
The following assumes that you have installed the JuliaFormatter.jl
package.
Expand: How to install JuliaFormatter
It is advised to add that package to your "base" environment (it comes at little overhead, and is then available in all environments). To install the package, run the following command in the Julia REPL, after switching to "package mode" (press
]
):(......) pkg> activate (@v1.10) pkg> add JuliaFormatterThe first "empty" activate command is necessary to switch to the "base" environment (it acts like
conda deactivate
). The second command then installs theJuliaFormatter.jl
package (note that(@v1.10)
is just an example, it could be different for you).
To check/fix the formatting of the package, run the following command in the Julia REPL:
using JuliaFormatter
format("src")
This automatically formats all files in the src
directory. This returns true
if all files were already formatted
correctly.
Check out Keep a Changelog for guidance on how to write a changelog. You can use the template below, replace all placeholders, and remove the parts that are not applicable. Add the new entry as topmost entry of the CHANGELOG.md file.
Expand: Changelog template
## [X.Y.Z] - YYYY-MM-DD
{{Give a (really) short description of the release here, ideally one sentence.}}
### Added
- {{document new features here}}
### Changed
- {{document changed features here}}
### Deprecated
- {{document deprecated features here}}
### Removed
- {{document removed features here}}
### Fixed
- {{document fixed bugs here}}
Update the version number in the Project.toml file. The version number should be in the format X.Y.Z
.
Check the Semantic Versioning specification for guidance on how to update the
version number. Make sure to name your commit as:
chore: prep for vX.Y.Z
Open the latest commit that was merged into the main
branch (this should be a chore: prep for vX.Y.Z
commit) and add
a comment with the following text:
@JuliaRegistrator register
Release notes:
{{>> directly add you new changelog entry here <<}}