summaryrefslogtreecommitdiffstats
path: root/commands/import_jekyll.go
diff options
context:
space:
mode:
authorAnthony Kong <kongakong@users.noreply.github.com>2017-03-13 22:50:57 +1100
committerBjørn Erik Pedersen <bjorn.erik.pedersen@gmail.com>2017-03-13 12:50:57 +0100
commit62efcdfed443239711910592e2d35cd955caea84 (patch)
tree5e9014ea5b8bdd33092248b5bfbe77565bf26055 /commands/import_jekyll.go
parent4b9493cb035a83bb6bb3b90270c6960c93bd3a64 (diff)
commands: Improve jekyll import date format
Allow both yyyy-mm-dd and yyyy-m-d formats in jekyll markdown file names.
Diffstat (limited to 'commands/import_jekyll.go')
-rw-r--r--commands/import_jekyll.go2
1 files changed, 1 insertions, 1 deletions
diff --git a/commands/import_jekyll.go b/commands/import_jekyll.go
index c33b68f2e..071257d7d 100644
--- a/commands/import_jekyll.go
+++ b/commands/import_jekyll.go
@@ -372,7 +372,7 @@ func parseJekyllFilename(filename string) (time.Time, string, error) {
return time.Now(), "", errors.New("filename not match")
}
- postDate, err := time.Parse("2006-01-02", r[0][1])
+ postDate, err := time.Parse("2006-1-2", r[0][1])
if err != nil {
return time.Now(), "", err
}