Skip to content

Instantly share code, notes, and snippets.

#!/bin/bash
declare process_echo_history
declare last_process_status
spinner() {
#spinner animation
local pid=$!
local delay=0.20
local spinstr='|/-\'
while [ "$(ps a | awk '{print $1}' | grep $pid)" ]; do
local temp=${spinstr#?}
@BlurryFlurry
BlurryFlurry / gist:4d9e469b92edeed37fda4b4c6a2864b3
Created September 15, 2022 11:50
# pacman -Qqn | pacman --overwrite=* -S -
# pacman -Qqn | pacman --overwrite=* -S -
warning: a52dec-0.7.4-11 is up to date -- reinstalling
warning: aalib-1.4rc5-14 is up to date -- reinstalling
warning: abseil-cpp-20220623.1-1 is up to date -- reinstalling
warning: accounts-qml-module-0.7-4 is up to date -- reinstalling
warning: accountsservice-22.08.8-2 is up to date -- reinstalling
warning: acl-2.3.1-2 is up to date -- reinstalling
warning: acpi-1.7-3 is up to date -- reinstalling
warning: acpid-2.0.33-1 is up to date -- reinstalling
warning: adobe-source-code-pro-fonts-2.038ro+1.058it+1.018var-1 is up to date -- reinstalling
@BlurryFlurry
BlurryFlurry / fastReply.js
Last active December 31, 2018 12:49
shortcut keys for youtube comment reply template
// ==UserScript==
// @name Youtube Comment Reply
// @namespace Violentmonkey Scripts
// @match https://www.youtube.com/comments
// @grant none
// ==/UserScript==
//
(function () {
@BlurryFlurry
BlurryFlurry / TogglDesktop.sh.patch
Created October 29, 2018 09:36
toggldesktop 7.4.144-3 this patch file fixes qt5ct: D-Bus system tray: no error
--- /opt/toggldesktop/TogglDesktop.sh 2018-10-29 14:49:37.695585963 +0530
+++ /opt/toggldesktop/TogglDesktop.sh 2018-10-29 14:48:49.882253006 +0530
@@ -15,6 +15,7 @@
XDG=$XDG_CURRENT_DESKTOP
if [[ "$XDG" = "X-Cinnamon" || "$XDG" = "XFCE" || "$XDG" = "Pantheon" || "$XDG" = "i3" || "$XDG" = "LXDE" || "$XDG" = "MATE" || "$XDG" = "Budgie:GNOME" ]]; then
+ QT_QPA_PLATFORMTHEME=gtk3
DBUS_SESSION_BUS_ADDRESS=""
dbus-launch $dirname/$appname "$@" &
else
@BlurryFlurry
BlurryFlurry / askpass-rofi.sh
Created October 11, 2018 10:38
Ask sudo password rofi
#!/bin/sh
# Take password prompt from STDIN, print password to STDOUT
# the sed piece just removes the colon from the provided
# prompt: rofi -p already gives us a colon
rofi -dmenu \
-password \
-no-fixed-num-lines \
-p "$(printf "$1" | sed s/://)"
@BlurryFlurry
BlurryFlurry / .user.js
Last active October 8, 2019 07:19
Greesemonkey | Violentmonkey | Tampermonkey | Userscript to force youtube.com to play specific quality (480p, 360p etc)
// ==UserScript==
// @name Youtube 480p
// @version 1
// @grant none
// @run-at document-start
// @include https://www.youtube.com/*
// @version 1.1
// @downloadURL https://gist.githubusercontent.com/BlurryFlurry/04124b45c0c4ec653cd2dae5a0ed266a/raw/.user.js
// @updateURL https://gist.githubusercontent.com/BlurryFlurry/04124b45c0c4ec653cd2dae5a0ed266a/raw/.user.js
// ==/UserScript==
# use vi mode
setw -g mode-keys vi
# remap prefix to control + a
set -g prefix C-a
unbind C-b
bind C-a send-prefix
# move around panes like in vim
bind j select-pane -D