OCaml Changelog
RSSOfficial stable release announcements and updates from the OCaml compiler, OCaml infrastructure and the OCaml Platform Tools.
We are excited to announce the release of dune-release 2.2.0 which brings full compatibility with cmdliner 2.0.0!
Please note that this release introduces a change in user-facing behavior: following the stricter requirements of Cmdliner 2.0, prefix-matching for command options is no longer supported. Users must now provide the full wording for all flags (for example, --skip-tests instead of --skip-test).
We recommend that all users update their automation scripts to use explicit, full-length options to ensure a smooth transition.
Dune-release 2.1.0 has been released!
With this update,
- A new command
dune-release delegate-info versionhas been added, which shows the current version of the package, as inferred bydune-release. - The
dev-repofield in the.opamfile can now be overridden using the--dev-repoflag on the commandsdune-releaseanddune-release publish. - A bug related to decoding GitHub URLs has been fixed (FIXME:explain context and what's working now that wasn't before)
dune-releaseno longer publishes docs to github pages. This choice has been made because, as a consequence of publishing toopam-repository, the package documentation is built and served byocaml.org/packages.dune-releasenow works with the experimental package management feature from Dune Developer Preview.
See full changelog
Added
- Add
dune-release delegate-info versionto show the current version as infered by the tool (#495, @samoht) - Add
--dev-repotodune-releaseanddune-release publishto overwrite thedev-repofield specified in the opam file (#494, @samoht)
Changed
- Use the 'user' option as the fork owner, only attempt to decode the remote URL if the user option is not set. (#480, @Julow)
Fixed
- Make
dune-releasenot fail in the presence of~/.dune/bin/dune(which is present when using dune package management)
Removed
dune-releaseno longer publishes docs to github pages. Instead, we rely on the docs published underocaml.org/packages(#499 #500, @v-gb @samoht)
We're excited to announce the release of Dune-release 2.0.0!
This release brings support for putting your .opam files in a opam/
directory. If your project contains dozens of packages, you'll be able to
generate them into the opam/ folder starting with Dune 3.8 using (opam_file_location inside_opam_directory) in your dune-project.
Another notable change is the removal of delegates. Users of dune-release who
want to publish their packages to another platform than GitHub can now use the
dune-release delegate-info and use the output to build their own publication
workflows.
See full changelog
Added
- Adopt the OCaml Code of Conduct (#473, @rikusilvola)
- Added support for projects that have their OPAM files in the
opam/subdirectory. (#466, @Leonidas-from-XIV)
Changed
- Running
dune-release checknow attempts to discover and parse the change log, and a new flag--skip-change-logdisables this behaviour. (#458, @gridbugs) - List the main package and amount of subpackages when creating the PR to avoid very long package lists in PRs (#465, @emillon)
Fixed
- Avoid collision between branch and tag name. Tag detection got confused when branch was named the same as tag. Now it searches only for tag refs, instead of all refs. (#452, @3Rafal)
- Fix project name detection from
dune-project. The parser could get confused when opam file generation is used. Now it only considers the first(name X)in the file. (#445, @emillon)
Removed
- Remove support for delegates.
Previous users of this feature should now use
dune-release delegate-infoand wrap dune-release calls in a script. See #188 for details. (#428, @NathanReb) - Removed support for the OPAM 1.2.2 client. This means
dune-releaseexpects theopambinary to be version 2.0 at least. (#406, #411, @Leonidas-from-XIV)
See full changelog
Fixed
- Fix project name detection from
dune-project. The parser could get confused when opam file generation is used. Now it only considers the first(name X)in the file. (#445, #446, @emillon)
See full changelog
Fixed
- Fix compatibility with Cmdliner 1.1.0. This also unfortunately means that the minimum OCaml version is 4.08 now. (#429, @NathanReb)
See full changelog
Added
- Add
--skip-lint,--skip-build,--skip-testand--keep-build-dirto the main command (#419, @NathanReb) - Added support for parsing changelogs written in the style of keepachangelog.com (#421, @ifazk)
See full changelog
Fixed
- Fixed the release asset URL for projects with multiple opam packages. Before,
the packages would attempt to infer their URL and fail in rare cases where
the project uses
vas prefix for tags but the project version omits it. Now they share the same URL. (#402, #404, @Leonidas-from-XIV)
See full changelog
Added
- Added support for creating releases from unannotated Git tags.
dune-releasesupported unannotated tags in a few places already, now it supports using them for creating a release. (#383, @Leonidas-from-XIV)
Fixed
- Change the
---Vcommand option to be-V(#388, @Leonidas-from-XIV) - Infer release versions are inferred from VCS tags. This change allows using
dune-releaseon projects that do not use the changelog or have it in a different format. (#381, #383 @Leonidas-from-XIV) - Fix a bug where
dune-releasecouldn't retrieve a release on GitHub if the tag and project version don't match (e.g.v1.0vs1.0).dune-releasewould in such case believe the release doesn't exist, attempt to create it and subsequently fail. (#387, #395, @Leonidas-from-XIV)
On behalf of the dune-release team I'm pleased to announce that we're releasing dune-release.1.5.0.
It has been quite a while since the last release so there are numerous changes and improvements in this one, along with a lot of bug fixes.
The two main new features in 1.5.0 are:
- A draft release mode that creates a draft Github release and a draft PR to opam-repository. It comes with an
undraftcommand that will undraft both and update the opam file'surl.srcfield accordingly. We believe this feature will prove helpful to maintainers of tools such asdunewhich releases are often watched by distribution maintainers. Draft releases allow you to wait until you have opam-repository's CI approval to actually create a GH release that will notify anyone watching the repository. This feature is still a bit experimental, we have ideas on how to improve it but we wanted to get a first version out to collect feedback on how it is used and what you folks expect from it. - A
checkcommand that you can run ahead of a release to know if dune-release has all the information it needs in the repository, along with running the lint, build and test checks it normally runs after building the tarball. We're aware that it can be frustrating to see dune-release fail right in the middle of the release process. We're trying to improve this situation and this is a first step in that direction.
You can see the full changelog here
You'll note we also deprecated a few features such as delegates (as we announced in this post), opam 1.x and the --user option and corresponding config file field.
This release is likely to be the last 1.x release of dune-release except for important bug fixes as we'll start working on 2.0 soon.
Our main goals for 2.0 are to make the experience for github users as seemless as possible. We want the tool to do the right thing for those users without them having to configure anything. Delegates got in the way there and that's why we're removing them. We do care about our non github users and we've worked on making it as configurable as possible so that you can integrate it in your release workflow. The situation should already have improved quite a bit with this release as we fixed several bugs for non github hosted repositories. We want to make sure that these users will be happy with dune-release 2.0 as well. Hopefully in the future dune-release will support other release workflows such as handling gitlab hosted repositories but we want to make sure our main user base is happy with the tool before adding this.
We'll communicate a bit more on our plans for 2.0 in the next few months. Our hope is that it will hit opam before the end of this year.
We hope that you'll like this new version and wish you all successful and happy releases!
See full changelog
Added
- Add
--no-auto-opento the default command. It was previously only available fordune-release opam. (#374, @NathanReb) - Add a
config createsubcommand to create a fresh configuration if you don't have one yet (#373, @NathanReb) - Add
--local-repo,--remote-repoand--opam-repooptions to the default command, they used to be only available for theopamsubcommand (#363, @NathanReb) - Add a
--tokenoption todune-release publishanddune-release opamcommands to specify a github token. This allows dune-release to be called through a Github Actions workflow and use the github token through an environment variable. (#284 #368, @gpetiot @NathanReb) - Log curl calls on verbose/debug mode (#281, @gpetiot)
- Try to publish the release asset again after it failed (#272, @gpetiot)
- Improve error reporting of failing git comands (#257, @gpetiot)
- Suggest a solution for users without ssh setup (#304, @pitag-ha)
- Allow including git submodules to the distrib tarball by passing the
--include-submodulesflag todune-release,dune-release bistroordune-release distrib(#300, @NathanReb) - Support 'git://' scheme for dev-repo uri (#331, @gpetiot)
- Support creation of draft releases and draft PRs. Define a new option
--draftfordune-release publishanddune-release opam submitcommands. (#248, @gpetiot) - Add a new command
checkto check the prerequisites of dune-release and avoid starting a release process that couldn't be finished (#318, #351, @pitag-ha) - When preparing the opam-repository PR and pushing the local branch to
the user's remote opam-repository fork, use
--set-upstreamto ease any further update of the PR (#350, @gpetiot)
Changed
- Entirely rely on the remote fork of opam-repository URL in
opam submitinstead of reading the user separately. The information was redundant and could only lead to bugs when unproperly set. (#372, @NathanReb) - Use pure token authentication for Github API requests rather than "token as passwords" authentication (#369, @NathanReb)
- Require tokens earlier in the execution of commands that use the github API. If the token isn't saved to the user's configuration, the prompt for creating one will show up at the command startup rather than on sending the first request (#368, @NathanReb)
- Attach the changelog to the annotated tag message (#283, @gpetiot)
- Do not remove versioned files from the tarball anymore. We used to exclude
.gitignore,.gitattributesand other such files from the archive. (#299, @NathanReb) - Don't try to push the tag if it is already present and point to the same ref on the remote.
dune-releasemust guess which URI to pass togit pushand may guess it wrong. This change allows users to push the tag manually to avoid using that code. (#219, @Julow) - Don't try to create the release if it is already present and points to the same tag (#277, @kit-ty-kate)
- Recursively exclude all
.git/.hgfiles and folders from the distrib tarball (#300, @NathanReb) - Make the automatic dune-release workflow to stop if a step exits with a non-zero code (#332, @gpetiot)
- Make git-related mdx tests more robust in unusual environments (#334, @sternenseemann)
- Set the default tag message to "Release
" instead of "Distribution " - Opam file linter: check for
synopsisinstead ofdescription(#291, @kit-ty-kate) - Upgrade the use of the opam libraries to opam 2.1 (#343, @kit-ty-kate)
Deprecated
- Deprecate the
--userCLI options and configuration field, they were redundant with the remote-repo option and field and could be set unproperly, leading to bugs (#372, @NathanReb) - Deprecate the use of delegates in
dune-release publish(#276, #302, @pitag-ha) - Deprecate the use of opam file format 1.x (#352, @NathanReb)
Removed
- Option --name is removed from all commands. When used with
dune-release distrib, it was previously effectively ignored. Now it is required to add a(name <name>)stanza todune-project. (#327, @lehy)
Fixed
- Fix a bug where
opam submitwould look up a config file, even though all the required information was provided on the command line. This would lead to starting the interactive config creation quizz if that file did not exist which made it impossible to use it in a CI for instance. (#373, @NathanReb) - Fix a bug where
opam submitwould fail on non-github repositories if the user had no configuration file (#372, @NathanReb) - Fix a bug where subcommands wouldn't properly read the token files, leading to authentication failures on API requests (#368, @NathanReb)
- Fix a bug in
opam submitpreventing non-github users to create the opam-repo PR via dune-release. (#359, @NathanReb) - Fix a bug where
opam submitwould try to parse the custom URI provided through--distrib-urias a github repo URI instead of using the dev-repo (#358, @NathanReb) - Fix the priority of the
--distrib-urioption indune-release opam pkg. It used to have lower precedence than the url file written bydune-release publishand therefore made it impossible to overwrite it if needed. (#255, @NathanReb) - Fix a bug with --distrib-file in
dune-release opam pkgwhere you would need the regular dune-release generated archive to be around even though you specified a custom distrib archive file. (#255, @NathanReb) - Use int64 for timestamps. (#261, @gpetiot)
- Define the order of packages (#263, @gpetiot)
- Allow the dry-run mode to continue even after some API call's response were expected by using placeholder values (#262, @gpetiot)
- Build and run tests for all selected packages when checking distribution tarball (#266, @NathanReb)
- Improve trimming of the changelog to preserve the indentation of the list of changes. (#268, @gpetiot)
- Trim the data of the
urlfile before filling theurl.srcfield. This fixes an issue that caused theurl.srcfield to be a multi-line string instead of single line. (#270, @gpetiot) - Fix a bug causing dune-release to exclude all hidden files and folders (starting with
.) at the repository from the distrib archive (#298, @NathanReb) - Better report GitHub API errors, all of the error messages reported by the GitHub API are now checked and reported to the user. (#290, @gpetiot)
- Fix error message when
dune-release tagcannot guess the project name (#319, @lehy) - Always warn about uncommitted changes at the start of
dune-release distrib(#325, @lehy). Otherwise uncommitted changes to dune-project would be silently ignored bydune-release distrib. - Fix rewriting of github references in changelog (#330, @gpetiot)
- Fixes a bug under cygwin where dune-release was unable to find the commit hash corresponding to the release tag (#329, @gpetiot)
- Fixes release names by explicitly setting it to match the released version (#338, @NathanReb)
- Fix a bug that prevented release of a package whose version number contains invalid characters for a git branch. The git branch names are now sanitized. (#271, @gpetiot)
publish: Fix the process of inferring user name and repo from the dev repo uri (#348, @pitag-ha)
See full changelog
Added
- Add a
dune-release configsubcommand to display and edit the global configuration (#220, @NathanReb). - Add command
delegate-infoto print information needed by external release scripts (#221, @pitag-ha) - Use Curly instead of Cmd to interact with github (#202, @gpetiot)
- Add
x-commit-hashfield to the opam file when releasing (#224, @gpetiot) - Add support for common alternative names for the license and ChangeLog file (#204, @paurkedal)
Changed
- Command
tag: improve error and log messages by comparing the provided commit with the commit correspondent to the provided tag (#226, @pitag-ha) - Error logs: when an external command fails, include its error message in
the error message posted by
dune-release(#231, @pitag-ha) - Error log formatting: avoid unnecessary line-breaks; indent only slightly in multi-lines (#234, @pitag-ha)
- Linting step of
dune-release distribdoes not fail when opam'sdocfield is missing. Do not try to generate nor publish the documentation when opam'sdocfield is missing. (#235, @gpetiot)
Deprecated
- Deprecate opam 1.x (#195, @gpetiot)
Fixed
- Separate packages names by spaces in
publishlogs (#171, @hannesm) - Fix uncaught exceptions in distrib subcommand and replace them with proper error messages (#176, @gpetiot)
- Use the 'user' field in the configuration before inferring it from repo URI and handles HTTPS URIs (#183, @gpetiot)
- Ignore backup files when looking for README, CHANGES and LICENSE files (#194, @gpetiot)
- Do not echo input characters when reading token (#199, @gpetiot)
- Improve the output of VCS command errors (#193, @gpetiot)
- Better error handling when checking opam version (#195, @gpetiot)
- Do not write 'version' and 'name' fields in opam file (#200, @gpetiot)
- Use Yojson to parse github json response and avoid parsing bugs. (#177, @gpetiot)
- The
gitcommand used inpublish docshould checkDUNE_RELEASE_GIT(even if deprecated) beforePATH. (#242, @gpetiot) - Adapt the docs to the removal of the
logsubcommand (#196, @gpetiot)
See full changelog
Fixed
- Fix a bug where
opam submitwould fail if the opam files had no description (#165, @NathanReb) - Fix a bug where opam files could be improperly tempered with while building the distribution tarball (#168, @NathanReb)
See full changelog
Fixed
- Fix a bug where file presence lint check wouldn't be run for
CHANGES,LICENSEandREADME(#161, @NathanReb)
Changed
- Add headers to better distinguish various
dune-releaselogs such as user prompts and informational logs
See full changelog
- Fix a bug in documentation publication where under certain circumstances the
doc would be published in a
_htmlfolder instead of being published at the root ofgh-pages(#157, @NathanReb)
See full changelog
- Add confirmation prompts in some commands. (#144, #146, @NathanReb)
- Use github returned archive URL instead of guessing it. Fixes a bug when releasing a version with URL incompatible characters to github. (#143, @NathanReb)
- Add logs to better describe commands behaviour. (#141, #137, #135, #150, #153, @NathanReb)
- Fix a bug when publishing documentation to a repo for the first time (#136, @NathanReb)
- Allow to submit package to a different opam-repository hosted on github. (#140, #152, @NathanReb)
- Use
dune substfor watermarking. (#147, @NathanReb) - Fix linting step so it checks for
CHANGES,LICENSEandREADMEagain
See full changelog
- Remove assert false in favor of error message. (#125, @ejgallego)
- Embed a 'version: "$release-version"' in each opam file of the current directory to get reproducible releases (#128, #129, @hannesm)
- Generate sha256 and sha512 checksums for release (#131, @hannesm)
- Grammar fixes (#132, @anmonteiro)
- Handle doc fields with no trailing slash (#133, @yomimono)
See full changelog
- Remove the status and log commands (#95, @samoht)
- Fix
dune-release publish docwhen using multiple packages (#96, @samoht) - Fix inferred package name when reading
dune-projectfiles (#104. @samoht) - Add .ps and .eps files to default files excluded from watermarking (backport of dbuenzli/topkg@6cf1eae)
- Fix distribution uri when homepage is using github.io (#102, @samoht)
dune-release lintnow checks that a description and a synopsis exist in opam2 files (#101, @samoht)- Add a more explicit error message if
git checkoutfails in the local opam-repository (#98, @samoht) - Do not create an extra
_htmlfolder when publishing docs on Linux (#94, @anuragsoni and @samoht)
See full changelog
- Fix opam2 format upgrade when submitting a PR (#91, @samoht)
See full changelog
- Determine opam-repository fork user from URI (#64, @NathanReb and @diml)
- All subcommands now support multiple package names (@samoht)
- Do not remove
Makefilefrom the distribution archives (#71, @samoht) - Do not duplicate version strings in opam file (#72, @samoht)
- Fix configuration file upgrade from 0.2 (#55, @samoht)
- Add a
--tagoption to select the release tag (@samoht) - Add a
--versionoption to select the release version (@samoht) - Fix
--keep-v(#70, @samoht) - Make
dune-release <OPTIONS>a shorchut todune-release bistro <OPTIONS>(#75, @samoht) - Add a --no-open option to not open a browser after creating a new P (#79, @samoht)
- Control
--keep-vand--no-auto-openvia options in the config file (#79, @samoht) - Be flexible with file names (#86 and #20, @anuragsoni)
See full changelog
- Store config files in
~/.config/dune/instead of~/.duneto match whatduneis doing (#27, @samoht) - Support opam 1.2.2 when linting (#29, @samoht)
- Use
-p <pkg>instead of-n <pkg>to follow dune convention (#30, #42, @samoht) - Default to
nanoif the EDITOR environment variable is not set. (#32, @avsm) - Fix location of documentation when
odoccreates an_htmlsubdirectory (#34, @samoht) - Remove the browse command (#36, @samoht)
- Re-add the publish delegatation mechanism to allow non-GitHub users to
publish packages (see
dune-release help delegate) (#37, @samoht) - Fix dropping of
vat the beginning of version numbers indune-release opam(#40, @let-def) - Add basic token validation (#40, @let-def)
See full changelog
- Remove opam lint warnings for 1.2 files (#2, @samoht)
- Add a
--keep-voption to not dropvat the beginning of version numbers (#6, @samoht) - Pass
-p <package>to jbuilder (#8, @diml) - Fix a bug in
Distrib.write_substwhich could cause an infinite loop (#10, @diml) - Add a
--dry-runoption to avoid side-effects for all commands (@samoht) - Rewrite issues numbers in changelog to point to the right repository (#13, @samoht)
- Stop force pushing tags to
origin. Instead, just force push the release tag directly to thedev-reporepository (@samoht) - Fix publishing distribution when the the tag to publish is not the repository HEAD (#4, @samoht)
- Do not depend on
opam-publishanymore. Use configuration files stored in~/.duneto parametrise the publishing workflow. (@samoht)
Initial release.
Import some code from topkg.
- Use of
Astring,Logs,FpathandBosinstead of custom re-implementations; - Remove the IPC layer which is used between
topkgandtopkg-care; - Bundle everything as a single binary;
- Assume that the package is built using dune;
- Do not read/need a
pkg/pkg.mlfile.