This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/sh | |
# GistID: 8bfc3cd340d443b6847ccd443b4a1acc | |
yaycachedir=~/.cache/yay | |
yaycache="$(find $yaycachedir -maxdepth 1 -type d | awk '{ print "-c " $1 }' | tail -n +2)" | |
echo "==> Keep last 2 installed versions" | |
/usr/bin/paccache -rvk2 $yaycache | |
for pkgdir in "$yaycachedir"/*/; do |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/zsh | |
# Export title, link and extraxt to a gmi file | |
# GistID: 6489320d1def15b182b86bf29f1d1b73 | |
id=$(xprop -root | awk '/_NET_ACTIVE_WINDOW\(WINDOW\)/{print $NF}') | |
name=$(xprop -id $id | awk '/_NET_WM_NAME/{$1=$2="";print}' | cut -d'"' -f2) | |
FILE_NOTE=${GMI_FILE_NOTE:-~/sdf/gopher/notes-de-lectures.gmi} | |
#FILE_NOTE=/tmp/test.gmi | |
TITRE=${1:-$name} |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
/* | |
* Vieb - Vim Inspired Electron Browser | |
* Copyright (C) 2019-2022 Jelmer van Arnhem | |
* | |
* This program is free software: you can redistribute it and/or modify | |
* it under the terms of the GNU General Public License as published by | |
* the Free Software Foundation, either version 3 of the License, or | |
* (at your option) any later version. | |
* | |
* This program is distributed in the hope that it will be useful, |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/sh | |
# get width of the monitor | |
# GistID: 95863f4302b5bd8c85e565a122f8e0df | |
xrandr | grep "*" | cut -d" " -f4 | cut -d"x" -f2 |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/sh | |
# get width of the monitor | |
# GistID: 3e0bc7adbd07f82eb7eeca30215e9934 | |
xrandr | grep "*" | cut -d" " -f4 | cut -d"x" -f1 |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/sh | |
# simple timer for i3 | |
# depend on monitor_width and timer | |
# GistID: 4c6b8326117e9aad86300bc67b8429db | |
CMD="sh -c 'timer "$1"; echo -n "$1" time elapsed !'" | |
t_width=$(($(monitor_width)/2)) | |
t_height=50 #TODO calculate minimal height with height line, font size to adpat any screen resolution | |
p_v=$(($(monitor_height)-$t_height-2)) |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/sh | |
# Display qrcode in floating window in i3wm | |
# GistID: 3d87379105af6b5b4f5eb1463fee6228 | |
qrcode() { | |
qrencode -o - | feh --class "_popup-notitle" -x - | |
} | |
if [ -t 1 ] | |
then |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?xml version="1.0" encoding="utf-8"?> | |
<opml version="2.0"> | |
<head> | |
<title>gPodder subscriptions</title> | |
<dateCreated>Tue, 30 Aug 2022 14:37:58 +0200</dateCreated> | |
</head> | |
<body> | |
<outline title="La Grande table" text="A l'heure du déjeuner, les convives - artistes, personnalités du monde de la culture et des idées - prennent place à table. Rendez-vous sur l'application Radio France pour découvrir tous les autres épisodes." xmlUrl="http://radiofrance-podcast.net/podcast09/rss_12360.xml" type="rss"/> | |
<outline title="Les pieds sur terre" text="Tous les jours, une demi-heure de reportage sans commentaire. Du lundi au vendredi, de 13h30 à 14h Rendez-vous sur l'application Radio France pour découvrir tous les autres épisodes." xmlUrl="http://radiofrance-podcast.net/podcast09/rss_10078.xml" type="rss"/> | |
<outline title="La fabrique de l'histoire" text="Mieux comprendre quotidiennement le lien étrange qui nous unit au passé. |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#Calendrier des jours fériés | |
# GistID: e62ff64d9346dfadf3881cb86d9a971b | |
JF Jours fériés | |
00000101 Nouvel an | |
00000501 Fête du travail | |
00000508 Armistice 1945 | |
00000714 Fête nationale française | |
00001111 Armistice 1918 | |
Easter Pâques |