Improve dune_pkg_lock_normalized#13034
Merged
Leonidas-from-XIV merged 1 commit intoocaml:mainfrom Dec 22, 2025
Merged
Conversation
1. The `sed` command didn't do the right thing, so it was replaced by `dune_cmd subst` 2. `dune_cmd subst` added training newlines everywhere, but this is only correct for stdout. It shouldn't append them to files. That made files have trailing newlines. This change fixes inplace editing. 3. `dune_pkg_lock_normalized` created a file `solve-stderr.txt` in the folder. Use a temporary file instead. Signed-off-by: Marek Kubica <marek@tarides.com>
rgrinberg
approved these changes
Dec 22, 2025
davesnx
added a commit
to davesnx/dune
that referenced
this pull request
Jan 13, 2026
…x/dune into markdown-for-odoc-without-system * 'markdown-for-odoc-without-system' of github.com:/davesnx/dune: (45 commits) Update submodule test now that things work (ocaml#13032) Port pkg tests to internal `sed` where possible (ocaml#13035) dune_trace: add file watching events (ocaml#13038) Improve `dune_pkg_lock_normalized` (ocaml#13034) Only traverse list once to find Dune (ocaml#13031) Add information about dune show depexts in the tutorial (ocaml#13007) fix: Truncate rev store lock (ocaml#13030) coq: more removal of _build/log checking (ocaml#13028) refactor: float to Time.t and Time.Span.t (ocaml#13029) dune trace: move evaluated rules counter under debug (ocaml#13027) Dune_trace: add pid and initial_cwd to initial event (ocaml#13026) refactor: some cosmetic changes dune_trace: simplify event format (ocaml#13025) coq: move away from parsing _build/log in tests (ocaml#13016) dune trace: move process categories to field in args (ocaml#13024) dune_trace: remove all redundant opens (ocaml#13023) dune trace: async events category (ocaml#13022) dune_trace: add config category (ocaml#13021) Remove extra categories from RPC events (ocaml#13020) refactor: reduce code for timestamp/span generation (ocaml#13019) ...
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
sedcommand didn't do the right thing, so it was replaced bydune_cmd substdune_cmd substadded training newlines everywhere, but this is only correct for stdout. It shouldn't append them to files. That made files have trailing newlines. This change fixes inplace editing.dune_pkg_lock_normalizedcreated a filesolve-stderr.txtin the folder. Use a temporary file instead.