diff --git a/src/main/scala/gitbucket/core/plugin/PluginRegistory.scala b/src/main/scala/gitbucket/core/plugin/PluginRegistory.scala index a963f5e..7e5b0fd 100644 --- a/src/main/scala/gitbucket/core/plugin/PluginRegistory.scala +++ b/src/main/scala/gitbucket/core/plugin/PluginRegistory.scala @@ -3,7 +3,7 @@ import java.io.{File, FilenameFilter, InputStream} import java.net.URLClassLoader import java.nio.channels.{FileChannel, FileLock} -import java.nio.file.{Paths, StandardOpenOption, StandardWatchEventKinds} +import java.nio.file.{Files, Paths, StandardOpenOption, StandardWatchEventKinds} import java.util.Base64 import javax.servlet.ServletContext @@ -320,6 +320,9 @@ override def run(): Unit = { val path = Paths.get(PluginHome) + if(!Files.exists(path)){ + Files.createDirectories(path) + } val fs = path.getFileSystem val watcher = fs.newWatchService