GRUB_INIT_TUNE="1000 334 1 334 1 0 1 334 1 0 1 261 1 334 1 0 1 392 2 0 4 196 2"
This file contains 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/bash | |
DATE=$1 | |
CURRENCY=${2:-usd} | |
KURS=${3:-sre} | |
FORMAT="json" | |
API_KEY="YOUR_API_KEY_HERE" # https://www.kursna-lista.info/moj-nalog/api-podesavanja | |
API_ENDPOINT="https://api.kursna-lista.info/$API_KEY/kl_na_dan/$DATE/$FORMAT" | |
CACHE="$HOME/.kursna_lista/$DATE.$CURRENCY.$KURS" |
This file contains 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
# WEB | |
WEB is a recursive acronym. WEB stands for WEB Editor Bookmarklet. | |
WEB is a minimalistic HTML, CSS, and JavaScript CodePen-like web editor that fits inside a bookmarklet. | |
# Usage | |
Every time you edit the HTML, CSS, and JavaScript in the top three boxes, the result gets evaluated. | |
# Sharing | |
Click the share button in the bottom right to copy the contents of your WEB onto the clipboard for sharing. |
Do you want your computer to play a coin pickup audio sample from Super Mario Bros. every time it boots up? Of course you do! And if you are using a GRUB boot loader - you CAN!
Just add the following code to your /etc/default/grub
config file:
GRUB_INIT_TUNE="600 988 1 1319 8"
And update your grub:
This file contains 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
diff --git i/ledger-api.js w/ledger-api.js | |
index 963cc90..be07899 100644 | |
--- i/ledger-api.js | |
+++ w/ledger-api.js | |
@@ -20,6 +20,9 @@ const cleanInput = (str) => { | |
return padSpace(str.trim()) | |
} | |
+const sumByDate = "awk -F' ' '{a[$1]+=$2}END{for(x in a)print x\" \"a[x]}'"; | |
+const pipe = (...commands) => commands.join(" | "); |
This file contains 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
random_pitch() { | |
local delta=${1:-50} | |
local value=$(( ($RANDOM % $delta) - $delta/2 )) | |
echo "+${value}" | sed 's/+-/-/' | |
} | |
glados() { | |
local pitch=70 | |
local speed=180 | |
local lang=en |
This file contains 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
\vim - -u NONE -es '+1' "+$*" '+%print' '+:qa!' | tail -n +2 | |
# Commented version | |
# \vim `# use unaliased version of vim` \ | |
# - `# read from stdin` \ | |
# -u NONE `# do not process .vimrc` \ | |
# -es `# start in :ex mode, do not start visual interface` \ | |
# '+1' `# go to the first line` \ | |
# "+$*" `# process commands passed as arguments` \ |
This file contains 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
/////////////////////////////////////////// | |
// Animation Cubic Bezier easings // | |
// see - http://matthewlein.com/ceaser // | |
/////////////////////////////////////////// | |
// defaults | |
$ease-linear: "cubic-bezier(0.250, 0.250, 0.750, 0.750)"; | |
$ease-default: "cubic-bezier(0.250, 0.100, 0.250, 1.000)"; | |
$ease-in: "cubic-bezier(0.420, 0.000, 1.000, 1.000)"; | |
$ease-out: "cubic-bezier(0.000, 0.000, 0.580, 1.000)"; |
This file contains 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
#!/usr/bin/env bash | |
# Bash Helper Script For Kimai Docker | |
# https://www.kimai.org/documentation/docker.html | |
kimai_install() { | |
docker run --name kimai-mysql \ | |
-e MYSQL_DATABASE=kimai \ | |
-e MYSQL_USER=kimai \ | |
-e MYSQL_PASSWORD=kimai \ |
This file contains 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
rest: | |
scan_interval: 900 | |
method: GET | |
resource: http://api.allthingstalk.io/device/HYdfY2YhmeMxq10ICXvNfST7 | |
headers: | |
Authorization: !secret my_allthingstalk_bearer_token | |
sensor: | |
- name: "Klimerko PM1" | |
unique_id: 1668683822561 | |
value_template: >- |
OlderNewer