Getting Started¶
This page covers the shortest path from a fresh clone to a working CLI.
Prerequisites¶
- Windows.
- Hancom HWP/Hanword installed locally for COM-backed commands.
- MSBuild or Visual Studio Build Tools with .NET Framework support.
The CLI project targets x86 because HWP desktop automation is usually safer from an x86 host.
Build¶
From the repository root:
build.cmd Release
The Release executable is written to:
src\OpenHwp.Automation.Cli\bin\Release\OpenHwp.Automation.Cli.exe
For shorter commands in PowerShell:
$cli = "src\OpenHwp.Automation.Cli\bin\Release\OpenHwp.Automation.Cli.exe"
& $cli version
First Commands¶
Create a simple HWPX document:
& $cli new-text C:\temp\hello.hwpx "Hello from OpenHwp"
Read document text:
& $cli read-text C:\temp\hello.hwpx
Export to PDF through HWP COM:
& $cli --visible export-pdf C:\temp\hello.hwpx C:\temp\hello.pdf
Diagnose HWP COM¶
Before running editor-backed workflows, confirm the local HWP COM environment:
& $cli --visible diagnose-com
Use visible mode when debugging because hidden HWP sessions can be difficult to distinguish from file locks, modal dialogs, or environment-level COM failures.
Next Steps¶
- Use CLI reference for command examples.
- Use HWPX validation workflow when filling existing form templates.
- Use Image replacement when an existing picture object should keep its layout properties.