mirror of
https://github.com/kovetskiy/mark.git
synced 2026-05-02 05:12:35 +00:00
Add support for using the filename as the page title
This commit is contained in:
committed by
Manuel Rüger
parent
ae5347053a
commit
0f13d249f5
@@ -61,6 +61,12 @@ var Flags = []cli.Flag{
|
||||
Usage: "extract page title from a leading H1 heading. If no H1 heading on a page exists, then title must be set in the page metadata.",
|
||||
Sources: cli.NewValueSourceChain(cli.EnvVar("MARK_TITLE_FROM_H1"), altsrctoml.TOML("title-from-h1", altsrc.NewStringPtrSourcer(&filename))),
|
||||
},
|
||||
&cli.BoolFlag{
|
||||
Name: "title-from-filename",
|
||||
Value: false,
|
||||
Usage: "use the filename (without extension) as the Confluence page title if no explicit 'Title' header or H1 heading is found.",
|
||||
Sources: cli.NewValueSourceChain(cli.EnvVar("MARK_TITLE_FROM_FILENAME"), altsrctoml.TOML("title-from-filename", altsrc.NewStringPtrSourcer(&filename))),
|
||||
},
|
||||
&cli.BoolFlag{
|
||||
Name: "title-append-generated-hash",
|
||||
Value: false,
|
||||
|
||||
Reference in New Issue
Block a user