summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--tv/2configs/xserver/default.nix7
-rw-r--r--tv/5pkgs/haskell/xmonad-tv/src/Paths.hs3
-rw-r--r--tv/5pkgs/haskell/xmonad-tv/src/main.hs7
3 files changed, 16 insertions, 1 deletions
diff --git a/tv/2configs/xserver/default.nix b/tv/2configs/xserver/default.nix
index 357744533..4e9e30741 100644
--- a/tv/2configs/xserver/default.nix
+++ b/tv/2configs/xserver/default.nix
@@ -108,6 +108,13 @@ in {
};
path = [
config.tv.slock.package
+ (pkgs.flameshot-once.override {
+ config.imgur.enable = true;
+ config.imgur.createUrl = "http://ni.r/image";
+ config.imgur.deleteUrl = "http://ni.r/image/delete/%1";
+ config.imgur.xdg-open.browser = "/etc/profiles/per-user/tv/bin/cr";
+ config.timeout = 200;
+ })
pkgs.fzmenu
pkgs.pulseaudioLight.out
pkgs.rxvt_unicode
diff --git a/tv/5pkgs/haskell/xmonad-tv/src/Paths.hs b/tv/5pkgs/haskell/xmonad-tv/src/Paths.hs
index dd21511b4..6b7235530 100644
--- a/tv/5pkgs/haskell/xmonad-tv/src/Paths.hs
+++ b/tv/5pkgs/haskell/xmonad-tv/src/Paths.hs
@@ -3,6 +3,9 @@ module Paths where
import Helpers.Path
+flameshot :: FilePath
+flameshot = findExecutable "flameshot-once"
+
otpmenu :: FilePath
otpmenu = findExecutable "otpmenu"
diff --git a/tv/5pkgs/haskell/xmonad-tv/src/main.hs b/tv/5pkgs/haskell/xmonad-tv/src/main.hs
index 400c87ab9..047239eb7 100644
--- a/tv/5pkgs/haskell/xmonad-tv/src/main.hs
+++ b/tv/5pkgs/haskell/xmonad-tv/src/main.hs
@@ -22,7 +22,8 @@ import qualified XMonad.StackSet as W
import Data.Map (Map)
import qualified Data.Map as Map
import XMonad.Hooks.UrgencyHook (SpawnUrgencyHook(..), withUrgencyHook)
-import XMonad.Hooks.ManageHelpers (doCenterFloat)
+import XMonad.Hooks.ManageHelpers (doCenterFloat,doRectFloat)
+import Data.Ratio
import XMonad.Hooks.Place (placeHook, smart)
import XMonad.Actions.PerWorkspaceKeys (chooseAction)
@@ -66,6 +67,8 @@ mainNoArgs = do
composeAll
[ appName =? "fzmenu-urxvt" --> doCenterFloat
, appName =? "pinentry" --> doCenterFloat
+ , title =? "Upload to Imgur" -->
+ doRectFloat (W.RationalRect 0 0 (1 % 8) (1 % 8))
, placeHook (smart (1,0))
]
, startupHook =
@@ -163,6 +166,8 @@ myKeys conf = Map.fromList $
, ((_4, xF86XK_AudioMute), pavucontrol [])
, ((_4, xK_Prior), forkFile Paths.xcalib ["-invert", "-alter"] Nothing)
+
+ , ((0, xK_Print), forkFile Paths.flameshot [] Nothing)
]
where
_4 = mod4Mask