summaryrefslogtreecommitdiffhomepage
path: root/DotDir.hs
diff options
context:
space:
mode:
Diffstat (limited to 'DotDir.hs')
-rw-r--r--DotDir.hs12
1 files changed, 12 insertions, 0 deletions
diff --git a/DotDir.hs b/DotDir.hs
new file mode 100644
index 0000000..f6dbb58
--- /dev/null
+++ b/DotDir.hs
@@ -0,0 +1,12 @@
+module DotDir where
+
+import System.Posix
+import System.Directory
+import System.FilePath
+
+dotDir :: IO FilePath
+dotDir = do
+ home <- homeDirectory <$> (getUserEntryForID =<< getEffectiveUserID)
+ let dir = home </> ".debug-me"
+ createDirectoryIfMissing False dir
+ return dir