2018-05-26 17:08:13 +02:00
|
|
|
module Projects (
|
|
|
|
Projects.modify
|
|
|
|
) where
|
|
|
|
|
|
|
|
import XMonad
|
|
|
|
import XMonad.Actions.DynamicProjects
|
2019-04-17 16:14:19 +02:00
|
|
|
import XMonad.Util.Run
|
2018-05-26 17:08:13 +02:00
|
|
|
|
2022-02-19 16:24:39 +01:00
|
|
|
term = "kitty"
|
2020-12-26 10:05:29 +01:00
|
|
|
|
2022-02-19 16:24:39 +01:00
|
|
|
spawnGuiTextEditor :: X ()
|
2021-12-09 22:09:00 +01:00
|
|
|
spawnGuiTextEditor = safeSpawn "vim" ["-g"]
|
|
|
|
|
2020-12-26 10:05:29 +01:00
|
|
|
singleTermAppWithName :: String -> String -> Project
|
|
|
|
singleTermAppWithName name app = Project
|
|
|
|
{ projectName = name
|
|
|
|
, projectDirectory = "/tmp"
|
2022-02-19 16:24:39 +01:00
|
|
|
, projectStartHook = Just $ do safeSpawn term ["zsh","-c",app]
|
2020-12-26 10:05:29 +01:00
|
|
|
}
|
|
|
|
|
2021-10-05 22:40:55 +02:00
|
|
|
singleAppWithName :: String -> String -> Project
|
|
|
|
singleAppWithName name app = Project
|
2020-12-26 10:05:29 +01:00
|
|
|
{ projectName = name
|
2020-11-07 08:04:05 +01:00
|
|
|
, projectDirectory = "/tmp"
|
2021-10-05 22:40:55 +02:00
|
|
|
, projectStartHook = Just $ do spawn app
|
2020-11-07 08:04:05 +01:00
|
|
|
}
|
|
|
|
|
2020-12-26 10:05:29 +01:00
|
|
|
singleApp :: String -> Project
|
|
|
|
singleApp app = singleAppWithName app app
|
|
|
|
|
2018-05-26 17:08:13 +02:00
|
|
|
projects :: [Project]
|
2019-09-28 14:55:07 +02:00
|
|
|
projects =
|
2021-10-05 22:40:55 +02:00
|
|
|
[ singleApp "carla"
|
2021-05-30 12:07:01 +02:00
|
|
|
, singleApp "obs"
|
2021-10-05 22:40:55 +02:00
|
|
|
, singleApp "patchage"
|
|
|
|
, singleApp "reaper"
|
|
|
|
, singleApp "renoise"
|
2022-04-17 07:32:44 +02:00
|
|
|
, singleApp "mixxx"
|
2021-04-18 14:50:37 +02:00
|
|
|
, singleAppWithName "Books" "calibre"
|
2021-05-06 16:23:24 +02:00
|
|
|
, singleAppWithName "discord" "Discord"
|
2022-10-01 12:43:06 +02:00
|
|
|
, singleAppWithName "matrix" "cinny"
|
2021-03-30 17:46:00 +02:00
|
|
|
, singleAppWithName "signal" "signal-desktop"
|
2021-10-05 22:40:55 +02:00
|
|
|
, singleAppWithName "vcv" "Rack"
|
2020-12-26 10:05:29 +01:00
|
|
|
, singleTermAppWithName "email" "neomutt"
|
2020-11-07 08:04:05 +01:00
|
|
|
, Project { projectName = "admin"
|
2021-01-06 09:51:39 +01:00
|
|
|
, projectDirectory = "~/admin/nixos-config"
|
2021-12-09 22:09:00 +01:00
|
|
|
, projectStartHook = Just $ do spawnGuiTextEditor
|
2021-01-06 09:51:39 +01:00
|
|
|
safeSpawnProg term
|
|
|
|
}
|
2021-03-30 17:46:00 +02:00
|
|
|
, Project { projectName = "overlays-personal"
|
|
|
|
, projectDirectory = "~/admin/overlays-personal"
|
2021-12-09 22:09:00 +01:00
|
|
|
, projectStartHook = Just $ do spawnGuiTextEditor
|
2021-03-30 17:46:00 +02:00
|
|
|
safeSpawnProg term
|
|
|
|
}
|
2021-11-04 19:41:24 +01:00
|
|
|
, Project { projectName = "steam"
|
|
|
|
, projectDirectory = "/tmp"
|
|
|
|
, projectStartHook = Just $ safeSpawn "steam" ["-pipewire"]
|
|
|
|
}
|
2021-11-13 20:47:36 +01:00
|
|
|
, Project { projectName = "youtube"
|
|
|
|
, projectDirectory = "/tmp"
|
2021-12-09 22:09:00 +01:00
|
|
|
, projectStartHook = Just $ safeSpawn "chromium"
|
|
|
|
["--app=youtube.com"
|
|
|
|
,"--incognito"]
|
2021-11-13 20:47:36 +01:00
|
|
|
}
|
2021-01-06 09:51:39 +01:00
|
|
|
, Project { projectName = "cdc-config"
|
|
|
|
, projectDirectory = "~/admin/cdc-config"
|
2021-12-09 22:09:00 +01:00
|
|
|
, projectStartHook = Just $ do spawnGuiTextEditor
|
2020-12-26 10:05:29 +01:00
|
|
|
safeSpawnProg term
|
2020-03-28 16:41:16 +01:00
|
|
|
}
|
2021-10-05 22:40:55 +02:00
|
|
|
, Project { projectName = "cdc-documentation"
|
|
|
|
, projectDirectory = "~/admin/cdc-documentation"
|
|
|
|
, projectStartHook = Just $ do
|
|
|
|
safeSpawnProg term
|
2021-12-09 22:09:00 +01:00
|
|
|
spawnGuiTextEditor
|
|
|
|
}
|
|
|
|
, Project { projectName = "adventOfCode"
|
|
|
|
, projectDirectory = "~/candy/adventofcode"
|
|
|
|
, projectStartHook = Just $ do
|
|
|
|
safeSpawnProg term
|
|
|
|
spawnGuiTextEditor
|
2021-10-05 22:40:55 +02:00
|
|
|
}
|
2021-05-06 16:23:24 +02:00
|
|
|
, Project { projectName = "rukokuoppa"
|
|
|
|
, projectDirectory = "~/candy/rukokuoppa"
|
2021-12-09 22:09:00 +01:00
|
|
|
, projectStartHook = Just $ do spawnGuiTextEditor
|
2021-05-06 16:23:24 +02:00
|
|
|
safeSpawnProg term
|
|
|
|
}
|
2020-03-28 16:41:16 +01:00
|
|
|
, Project { projectName = "notes"
|
|
|
|
, projectDirectory = "~/zk"
|
2022-02-19 16:24:39 +01:00
|
|
|
, projectStartHook = Just $ do safeSpawnProg "logseq"
|
2020-12-26 10:05:29 +01:00
|
|
|
}
|
|
|
|
, Project { projectName = "xmonad"
|
|
|
|
, projectDirectory = "~/.xmonad"
|
2021-12-09 22:09:00 +01:00
|
|
|
, projectStartHook = Just $ do spawnGuiTextEditor
|
2021-07-15 18:20:30 +02:00
|
|
|
safeSpawnProg term
|
|
|
|
}
|
|
|
|
, Project { projectName = "waymonad"
|
|
|
|
, projectDirectory = "~/candy/waymonad"
|
2021-12-09 22:09:00 +01:00
|
|
|
, projectStartHook = Just $ do spawnGuiTextEditor
|
2020-12-26 10:05:29 +01:00
|
|
|
safeSpawnProg term
|
2019-09-28 14:55:07 +02:00
|
|
|
}
|
2020-03-07 16:53:04 +01:00
|
|
|
, Project { projectName = "accounting"
|
|
|
|
, projectDirectory = "~/accounting"
|
2020-12-26 10:05:29 +01:00
|
|
|
, projectStartHook = Just $ do safeSpawnProg term
|
2020-03-07 16:53:04 +01:00
|
|
|
}
|
2019-09-28 14:55:07 +02:00
|
|
|
, Project { projectName = "flim"
|
|
|
|
, projectDirectory = "/flims/rtorrent/download"
|
2020-12-26 10:05:29 +01:00
|
|
|
, projectStartHook = Just $ do safeSpawnProg term
|
2019-09-28 14:55:07 +02:00
|
|
|
}
|
|
|
|
, Project { projectName = "sound"
|
|
|
|
, projectDirectory = "/tmp"
|
|
|
|
, projectStartHook = Just $ do safeSpawnProg "pavucontrol"
|
|
|
|
}
|
|
|
|
, Project { projectName = "web"
|
|
|
|
, projectDirectory = "/tmp"
|
|
|
|
, projectStartHook = Just $ do spawn "firefox"
|
|
|
|
}
|
|
|
|
]
|
2018-05-26 17:08:13 +02:00
|
|
|
|
|
|
|
modify :: XConfig l -> XConfig l
|
|
|
|
modify conf = dynamicProjects projects conf
|
2018-05-28 19:53:36 +02:00
|
|
|
{ workspaces = [] }
|
2018-05-26 17:08:13 +02:00
|
|
|
|