about summary refs log tree commit diff
diff options
context:
space:
mode:
-rw-r--r--awesome/.config/awesome/rc.lua32
-rw-r--r--debian/.bashrc6
2 files changed, 22 insertions, 16 deletions
diff --git a/awesome/.config/awesome/rc.lua b/awesome/.config/awesome/rc.lua
index 1e8432f..66deb1a 100644
--- a/awesome/.config/awesome/rc.lua
+++ b/awesome/.config/awesome/rc.lua
@@ -60,9 +60,9 @@ local slock_suspend = "slock systemctl --ignore-inhibitors suspend"
 -- Audacious media player
 local audacious_main_window = "audacious --show-main-window"
 local audacious_jump_box = "audacious --show-jump-box"
-local audacious_play_pause = "audacious --play-pause"
-local audacious_rewind = "audacious --rew"
-local audacious_forward = "audacious --fwd"
+local play_pause = "playerctl play-pause"
+local rewind = "playerctl previous"
+local forward = "playerctl next"
 
 local scrot = "scrot /home/cnx/Desktop/%FT%T.png"
 local scrot_select = "scrot --border --select /home/cnx/Desktop/%FT%T.png"
@@ -228,20 +228,20 @@ awful.spawn.with_line_callback(
    end}
 )
 
-local function audacious_seeker(time)
+local function seeker(time, sign)
   return function ()
-    awful.spawn(("audtool playback-seek-relative %f"):format(time))
+    awful.spawn(("playerctl position %f%s"):format(time, sign))
   end
 end
 
 local myplayer = wibox.container.background(myplayer_text, beautiful.magenta)
 myplayer.fg = beautiful.gray
 myplayer:buttons(awful.util.table.join(
-  awful.button({}, 1, spawner(audacious_rewind)),
-  awful.button({}, 2, spawner(audacious_play_pause)),
-  awful.button({}, 3, spawner(audacious_forward)),
-  awful.button({}, 4, audacious_seeker(1)),
-  awful.button({}, 5, audacious_seeker(-1))
+  awful.button({}, 1, spawner(rewind)),
+  awful.button({}, 2, spawner(play_pause)),
+  awful.button({}, 3, spawner(forward)),
+  awful.button({}, 4, seeker(1, "+")),
+  awful.button({}, 5, seeker(1, "-"))
 ))
 
 -- Create a weather widget
@@ -502,17 +502,17 @@ local globalkeys = awful.util.table.join(
             {description = "Audacious: jump-to-song", group = "multimedia"}),
   awful.key({modkey, "Shift"}, "a", spawner(audacious_main_window),
             {description = "Audacious: main window", group = "launcher"}),
-  awful.key({modkey, "Control"}, "a", spawner(audacious_play_pause),
+  awful.key({modkey, "Control"}, "a", spawner(play_pause),
             {description = "Audacious: play/pause", group = "multimedia"}),
-  awful.key({modkey}, "Up", spawner(audacious_rewind),
+  awful.key({modkey}, "Up", spawner(rewind),
             {description = "Audacious: previous track", group = "multimedia"}),
-  awful.key({modkey}, "Down", spawner(audacious_forward),
+  awful.key({modkey}, "Down", spawner(forward),
             {description = "Audacious: next track", group = "multimedia"}),
-  awful.key({}, "XF86AudioPlay", spawner(audacious_play_pause),
+  awful.key({}, "XF86AudioPlay", spawner(play_pause),
             {description = "Audacious: jump-to-song", group = "multimedia"}),
-  awful.key({}, "XF86AudioPrev", spawner(audacious_rewind),
+  awful.key({}, "XF86AudioPrev", spawner(rewind),
             {description = "Audacious: previous track", group = "multimedia"}),
-  awful.key({}, "XF86AudioNext", spawner(audacious_forward),
+  awful.key({}, "XF86AudioNext", spawner(forward),
             {description = "Audacious: next track", group = "multimedia"}),
   awful.key({}, "XF86Display", spawner"arandr",
             {description = "open Arandr", group = "multimedia"}),
diff --git a/debian/.bashrc b/debian/.bashrc
index f8f277b..70eba5c 100644
--- a/debian/.bashrc
+++ b/debian/.bashrc
@@ -108,6 +108,12 @@ function ipfs-cors {
   systemctl restart --user ipfs
 }
 
+function expose-anbox {
+  systemctl --user restart anbox-session-manager.service
+  adb kill-server
+  adb start-server
+}
+
 # enable programmable completion features (you don't need to enable
 # this, if it's already enabled in /etc/bash.bashrc and /etc/profile
 # sources /etc/bash.bashrc).