Update css/js + few configs
This commit is contained in:
@@ -1,25 +1,8 @@
|
||||
#+TITLE: Qutebrowser Configuration
|
||||
:DRAWER:
|
||||
#+STARTUP: overview
|
||||
|
||||
#+LANGUAGE: en
|
||||
#+EMAIL: dehaeze.thomas@gmail.com
|
||||
#+AUTHOR: Dehaeze Thomas
|
||||
|
||||
#+HTML_LINK_HOME: ./index.html
|
||||
#+HTML_LINK_UP: ./index.html
|
||||
|
||||
#+HTML_HEAD: <link rel="stylesheet" type="text/css" href="./css/htmlize.css"/>
|
||||
#+HTML_HEAD: <link rel="stylesheet" type="text/css" href="./css/readtheorg.css"/>
|
||||
#+HTML_HEAD: <script type="text/javascript" src="./js/jquery.min.js"></script>
|
||||
#+HTML_HEAD: <script type="text/javascript" src="./js/bootstrap.min.js"></script>
|
||||
#+HTML_HEAD: <script type="text/javascript" src="./js/jquery.stickytableheaders.min.js"></script>
|
||||
#+HTML_HEAD: <script type="text/javascript" src="./js/readtheorg.js"></script>
|
||||
|
||||
#+SETUPFILE: ./setup/org-setup-file.org
|
||||
#+PROPERTY: header-args+ :comments none
|
||||
#+PROPERTY: header-args+ :mkdirp yes
|
||||
#+PROPERTY: header-args+ :tangle ~/.config/qutebrowser/config.py
|
||||
:END:
|
||||
|
||||
* Import
|
||||
#+begin_src python
|
||||
@@ -44,7 +27,6 @@
|
||||
c.content.geolocation = 'ask'
|
||||
c.content.javascript.alert = True
|
||||
c.content.javascript.can_access_clipboard = True
|
||||
c.content.media_capture = 'ask'
|
||||
c.content.pdfjs = False
|
||||
c.content.proxy = 'system'
|
||||
#+END_SRC
|
||||
@@ -312,6 +294,11 @@ Screenshot of webpage to png
|
||||
config.bind(',S', 'spawn --userscript ~/.config/qutebrowser/userscripts/html-to-png.sh')
|
||||
#+end_src
|
||||
|
||||
Download AES video
|
||||
#+begin_src python
|
||||
config.bind(',E', 'spawn --userscript ~/.config/qutebrowser/userscripts/aes-download.sh')
|
||||
#+end_src
|
||||
|
||||
Download a torrent
|
||||
#+begin_src python
|
||||
config.bind(',t', 'hint links spawn torrent-add {hint-url}')
|
||||
@@ -570,10 +557,7 @@ Send to Emacs
|
||||
|
||||
** Download with aria2c on the Homelab
|
||||
#+begin_src bash :tangle ~/.config/qutebrowser/userscripts/aria2c-add-homelab.sh
|
||||
# Remove the =&af= from 1fichier.
|
||||
$url=$(echo "$1" | sed 's/\&af=.*$//g')
|
||||
|
||||
dlab add "$url" && \
|
||||
dl-add $(echo "$1" | sed 's/\&af=.*$//g') && \
|
||||
dunstify "Aria2" "Download Started" || \
|
||||
dunstify "Aria2" "Error"
|
||||
#+end_src
|
||||
@@ -599,3 +583,17 @@ Send to Emacs
|
||||
dunstify "Percollate" "Successfully saved to pdf"
|
||||
fi
|
||||
#+end_src
|
||||
|
||||
** Download AES video
|
||||
#+begin_src bash :tangle ~/.config/qutebrowser/userscripts/aes-download.sh
|
||||
m3u8_path=`curl -L -s "$QUTE_URL" | pcregrep -o1 "file = \"\/(.*aes.*mp4)\""`
|
||||
|
||||
if [ -z "$m3u8_path" ]; then
|
||||
dunstify --urgency=critical "Qutebrowser" "No m3u8 playlist found"
|
||||
else
|
||||
dunstify "Qutebrowser" "Downloads..." && \
|
||||
cd ~/Downloads/ && \
|
||||
ffmpeg -user_agent "Mozilla/5.0 (X11; Linux x86_64; rv:84.0) Gecko/20100101 Firefox/84.0" -referer "$QUTE_URL" -i "https://cdn2.digitellinc.com/play/_definst_/mp4:$m3u8_path/playlist.m3u8" -c copy "$QUTE_TITLE.mp4" && \
|
||||
dunstify "Qutebrowser" "$QUTE_TITLE Downloaded"
|
||||
fi
|
||||
#+end_src
|
||||
|
||||
Reference in New Issue
Block a user