diff options
author | Bjørn Erik Pedersen <[email protected]> | 2022-01-04 13:07:10 +0100 |
---|---|---|
committer | Bjørn Erik Pedersen <[email protected]> | 2022-01-04 17:10:39 +0100 |
commit | 2b6063c3e388056597af88709ff017d15f53c962 (patch) | |
tree | a86d4dde3cd5b7df5bb5738a248a0da0c5f640fd /commands/convert.go | |
parent | 56ab83a59712725e1ce0dd3fd516cc7c190c8478 (diff) | |
download | hugo-2b6063c3e388056597af88709ff017d15f53c962.tar.gz hugo-2b6063c3e388056597af88709ff017d15f53c962.zip |
Misc depreation updates
* Deprecate .Page.Path when backed by a file
* site.Permalinks
* --ignoreVendor (use --ignoreVendorPaths)
Closes #9348
Closes #9349
Diffstat (limited to 'commands/convert.go')
-rw-r--r-- | commands/convert.go | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/commands/convert.go b/commands/convert.go index e2bd4307f..8c84423f5 100644 --- a/commands/convert.go +++ b/commands/convert.go @@ -142,7 +142,7 @@ func (cc *convertCmd) convertAndSavePage(p page.Page, site *hugolib.Site, target return nil } - errMsg := fmt.Errorf("Error processing file %q", p.Path()) + errMsg := fmt.Errorf("Error processing file %q", p.File().Path()) site.Log.Infoln("Attempting to convert", p.File().Filename()) @@ -185,10 +185,10 @@ func (cc *convertCmd) convertAndSavePage(p page.Page, site *hugolib.Site, target newFilename := p.File().Filename() if cc.outputDir != "" { - contentDir := strings.TrimSuffix(newFilename, p.Path()) + contentDir := strings.TrimSuffix(newFilename, p.File().Path()) contentDir = filepath.Base(contentDir) - newFilename = filepath.Join(cc.outputDir, contentDir, p.Path()) + newFilename = filepath.Join(cc.outputDir, contentDir, p.File().Path()) } fs := hugofs.Os |