mirror of
https://gitlab.com/dwt1/dotfiles.git
synced 2026-04-24 12:00:24 +10:00
Restructing the entire dotfile repo!
This commit is contained in:
22
.config/openbox/pipemenus/obrecent.sh
Executable file
22
.config/openbox/pipemenus/obrecent.sh
Executable file
@@ -0,0 +1,22 @@
|
||||
From Openbox
|
||||
Jump to: navigation, search
|
||||
|
||||
#!/bin/sh
|
||||
echo "<openbox_pipe_menu>"
|
||||
files=$(
|
||||
cat ~/.local/share/recently-used.xbel | grep file:/// | tail -n15 | cut -d "\"" -f 2 | tac | while read line;
|
||||
do
|
||||
file=$(echo "$line")
|
||||
name=$(echo -en "$file" | sed 's,.*/,,' | sed 's/%20/ /g')
|
||||
echo "<item label=\"$name\">
|
||||
<action name=\"Execute\"><command>xdg-open $line</command></action>
|
||||
</item>"
|
||||
done);
|
||||
echo "$files"
|
||||
echo "<separator />"
|
||||
echo "<item label=\"Clear Recent Documents\">
|
||||
<action name=\"Execute\"><command>rm ~/.local/share/recently-used.xbel</command></action>
|
||||
</item>"
|
||||
echo "</openbox_pipe_menu>"
|
||||
|
||||
|
||||
Reference in New Issue
Block a user