From b7dbbef42401e699aeecc5d5f376152c14081843 Mon Sep 17 00:00:00 2001 From: walker <13750528578@163.com> Date: Sat, 13 Jun 2026 10:28:00 +0800 Subject: [PATCH] =?UTF-8?q?feat(xhs):=20=E6=94=AF=E6=8C=81=E6=A0=87?= =?UTF-8?q?=E9=A2=98=E5=88=97=E8=A1=A8=E6=AD=A3=E6=96=87=E6=A8=A1=E5=BC=8F?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- cmd/mark2note/main.go | 108 +++++++++++++++++++++++++++++++++++++ cmd/mark2note/main_test.go | 88 ++++++++++++++++++++++++++++++ internal/app/service.go | 2 + 3 files changed, 198 insertions(+) diff --git a/cmd/mark2note/main.go b/cmd/mark2note/main.go index ccdecae..d586459 100644 --- a/cmd/mark2note/main.go +++ b/cmd/mark2note/main.go @@ -26,6 +26,11 @@ type Options = app.Options const xhsPublishMetaFilename = "xhs-publish-meta.json" +const ( + xhsContentModeNone = "none" + xhsContentModePageTitles = "page-titles" +) + func defaultOptions() Options { return Options{ OutDir: "output", @@ -82,6 +87,7 @@ Flags: --stop-before-submit for --publish-xhs, prepare Xiaohongshu editor then stop before final submit --prepare-xhs generate Xiaohongshu publish metadata after render without publishing --xhs-tags override auto-generated Xiaohongshu topics for --publish-xhs/--prepare-xhs + --xhs-content-mode XHS body generation for --publish-xhs/--prepare-xhs (none or page-titles) --xhs-mode override Xiaohongshu publish timing mode for --publish-xhs/--prepare-xhs (immediate or schedule) --xhs-visibility override Xiaohongshu visibility for --publish-xhs/--prepare-xhs (public or only-self) --xhs-schedule-at