Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
6 changes: 6 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -17,6 +17,12 @@ The workspace `Cargo.toml` `[workspace.package] version` is the single source fo

**Fixed**

- Section, saved-page and typed-range splits exclude the source's whole HWP5 `/DocHistory`
from every fragment and ledger the removed storage and its streams. `--strict` refuses this
reported loss before fragment publication. Native XMLTemplate and HWPX extra parts remain
unchanged to preserve opaque schema/package dependencies; ordinary convert, edit and identity
round-trips retain their existing history behavior ([#449](https://github.com/STAIxBWLB/hwp-cli/issues/449)).

- Shared stage-sync and file-identity helper failures now name their phase and advise checking
output-directory permissions and free space before rerunning. The helper error values use
fixed Korean messages without staging/destination paths or underlying I/O error chains,
Expand Down
4 changes: 4 additions & 0 deletions crates/hwp-cli/src/commands/split.rs
Original file line number Diff line number Diff line change
Expand Up @@ -468,6 +468,7 @@ pub(crate) fn execute(
SplitOutcome {
fragments: vec![extracted.fragment.clone()],
roundings: Vec::new(),
preservation: extracted.preservation.clone(),
}
} else if pages.is_empty() {
hwp_convert::document_split::split_sections(&document)
Expand Down Expand Up @@ -531,6 +532,9 @@ pub(crate) fn execute(
.with_context(|| format!("출력 디렉터리를 만들 수 없습니다: {}", out_dir.display()))?;

let mut report = WriteReport::new();
// Writers compare the sanitized fragment with its output and cannot see source history
// intentionally excluded by the transform. Carry that evidence into strict/loss reporting.
report.preservation.extend(outcome.preservation.clone());
let mut fragment_bytes: Vec<(PathBuf, Vec<u8>)> = Vec::with_capacity(outcome.fragments.len());
for (fragment, destination) in outcome.fragments.iter().zip(&destinations) {
let (write_report, output_document, bytes) =
Expand Down
Loading
Loading