Skip to content

Instantly share code, notes, and snippets.

@kairusds
kairusds / fullscreen-landscape.user.js
Created August 5, 2021 23:11
Fix fullscreen orientation on Chrome mobile
// ==UserScript==
// @name Fullscreen Landscape
// @namespace https://kairusds.js.org/
// @version 0.1
// @description Fix Chrome mobile fullscreen orientation
// @author kairusds
// @match http://*/*
// @match https://*/*
// @icon data:image/gif;base64,R0lGODlhAQABAAAAACH5BAEKAAEALAAAAAABAAEAAAICTAEAOw==
// @grant none
@kairusds
kairusds / compile-android.sh
Created August 1, 2021 00:10
Compile ffmpeg for Android with support for MP3, OGG & WAv
#!/bin/bash
if [ -z "$ANDROID_NDK" ]; then
echo "Please set ANDROID_NDK to the Android NDK folder"
exit 1
fi
#Change to your local machine's architecture
HOST_OS_ARCH=linux-x86_64
function configure_ffmpeg {
@kairusds
kairusds / genkey.sh
Last active July 31, 2021 18:03
Generates a private key for use with PocketGit (or JGit Clients)
ssh-keygen -t rsa -m PEM
@kairusds
kairusds / eruda.js
Created June 6, 2021 23:01
eruda userscript for use with tampermonkey on mobile browsers / via web browser
// ==UserScript==
// @name eruda
// @namespace http://tampermonkey.net/
// @version 0.1
// @description try to take over the world!
// @author You
// @include http://*
// @include https://*
// @icon https://www.google.com/s2/favicons?domain=greasyfork.org
// @run-at document-body
@kairusds
kairusds / fleeter.sh
Last active March 5, 2021 08:04
credits: endrift and MarioMasta64, slightly modified by me
#!/bin/sh
if [ $# -eq 0 ]; then
echo "Usage: fleeter FILE\n"
exit 1
fi
VIDEO=$1
LEN=$(ffprobe -v error -show_entries format=duration -of default=noprint_wrappers=1:nokey=1 "$VIDEO")
@kairusds
kairusds / dt.sh
Last active February 12, 2021 23:42
speed up a music file's audio by 1.5x
#!/bin/sh
if [ $# -eq 0 ]; then
echo "Usage: dt <path>"
exit 1
fi
out="${1%.*} 1.5x.mp3"
ffmpeg -i "$1" -ab 192k -af atempo=1.5 "$out"
@kairusds
kairusds / termux-setup.sh
Last active November 20, 2022 15:24
termux setup script for personal use
termux-setup-storage && pkg install neofetch htop && mkdir $HOME/.termux/ ;echo "extra-keys = [['ESC','/','-','HOME','UP','END','PGUP'],['TAB','CTRL','ALT','LEFT','DOWN','RIGHT','PGDN']]" >> $HOME/.termux/termux.properties && termux-reload-settings && sleep 1 && logout
#!/bin/sh
URL="https://0x0.st"
if [ $# -eq 0 ]; then
echo "Usage: 0x0.sh FILE\n"
exit 1
fi
FILE=$1
@kairusds
kairusds / aget
Last active October 19, 2022 19:46
Alias command for downloading files or the best quality of a video's audio into mp3 with yt-dlp
#!/bin/sh
if [ $# -eq 0 ]; then
echo "Usage: aget <url>"
exit 1
fi
aria2c -j 16 -s 16 -x 16 -k 1M "$1"

Keybase proof

I hereby claim:

  • I am kairusds on github.
  • I am kairusds (https://keybase.io/kairusds) on keybase.
  • I have a public key ASDgXOccjIX4h6QoLhqqDWvA74DfEbmsVTclTx8gCUiOnAo

To claim this, I am signing this object: