summaryrefslogtreecommitdiffstats
path: root/commands/convert.go
diff options
context:
space:
mode:
authorspf13 <steve.francia@gmail.com>2014-10-16 20:20:09 -0400
committerspf13 <steve.francia@gmail.com>2014-10-16 20:20:09 -0400
commit5dfc1dedb8ac53b7a2d3823d06808ae86f90b3d9 (patch)
treee90f9cfbcc920685dd9bceecd1925abec81ae0c0 /commands/convert.go
parent24bbfe7d32fe151487ff87394433622e3f69eee4 (diff)
Big refactor of how source files are used. Also added default destination extension option.
Diffstat (limited to 'commands/convert.go')
-rw-r--r--commands/convert.go10
1 files changed, 5 insertions, 5 deletions
diff --git a/commands/convert.go b/commands/convert.go
index c9482bea4..434c6896f 100644
--- a/commands/convert.go
+++ b/commands/convert.go
@@ -99,20 +99,20 @@ func convertContents(mark rune) (err error) {
jww.FEEDBACK.Println("processing", len(site.Source.Files()), "content files")
for _, file := range site.Source.Files() {
- jww.INFO.Println("Attempting to convert", file.LogicalName)
- page, err := hugolib.NewPage(file.LogicalName)
+ jww.INFO.Println("Attempting to convert", file.LogicalName())
+ page, err := hugolib.NewPage(file.LogicalName())
if err != nil {
return err
}
psr, err := parser.ReadFrom(file.Contents)
if err != nil {
- jww.ERROR.Println("Error processing file:", path.Join(file.Dir, file.LogicalName))
+ jww.ERROR.Println("Error processing file:", file.Path())
return err
}
metadata, err := psr.Metadata()
if err != nil {
- jww.ERROR.Println("Error processing file:", path.Join(file.Dir, file.LogicalName))
+ jww.ERROR.Println("Error processing file:", file.Path())
return err
}
@@ -128,7 +128,7 @@ func convertContents(mark rune) (err error) {
metadata = newmetadata
}
- page.Dir = file.Dir
+ //page.Dir = file.Dir
page.SetSourceContent(psr.Content())
page.SetSourceMetaData(metadata, mark)