mirror of
https://github.com/gohugoio/hugo.git
synced 2025-08-20 21:31:32 +02:00
@@ -116,13 +116,9 @@ func newFs(source, destination afero.Fs, workingDir, publishDir string) *Fs {
|
||||
panic("workingDir is too short")
|
||||
}
|
||||
|
||||
// If this does not exist, it will be created later.
|
||||
absPublishDir := paths.AbsPathify(workingDir, publishDir)
|
||||
|
||||
// Make sure we always have the /public folder ready to use.
|
||||
if err := source.MkdirAll(absPublishDir, 0777); err != nil && !os.IsExist(err) {
|
||||
panic(err)
|
||||
}
|
||||
|
||||
pubFs := afero.NewBasePathFs(destination, absPublishDir)
|
||||
|
||||
return &Fs{
|
||||
|
Reference in New Issue
Block a user