Fix Jekyll import

Fixes #6131
This commit is contained in:
Bjørn Erik Pedersen 2019-07-30 09:14:14 +02:00
parent 2c7c361091
commit e28bd4c0f8
No known key found for this signature in database
GPG key ID: 330E6E2BD4859D8F

View file

@ -334,6 +334,14 @@ func NewCaches(p *helpers.PathSpec) (Caches, error) {
cfs = fs cfs = fs
} }
if cfs == nil {
// TODO(bep) we still have some places that do not initialize the
// full dependencies of a site, e.g. the import Jekyll command.
// That command does not need these caches, so let us just continue
// for now.
continue
}
baseDir := v.Dir baseDir := v.Dir
if err := cfs.MkdirAll(baseDir, 0777); err != nil && !os.IsExist(err) { if err := cfs.MkdirAll(baseDir, 0777); err != nil && !os.IsExist(err) {