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 | |
# Compress all git folders responscing gitignore rules | |
set -e | |
# Export folder | |
export_folder=$(pwd)/export | |
mkdir -p $export_folder | |
echo "Exporting all git subfolders for $(pwd) to tar.gz files into $export_folder" |
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 | |
# This script runs the speech-to-text loop from the commandline. It records to given file till you press CTRL-C or 30 seconds has passs`ed | |
# and then it transcribes the recording and prints the result. It then starts recording again and so on. | |
# Install whisper | |
:' | |
git clone git@github.com:ggerganov/whisper.cpp.git | |
cd whisper.cpp | |
# Download whisper open source model base version |
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 | |
# Customisations/granular instructuions need to be followed | |
# Refer [1], [2], [3] | |
# Written for linux. May need some customisations for windows | |
# Dependencies: | |
# - htmlq: https://github.com/mgdm/htmlq | |
# - jq: https://github.com/stedolan/jq | |
# - html | |
# |
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 | |
# BE EXTRA CAREFUL with repo deletion. There is no way to recover repository once its deleted. | |
# Do this AT YOUR OWN RISK | |
# Pre-requisites: gh cli, awk | |
# Selection through file edit | |
# gh repo list -L 100 | awk '{print $1}' | sed 's,.*/,,') > repo.remote.list.all | |
# gh repo list -L 100 --source | awk '{print $1}' | sed 's,.*/,,') > repo.remote.list.all # non forked |
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 | |
cat /var/log/apt/history.log 2>/dev/null | | |
egrep '^(Start-Date:|Commandline:)' | | |
grep -v aptdaemon | | |
egrep '^Commandline:'|rg 'apt install'|sed 's/Commandline: apt install//' | |
# Last tested on ubuntu 22.04 (29/12/2022) |
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 sh | |
# Script to test a specific version of script locally | |
export NVIM_BINARY="$HOME/.local/bin/nvim081" | |
export VERSION="0.8.1" | |
# # @nvim-Install | |
# curl https://github.com/neovim/neovim/releases/download/v$VERSION/nvim-linux64.tar.gz -o ~/Downloads/nvim.tar.gz -L | |
# tar -zxf ~/Downloads/nvim.tar.gz -C ~/.local/bin --wildcards "nvim-linux64/bin/*" --strip-components=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
// Run this link on https://twitter.com/<username>/following | |
// On a Twitter "Following" timeline, run this in console | |
// You can trigger thuis through chrome console as well | |
async function getAllFollowers() { | |
window.scrollTo(0,0); | |
var hs = new Set(); | |
var last_hs_size; | |
var ctr=0; | |
const getFollowers=function (){ | |
last_hs_size = hs.size; |
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 | |
LATEST_SUBSCRIPTIONS_FP=~/repos/exports/yt/subscriptions.csv | |
NEWSBOAT_YOUTUBE_FP=~/repos/newsboat/urlcategory/youtube | |
if test -f $NEWSBOAT_YOUTUBE_FP | |
then | |
cp $NEWSBOAT_YOUTUBE_FP $NEWSBOAT_YOUTUBE_FP.bk | |
rm $NEWSBOAT_YOUTUBE_FP | |
fi |
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
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
# Deleting multi repositories from github in windows | |
1. Download & Install github CLI | |
2. Authenticate using `gh auth login` in windows command prompt ( Browser window will open) | |
3. Add extra permitions ( for delete) using `gh auth refresh -h github.com -s delete_repo ` from cmd | |
4. Ensure all your repos to be deleted are saved in a file `repos.txt` current folder in format "username":"reponame" | |
5. run the above batch file from same folder |
NewerOlder