]> git.tdb.fi Git - builder.git/blobdiff - source/task.cpp
Refactor transitive dependencies to work on all targets
[builder.git] / source / task.cpp
diff --git a/source/task.cpp b/source/task.cpp
deleted file mode 100644 (file)
index f6fa7b2..0000000
+++ /dev/null
@@ -1,38 +0,0 @@
-#include <msp/fs/dir.h>
-#include <msp/fs/stat.h>
-#include <msp/fs/utils.h>
-#include "task.h"
-
-using namespace Msp;
-
-Task::Task():
-       unlink(false)
-{ }
-
-void Task::set_file(const FS::Path &f)
-{
-       file = f;
-}
-
-void Task::set_unlink(bool u)
-{
-       unlink = u;
-}
-
-void Task::prepare()
-{
-       if(!file.empty())
-       {
-               if(FS::exists(file))
-               {
-                       // If the file exists, the directory it's in must exist too
-                       FS::unlink(file);
-               }
-               else
-               {
-                       FS::Path dir = FS::dirname(file);
-                       if(!FS::exists(dir))
-                               FS::mkpath(dir, 0755);
-               }
-       }
-}