Changes
This commit is contained in:
parent
9f4a11f2e0
commit
9ed520abc2
19
archive.sh
19
archive.sh
@ -1,7 +1,8 @@
|
||||
#!/bin/bash
|
||||
|
||||
dir=$PWD
|
||||
dir="$PWD"
|
||||
scripts_subdir="$PWD/scripts"
|
||||
config="${dir}/config"
|
||||
|
||||
# rsync -a ~/pictures/wallpapers/* wallpapers/
|
||||
|
||||
@ -11,13 +12,13 @@ rsync -a \
|
||||
--exclude 'quickmarks' \
|
||||
--exclude 'qsettings' \
|
||||
--exclude 'autoconfig.yml' \
|
||||
~/.config/qutebrowser .
|
||||
rsync -a ~/.config/vesktop/settings ./vesktop
|
||||
rsync -a ~/.config/bspwm .
|
||||
rsync -a ~/.config/sxhkd .
|
||||
~/.config/qutebrowser "$config"
|
||||
rsync -a ~/.config/vesktop/settings "${config}/vesktop"
|
||||
rsync -a ~/.config/bspwm "$config"
|
||||
rsync -a ~/.config/sxhkd "$config"
|
||||
rsync -a ~/.config/xfce4 \
|
||||
--exclude 'desktop' .
|
||||
rsync -a ~/.config/rofi .
|
||||
--exclude 'desktop' "$config"
|
||||
rsync -a ~/.config/rofi "$config"
|
||||
# cp ~/.config/picom.conf .
|
||||
|
||||
cd ~/bin || exit
|
||||
@ -35,8 +36,10 @@ le-wallpaper-open \
|
||||
xfce4-le-wallpaper \
|
||||
qutebrowser \
|
||||
qutesearch \
|
||||
mdread \
|
||||
rack \
|
||||
f \
|
||||
"$scripts_subdir"
|
||||
cd "$dir" || exit
|
||||
|
||||
cd "$dir"
|
||||
cp -r ~/.local/share/qutebrowser/userscripts "${dir}/local/share/qutebrowser"
|
||||
|
@ -3,8 +3,7 @@
|
||||
wmname LG3D &
|
||||
|
||||
# START MONITOR BLOCK
|
||||
bspc monitor HDMI-1 -d I II III IV
|
||||
bspc monitor eDP-1 -d eDP-1
|
||||
bspc monitor HDMI-1 -d I II III IV V
|
||||
# END MONITOR BLOCK
|
||||
|
||||
bsp-key-daemon
|
||||
|
@ -1,3 +1,3 @@
|
||||
bspc config normal_border_color "#3c3f4c"
|
||||
bspc config active_border_color "#383a47"
|
||||
bspc config focused_border_color "#555e70"
|
||||
bspc config normal_border_color "#4a4543"
|
||||
bspc config active_border_color "#5c5855"
|
||||
bspc config focused_border_color "#807d7c"
|
||||
|
@ -1,27 +1,27 @@
|
||||
# :root {
|
||||
# --vii: #22262d;
|
||||
# --vi: #383a47;
|
||||
# --v: #ff29a8;
|
||||
# --iv: #8b9cbe;
|
||||
# --iiv: #f4f4f7;
|
||||
# --a: #8265ff;
|
||||
# --vii: #3a3432;
|
||||
# --vi: #5c5855;
|
||||
# --v: #db2d20;
|
||||
# --iv: #a5a2a2;
|
||||
# --iiv: #f7f7f7;
|
||||
# --a: #b5e4f4;
|
||||
# }
|
||||
|
||||
:root {
|
||||
--base00: #17191E;
|
||||
--base01: #22262d;
|
||||
--base02: #3c3f4c;
|
||||
--base03: #383a47;
|
||||
--base04: #555e70;
|
||||
--base05: #8b9cbe;
|
||||
--base06: #B2BFD9;
|
||||
--base07: #f4f4f7;
|
||||
--base08: #ff29a8;
|
||||
--base09: #85ffe0;
|
||||
--base0A: #f0ffaa;
|
||||
--base0B: #0badff;
|
||||
--base0C: #8265ff;
|
||||
--base0D: #00eaff;
|
||||
--base0E: #00f6d9;
|
||||
--base0F: #ff3d81;
|
||||
--base00: #090300;
|
||||
--base01: #3a3432;
|
||||
--base02: #4a4543;
|
||||
--base03: #5c5855;
|
||||
--base04: #807d7c;
|
||||
--base05: #a5a2a2;
|
||||
--base06: #d6d5d4;
|
||||
--base07: #f7f7f7;
|
||||
--base08: #db2d20;
|
||||
--base09: #e8bbd0;
|
||||
--base0A: #fded02;
|
||||
--base0B: #01a252;
|
||||
--base0C: #b5e4f4;
|
||||
--base0D: #01a0e4;
|
||||
--base0E: #a16a94;
|
||||
--base0F: #cdab53;
|
||||
}
|
||||
|
@ -13,8 +13,8 @@ c.content.autoplay = False
|
||||
|
||||
config.bind('h', 'back')
|
||||
config.bind('l', 'forward')
|
||||
config.bind('j', 'scroll-page 0 1')
|
||||
config.bind('k', 'scroll-page 0 -1')
|
||||
config.bind('j', 'scroll-page 0 0.6')
|
||||
config.bind('k', 'scroll-page 0 -0.6')
|
||||
|
||||
config.bind('gp', 'mode-enter passthrough')
|
||||
|
||||
@ -25,12 +25,18 @@ c.hints.selectors["bookmarks"] = [
|
||||
"h4[id]",
|
||||
"h5[id]",
|
||||
"h6[id]",
|
||||
"h1 > a[id]",
|
||||
"h2 > a[id]",
|
||||
"h3 > a[id]",
|
||||
"h4 > a[id]",
|
||||
"h5 > a[id]",
|
||||
"h6 > a[id]",
|
||||
"h1 a[id]",
|
||||
"h2 a[id]",
|
||||
"h3 a[id]",
|
||||
"h4 a[id]",
|
||||
"h5 a[id]",
|
||||
"h6 a[id]",
|
||||
"h1 span[id]",
|
||||
"h2 span[id]",
|
||||
"h3 span[id]",
|
||||
"h4 span[id]",
|
||||
"h5 span[id]",
|
||||
"h6 span[id]",
|
||||
"header[id]",
|
||||
"footer[id]",
|
||||
"article[id]",
|
||||
@ -49,22 +55,22 @@ c.content.user_stylesheets = "base16.css"
|
||||
# Template author: theova
|
||||
# Commentary: Tinted Theming: (https://github.com/tinted-theming)
|
||||
|
||||
base00 = "#17191E"
|
||||
base01 = "#22262d"
|
||||
base02 = "#3c3f4c"
|
||||
base03 = "#383a47"
|
||||
base04 = "#555e70"
|
||||
base05 = "#8b9cbe"
|
||||
base06 = "#B2BFD9"
|
||||
base07 = "#f4f4f7"
|
||||
base08 = "#ff29a8"
|
||||
base09 = "#85ffe0"
|
||||
base0A = "#f0ffaa"
|
||||
base0B = "#0badff"
|
||||
base0C = "#8265ff"
|
||||
base0D = "#00eaff"
|
||||
base0E = "#00f6d9"
|
||||
base0F = "#ff3d81"
|
||||
base00 = "#090300"
|
||||
base01 = "#3a3432"
|
||||
base02 = "#4a4543"
|
||||
base03 = "#5c5855"
|
||||
base04 = "#807d7c"
|
||||
base05 = "#a5a2a2"
|
||||
base06 = "#d6d5d4"
|
||||
base07 = "#f7f7f7"
|
||||
base08 = "#db2d20"
|
||||
base09 = "#e8bbd0"
|
||||
base0A = "#fded02"
|
||||
base0B = "#01a252"
|
||||
base0C = "#b5e4f4"
|
||||
base0D = "#01a0e4"
|
||||
base0E = "#a16a94"
|
||||
base0F = "#cdab53"
|
||||
|
||||
# set qutebrowser colors
|
||||
|
||||
|
@ -7,13 +7,13 @@
|
||||
*/
|
||||
|
||||
* {
|
||||
red: rgba ( 255, 41, 168, 100 % );
|
||||
blue: rgba ( 0, 234, 255, 100 % );
|
||||
lightfg: rgba ( 178, 191, 217, 100 % );
|
||||
lightbg: rgba ( 34, 38, 45, 100 % );
|
||||
foreground: rgba ( 139, 156, 190, 100 % );
|
||||
background: rgba ( 23, 25, 30, 100 % );
|
||||
background-color: rgba ( 23, 25, 30, 0 % );
|
||||
red: rgba ( 219, 45, 32, 100 % );
|
||||
blue: rgba ( 1, 160, 228, 100 % );
|
||||
lightfg: rgba ( 214, 213, 212, 100 % );
|
||||
lightbg: rgba ( 58, 52, 50, 100 % );
|
||||
foreground: rgba ( 165, 162, 162, 100 % );
|
||||
background: rgba ( 9, 3, 0, 100 % );
|
||||
background-color: rgba ( 9, 3, 0, 0 % );
|
||||
separatorcolor: @foreground;
|
||||
border-color: @foreground;
|
||||
selected-normal-foreground: @lightbg;
|
||||
|
@ -49,11 +49,11 @@ super + v
|
||||
|
||||
# Exit session
|
||||
super + q
|
||||
xfce4-session-logout
|
||||
xflock4
|
||||
|
||||
# Lock screen
|
||||
super + shift + q
|
||||
xflock4
|
||||
xfce4-session-logout
|
||||
|
||||
# Open task manager
|
||||
super + t
|
||||
@ -61,8 +61,9 @@ super + t
|
||||
bsp-float xfce4-taskmanager
|
||||
|
||||
# Screenshot region
|
||||
super + Print
|
||||
xfce4-screenshooter -r
|
||||
XF86Launch5
|
||||
flameshot gui
|
||||
# xfce4-screenshooter -r
|
||||
|
||||
# Manage audio profiles[57362;10u]
|
||||
super + shift + Pause
|
||||
|
@ -186,9 +186,6 @@
|
||||
"GreetStickerPicker": {
|
||||
"enabled": false
|
||||
},
|
||||
"HideAttachments": {
|
||||
"enabled": false
|
||||
},
|
||||
"iLoveSpam": {
|
||||
"enabled": false
|
||||
},
|
||||
@ -570,6 +567,9 @@
|
||||
},
|
||||
"UserMessagesPronouns": {
|
||||
"enabled": false
|
||||
},
|
||||
"HideMedia": {
|
||||
"enabled": false
|
||||
}
|
||||
},
|
||||
"notifications": {
|
||||
@ -582,6 +582,7 @@
|
||||
"authenticated": false,
|
||||
"url": "https://api.vencord.dev/",
|
||||
"settingsSync": false,
|
||||
"settingsSyncVersion": 1731937700893
|
||||
}
|
||||
"settingsSyncVersion": 1739774681370
|
||||
},
|
||||
"eagerPatches": false
|
||||
}
|
@ -1,13 +1,13 @@
|
||||
[Configuration]
|
||||
ColorForeground=#8b9cbe
|
||||
ColorBackground=#17191E
|
||||
ColorCursor=#8265ff
|
||||
ColorSelection=#17191E
|
||||
ColorBold=#8b9cbe
|
||||
ColorForeground=#a5a2a2
|
||||
ColorBackground=#090300
|
||||
ColorCursor=#b5e4f4
|
||||
ColorSelection=#090300
|
||||
ColorBold=#a5a2a2
|
||||
ColorBoldUseDefault=FALSE
|
||||
ColorPalette=#17191E;#ff29a8;#0badff;#f0ffaa;#00eaff;#00f6d9;#8265ff;#8b9cbe;#383a47;#ff29a8;#0badff;#f0ffaa;#00eaff;#00f6d9;#8265ff;#f4f4f7
|
||||
TabActivityColor=#f0ffaa
|
||||
FontName=DejaVu Sans Mono 11
|
||||
ColorPalette=#090300;#db2d20;#01a252;#fded02;#01a0e4;#a16a94;#b5e4f4;#a5a2a2;#5c5855;#db2d20;#01a252;#fded02;#01a0e4;#a16a94;#b5e4f4;#f7f7f7
|
||||
TabActivityColor=#fded02
|
||||
FontName=DejaVu Sans Mono 13
|
||||
MiscAlwaysShowTabs=FALSE
|
||||
MiscBell=FALSE
|
||||
MiscBellUrgent=FALSE
|
||||
|
@ -20,14 +20,14 @@
|
||||
<property name="Y" type="int" value="0"/>
|
||||
</property>
|
||||
</property>
|
||||
<property name="HDMI-1" type="string" value="Lenovo 22"">
|
||||
<property name="HDMI-1" type="string" value="LG 72"">
|
||||
<property name="Active" type="bool" value="true"/>
|
||||
<property name="EDID" type="string" value="c89931af72068948d9206fa7f80f34bb90faeb1d"/>
|
||||
<property name="Resolution" type="string" value="1920x1080"/>
|
||||
<property name="RefreshRate" type="double" value="60"/>
|
||||
<property name="EDID" type="string" value="798e7beefc07f4d7c9dd87f70fd5a408ac3ace59"/>
|
||||
<property name="Resolution" type="string" value="2560x1440"/>
|
||||
<property name="RefreshRate" type="double" value="59.950550105254798"/>
|
||||
<property name="Rotation" type="int" value="0"/>
|
||||
<property name="Reflection" type="string" value="0"/>
|
||||
<property name="Primary" type="bool" value="true"/>
|
||||
<property name="Primary" type="bool" value="false"/>
|
||||
<property name="Scale" type="empty">
|
||||
<property name="X" type="double" value="1"/>
|
||||
<property name="Y" type="double" value="1"/>
|
||||
@ -40,7 +40,7 @@
|
||||
</property>
|
||||
<property name="Fallback" type="empty">
|
||||
<property name="eDP-1" type="string" value="Laptop">
|
||||
<property name="Active" type="bool" value="true"/>
|
||||
<property name="Active" type="bool" value="false"/>
|
||||
<property name="EDID" type="string" value="b523bc2cb14c5b55f5ea3aa234181e999627d08e"/>
|
||||
<property name="Resolution" type="string" value="1920x1080"/>
|
||||
<property name="RefreshRate" type="double" value="60.002344822965867"/>
|
||||
@ -56,14 +56,14 @@
|
||||
<property name="Y" type="int" value="0"/>
|
||||
</property>
|
||||
</property>
|
||||
<property name="HDMI-1" type="string" value="Lenovo 22"">
|
||||
<property name="HDMI-1" type="string" value="LG 72"">
|
||||
<property name="Active" type="bool" value="true"/>
|
||||
<property name="EDID" type="string" value="c89931af72068948d9206fa7f80f34bb90faeb1d"/>
|
||||
<property name="Resolution" type="string" value="1920x1080"/>
|
||||
<property name="RefreshRate" type="double" value="60"/>
|
||||
<property name="EDID" type="string" value="798e7beefc07f4d7c9dd87f70fd5a408ac3ace59"/>
|
||||
<property name="Resolution" type="string" value="2560x1440"/>
|
||||
<property name="RefreshRate" type="double" value="59.950550105254798"/>
|
||||
<property name="Rotation" type="int" value="0"/>
|
||||
<property name="Reflection" type="string" value="0"/>
|
||||
<property name="Primary" type="bool" value="true"/>
|
||||
<property name="Primary" type="bool" value="false"/>
|
||||
<property name="Scale" type="empty">
|
||||
<property name="X" type="double" value="1"/>
|
||||
<property name="Y" type="double" value="1"/>
|
||||
|
@ -9,14 +9,14 @@
|
||||
<property name="shortcuts-icon-size" type="empty"/>
|
||||
<property name="last-view" type="string" value="ThunarDetailsView"/>
|
||||
<property name="last-icon-view-zoom-level" type="string" value="THUNAR_ZOOM_LEVEL_100_PERCENT"/>
|
||||
<property name="last-window-width" type="int" value="876"/>
|
||||
<property name="last-window-height" type="int" value="1045"/>
|
||||
<property name="last-window-width" type="int" value="598"/>
|
||||
<property name="last-window-height" type="int" value="1039"/>
|
||||
<property name="last-window-maximized" type="bool" value="false"/>
|
||||
<property name="last-separator-position" type="int" value="170"/>
|
||||
<property name="last-show-hidden" type="bool" value="true"/>
|
||||
<property name="last-details-view-zoom-level" type="string" value="THUNAR_ZOOM_LEVEL_25_PERCENT"/>
|
||||
<property name="last-details-view-visible-columns" type="string" value="THUNAR_COLUMN_DATE_MODIFIED,THUNAR_COLUMN_NAME,THUNAR_COLUMN_SIZE,THUNAR_COLUMN_TYPE"/>
|
||||
<property name="last-details-view-column-widths" type="string" value="50,50,106,50,73,217,50,50,284,50,50,65,50,356"/>
|
||||
<property name="last-details-view-column-widths" type="string" value="50,50,124,50,73,74,50,50,340,50,50,77,50,440"/>
|
||||
<property name="last-sort-column" type="string" value="THUNAR_COLUMN_DATE_MODIFIED"/>
|
||||
<property name="last-sort-order" type="string" value="GTK_SORT_DESCENDING"/>
|
||||
</channel>
|
||||
|
@ -35,8 +35,8 @@
|
||||
</property>
|
||||
</property>
|
||||
<property name="last" type="empty">
|
||||
<property name="window-height" type="int" value="1045"/>
|
||||
<property name="window-width" type="int" value="990"/>
|
||||
<property name="window-height" type="int" value="1039"/>
|
||||
<property name="window-width" type="int" value="1910"/>
|
||||
<property name="pane-position" type="int" value="180"/>
|
||||
</property>
|
||||
</channel>
|
||||
|
@ -73,7 +73,7 @@
|
||||
<property name="show" type="empty"/>
|
||||
</property>
|
||||
<property name="last" type="empty">
|
||||
<property name="window-width" type="int" value="815"/>
|
||||
<property name="window-height" type="int" value="599"/>
|
||||
<property name="window-width" type="int" value="929"/>
|
||||
<property name="window-height" type="int" value="842"/>
|
||||
</property>
|
||||
</channel>
|
||||
|
@ -22,7 +22,7 @@
|
||||
<value type="int" value="10"/>
|
||||
</property>
|
||||
<property name="background-style" type="uint" value="0"/>
|
||||
<property name="size" type="uint" value="24"/>
|
||||
<property name="size" type="uint" value="30"/>
|
||||
<property name="length-adjust" type="bool" value="true"/>
|
||||
<property name="span-monitors" type="bool" value="false"/>
|
||||
<property name="mode" type="uint" value="0"/>
|
||||
@ -39,6 +39,8 @@
|
||||
<value type="string" value="xfce4-terminal-emulator.desktop"/>
|
||||
</property>
|
||||
<property name="recent" type="array">
|
||||
<value type="string" value="org.gnome.LightsOff.desktop"/>
|
||||
<value type="string" value="org.gnome.Hitori.desktop"/>
|
||||
<value type="string" value="panel-preferences.desktop"/>
|
||||
<value type="string" value="xfce-display-settings.desktop"/>
|
||||
<value type="string" value="xfce-backdrop-settings.desktop"/>
|
||||
@ -47,8 +49,6 @@
|
||||
<value type="string" value="xfce4-file-manager.desktop"/>
|
||||
<value type="string" value="xfce-keyboard-settings.desktop"/>
|
||||
<value type="string" value="xfce4-accessibility-settings.desktop"/>
|
||||
<value type="string" value="xfce-ui-settings.desktop"/>
|
||||
<value type="string" value="discord.desktop"/>
|
||||
</property>
|
||||
</property>
|
||||
<property name="plugin-2" type="string" value="separator">
|
||||
@ -85,7 +85,7 @@
|
||||
<property name="enable-keyboard-shortcuts" type="bool" value="true"/>
|
||||
<property name="enable-mpris" type="bool" value="true"/>
|
||||
<property name="enable-wnck" type="bool" value="true"/>
|
||||
<property name="known-players" type="string" value="Chromium;cmus;ncspot;org.gnome.Rhythmbox3;parole;qutebrowser;vlc;VSCodium"/>
|
||||
<property name="known-players" type="string" value="Chromium;cmus;firefox_firefox;ncspot;org.gnome.Rhythmbox3;parole;qutebrowser;vlc;VSCodium"/>
|
||||
<property name="mixer-command" type="string" value="pavucontrol"/>
|
||||
<property name="persistent-players" type="string" value="parole;org.gnome.Rhythmbox3"/>
|
||||
<property name="show-notifications" type="bool" value="true"/>
|
||||
|
@ -18,7 +18,7 @@
|
||||
<property name="show-tray-icon" type="bool" value="false"/>
|
||||
<property name="brightness-switch" type="int" value="0"/>
|
||||
<property name="brightness-switch-restore-on-exit" type="int" value="1"/>
|
||||
<property name="presentation-mode" type="bool" value="true"/>
|
||||
<property name="presentation-mode" type="bool" value="false"/>
|
||||
<property name="inactivity-on-ac" type="uint" value="14"/>
|
||||
<property name="critical-power-action" type="uint" value="0"/>
|
||||
</property>
|
||||
|
@ -2,6 +2,18 @@
|
||||
|
||||
<channel name="xfce4-screensaver" version="1.0">
|
||||
<property name="saver" type="empty">
|
||||
<property name="mode" type="int" value="0"/>
|
||||
<property name="mode" type="int" value="2"/>
|
||||
<property name="themes" type="empty">
|
||||
<property name="list" type="array">
|
||||
<value type="string" value="screensavers-xfce-personal-slideshow"/>
|
||||
</property>
|
||||
</property>
|
||||
</property>
|
||||
<property name="screensavers" type="empty">
|
||||
<property name="xfce-personal-slideshow" type="empty">
|
||||
<property name="location" type="string" value="/home/dakedres/pictures/screensaver-slideshow"/>
|
||||
<property name="arguments" type="string" value="--location=/home/dakedres/pictures/screensaver-slideshow --background-color=#000000"/>
|
||||
<property name="no-stretch" type="bool" value="false"/>
|
||||
</property>
|
||||
</property>
|
||||
</channel>
|
||||
|
@ -2,7 +2,7 @@
|
||||
|
||||
<channel name="xfce4-settings-manager" version="1.0">
|
||||
<property name="last" type="empty">
|
||||
<property name="window-width" type="int" value="1061"/>
|
||||
<property name="window-height" type="int" value="767"/>
|
||||
<property name="window-width" type="int" value="1028"/>
|
||||
<property name="window-height" type="int" value="1039"/>
|
||||
</property>
|
||||
</channel>
|
||||
|
@ -48,7 +48,7 @@
|
||||
<property name="title_vertical_offset_inactive" type="int" value="0"/>
|
||||
<property name="urgent_blink" type="bool" value="false"/>
|
||||
<property name="use_compositing" type="bool" value="true"/>
|
||||
<property name="workspace_count" type="int" value="4"/>
|
||||
<property name="workspace_count" type="int" value="6"/>
|
||||
<property name="wrap_resistance" type="int" value="10"/>
|
||||
<property name="wrap_windows" type="bool" value="false"/>
|
||||
<property name="wrap_workspaces" type="bool" value="false"/>
|
||||
|
@ -25,8 +25,8 @@
|
||||
<property name="Gtk" type="empty">
|
||||
<property name="CanChangeAccels" type="empty"/>
|
||||
<property name="ColorPalette" type="empty"/>
|
||||
<property name="FontName" type="empty"/>
|
||||
<property name="MonospaceFontName" type="empty"/>
|
||||
<property name="FontName" type="string" value="Noto Sans 11"/>
|
||||
<property name="MonospaceFontName" type="string" value="Monospace 12"/>
|
||||
<property name="IconSizes" type="empty"/>
|
||||
<property name="KeyThemeName" type="empty"/>
|
||||
<property name="ToolbarStyle" type="empty"/>
|
||||
|
67
local/share/qutebrowser/userscripts/copy-bookmark
Executable file
67
local/share/qutebrowser/userscripts/copy-bookmark
Executable file
@ -0,0 +1,67 @@
|
||||
#!/usr/bin/env python3
|
||||
|
||||
# copy-bookmark
|
||||
# copies links to specific headers/elements of a page
|
||||
# by Dakedres
|
||||
#
|
||||
# I guessed at how Python works.
|
||||
# Based on https://github.com/LaurenceWarne/qute-code-hint/blob/master/code_select.py
|
||||
|
||||
# It is recommended you add this to your config.py to use this script:
|
||||
# c.hints.selectors["bookmarks"] = [
|
||||
# "h1[id]",
|
||||
# "h2[id]",
|
||||
# "h3[id]",
|
||||
# "h4[id]",
|
||||
# "h5[id]",
|
||||
# "h6[id]",
|
||||
# "h1 > a[id]",
|
||||
# "h2 > a[id]",
|
||||
# "h3 > a[id]",
|
||||
# "h4 > a[id]",
|
||||
# "h5 > a[id]",
|
||||
# "h6 > a[id]",
|
||||
# "header[id]",
|
||||
# "footer[id]",
|
||||
# "article[id]",
|
||||
# "section[id]",
|
||||
# "p[id]",
|
||||
# "div[itemtype=\"https://schema.org/Answer\"]" # Stackoverflow answers
|
||||
# ]
|
||||
# And call it with
|
||||
# hint bookmarks userscript copy-bookmark
|
||||
|
||||
import os
|
||||
from urllib.parse import urlparse, urlunparse
|
||||
from html.parser import HTMLParser
|
||||
|
||||
class BookmarkParser(HTMLParser):
|
||||
def handle_starttag(self, tag, attrs):
|
||||
for attr in attrs:
|
||||
print(attr[0])
|
||||
if(attr[0] == "id"):
|
||||
self.bookmark_id = attr[1]
|
||||
|
||||
def close(self):
|
||||
HTMLParser.close(self)
|
||||
return self.bookmark_id
|
||||
|
||||
def send_to_qute(command):
|
||||
with open(os.environ.get("QUTE_FIFO"), "w") as f:
|
||||
f.write(command)
|
||||
|
||||
def construct_bookmark_url():
|
||||
parser = BookmarkParser()
|
||||
parser.feed(os.environ.get("QUTE_SELECTED_HTML"))
|
||||
bookmark_id = parser.close()
|
||||
|
||||
url = urlparse(os.environ.get("QUTE_CURRENT_URL") )
|
||||
url = url._replace(fragment=bookmark_id)
|
||||
|
||||
return urlunparse(url)
|
||||
|
||||
def main():
|
||||
send_to_qute("yank inline '{url}'".format(url=construct_bookmark_url() ) )
|
||||
|
||||
if __name__ == "__main__":
|
||||
main()
|
47
local/share/qutebrowser/userscripts/le-password
Executable file
47
local/share/qutebrowser/userscripts/le-password
Executable file
@ -0,0 +1,47 @@
|
||||
#!/bin/sh
|
||||
|
||||
mode=$1
|
||||
index=0
|
||||
|
||||
if [ -z "$mode" ]; then
|
||||
mode="eval"
|
||||
fi
|
||||
|
||||
printf %s\\n 'message-info "Requesting password..."' >> "$QUTE_FIFO"
|
||||
results=$(bw list items --session --url "$QUTE_CURRENT_URL")
|
||||
|
||||
query() {
|
||||
printf %s "$results" | jq "$1"
|
||||
}
|
||||
|
||||
if [ "$(query length)" != 1 ]; then
|
||||
index=$(query ".[] | .name,.login.username" | tr -d '"' | awk '!(NR%2){print $0 " (" p ")"}{p=$0}' | rofi -dmenu -format i)
|
||||
fi
|
||||
|
||||
password="$(query ".[${index}].login.password" | tr -d '"')"
|
||||
|
||||
case $mode in
|
||||
eval)
|
||||
username="$(query ".[${index}].login.username" | tr -d '"')"
|
||||
script=$(printf %s """\
|
||||
let e = document.activeElement, \
|
||||
f = e.closest('form'), \
|
||||
p = !f || e.type === 'password' ? e : f.querySelector('input[type=password]'), \
|
||||
u = !f || e.type === 'email' || e.type === 'text' ? e : f.querySelector('input[type=email], input[name=email], input[name=username], input[name=user_name], input[name=user], input[autofocus]'), \
|
||||
F = (i, v) => { if(i) { i.value = v; return true } }, \
|
||||
su = F(u, USERNAME), \
|
||||
sp = F(p, PASSWORD); \
|
||||
if(su && sp) { 'Login filled' } \
|
||||
else if(su) { 'Username filled' } \
|
||||
else if(sp) { 'Password filled' } \
|
||||
else 'Unable to fill login info' \
|
||||
""")
|
||||
command="jseval $(printf '{ let USERNAME="%s", PASSWORD="%s"; %s }' "$username" "$password" "$script" )"
|
||||
;;
|
||||
|
||||
*)
|
||||
command="insert-text ${password}"
|
||||
;;
|
||||
esac
|
||||
|
||||
printf %s\\n "$command" > "$QUTE_FIFO"
|
27
local/share/qutebrowser/userscripts/pipe.sh
Executable file
27
local/share/qutebrowser/userscripts/pipe.sh
Executable file
@ -0,0 +1,27 @@
|
||||
#!/bin/bash
|
||||
|
||||
# pipe=/tmp/testpipe
|
||||
|
||||
# trap "rm -f $pipe" EXIT
|
||||
#
|
||||
# if [[ ! -p $pipe ]]; then
|
||||
# mkfifo $pipe
|
||||
# fi
|
||||
|
||||
# echo "$QUTE_FIFO" > $HOME/fifoa
|
||||
#
|
||||
# echo "jseval window.location.href"
|
||||
#
|
||||
# while true
|
||||
# do
|
||||
# if read -r line <"$QUTE_FIFO"; then
|
||||
# if [[ "$line" == 'quit' ]]; then
|
||||
# break
|
||||
# fi
|
||||
# echo "$line"
|
||||
# fi
|
||||
# done
|
||||
#
|
||||
# echo "Reader exiting"
|
||||
|
||||
echo "open -t https://www.dict.cc/?s=$QUTE_SELECTED_TEXT" >> "$QUTE_FIFO"
|
@ -1,2 +1,2 @@
|
||||
setxkbmap -option altwin:swap_alt_win
|
||||
# setxkbmap -option altwin:swap_alt_win
|
||||
setxkbmap -option caps:swapescape
|
||||
|
6
scripts/mdread
Executable file
6
scripts/mdread
Executable file
@ -0,0 +1,6 @@
|
||||
#!/bin/sh
|
||||
|
||||
o="$(mktemp).html"
|
||||
t="$(basename $1)"
|
||||
pandoc "$1" -o "$o" --metadata="title:$t"
|
||||
xdg-open "$o"
|
Loading…
x
Reference in New Issue
Block a user