Skip to content

Commit 170e491

Browse files
fix: incorrect error message for --doc-update.
1 parent 115a518 commit 170e491

File tree

2 files changed

+3
-2
lines changed

2 files changed

+3
-2
lines changed

changelog.md

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -3,6 +3,7 @@
33
## Unreleased
44
<!-- Add all new changes here. They will be moved under a version at release -->
55
* `FIX` incorrect argument skip pattern for `--check_out_path=`, which incorrectly skips the next argument
6+
* `FIX` incorrect error message for `--doc_update`.
67

78
## 3.13.6
89
`2025-2-6`

script/cli/doc/init.lua

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -16,7 +16,7 @@ local doc = {}
1616
local function findDocJson()
1717
local doc_json_path
1818
if type(DOC_UPDATE) == 'string' then
19-
doc_json_path = fs.absolute(fs.path(DOC_UPDATE)) .. '/doc.json'
19+
doc_json_path = fs.canonical(fs.path(DOC_UPDATE)) .. '/doc.json'
2020
else
2121
doc_json_path = fs.current_path() .. '/doc.json'
2222
end
@@ -46,7 +46,7 @@ local function getPathDocUpdate()
4646
local doc_json_dir = doc_json_path:string():gsub('/doc.json', '')
4747
return doc_json_dir, doc_path
4848
else
49-
error(string.format('Error: Cannot update "%s".', doc_json_path .. '/doc.json'))
49+
error(string.format('Error: Cannot update "%s".', doc_json_path))
5050
end
5151
end
5252

0 commit comments

Comments
 (0)