diff --git a/src/directories.cc b/src/directories.cc index 0b019a6..9e7095f 100644 --- a/src/directories.cc +++ b/src/directories.cc @@ -309,7 +309,10 @@ Directories::Directories() : Gtk::TreeView(), stop_update_thread(false) { bool is_directory=boost::filesystem::is_directory(*source_path); auto target_path = (is_directory ? *source_path : source_path->parent_path())/content; if(!boost::filesystem::exists(target_path)) + { filesystem::write(target_path, ""); + Notebook::get().open(target_path); + } else Terminal::get().print("Cannot create "+target_path.string()+": file already exists.\n", true); update();