1
0
mirror of https://github.com/writeas/writeas-cli synced 2025-07-26 23:08:16 +00:00

Output full URL publishing with --host flag

Now that no scheme is required, we need to use the helper function to
include it, instead of the raw --host value. This does that.

Ref T595
This commit is contained in:
Matt Baer 2019-07-22 15:00:18 -04:00
parent 4e4ccbe2e8
commit c8502be442

View File

@ -126,8 +126,8 @@ func DoPost(c *cli.Context, post []byte, font string, encrypt, code bool) (*writ
if p.Collection != nil {
url = p.Collection.URL + p.Slug
} else {
if c.GlobalString("host") != "" {
url = c.GlobalString("host")
if host := HostURL(c); host != "" {
url = host
} else if cfg.Default.Host != "" {
url = cfg.Default.Host
} else if config.IsDev() {