Skip to content

Instantly share code, notes, and snippets.

@RichNSD
RichNSD / Textastic-Dockerfile-Support.md
Created February 5, 2023 11:22
Initially drafted in response to a forum post about adding language support for `Dockerfiles`. Then I got carried away and wrote a small manual.

Dockerfile Support

I can't believe it took me so long to figure out the answer to this- and it was right in front of my face the whole time. Regardless, now that I've finally figured this out for myself, I want to share the ✨ magic ✨ with everyone else.

So what is the solution- and where was it the whole time? Shockingly, this answer was actually right where it should have been... in the Online Manual.


Sublime 3 & TextMate Packages

#!/bin/bash
# https://gist.github.com/scrathe
# https://www.reddit.com/r/PleX/comments/vcc95i/database_repair_script_for_common_plex_db_errors/
# what is this? performs the steps outlined in Plex's garbage instructions on how to "Manually Repair the Database" https://support.plex.tv/articles/repair-a-corrupted-database/
# notes
# although this script will backup your Plex DB, i would suggest making your own backup.
# this script assumes you are comfortable with copying/pasting/running random things from the internet.
@b01
b01 / download-vs-code-server.sh
Last active May 4, 2024 21:41
Linux script to download latest VS Code Server, good for Docker (tested in Alpine).
#!/bin/sh
# Copyright 2023 Khalifah K. Shabazz
#
# Permission is hereby granted, free of charge, to any person obtaining a
# copy of this software and associated documentation files (the “Software”),
# to deal in the Software without restriction, including without limitation
# the rights to use, copy, modify, merge, publish, distribute, sublicense,
# and/or sell copies of the Software, and to permit persons to whom the
# Software is furnished to do so, subject to the following conditions:

This script add Categories to Automatically add torrents from per Monitored Folder

👉 This script is in flux, as it may be implemented into qBittorrent in the future.

savecategory expects the user's watch directories to look similar to something like this:

It's based off Docker guide for setting up hard links between virtual volumes (Docker) and machine volumes.

@rverst
rverst / check_semver.sh
Last active April 14, 2024 04:41
Bash script for checking a semantic version
#!/usr/bin/env bash
# https://gist.github.com/rverst/1f0b97da3cbeb7d93f4986df6e8e5695
function chsv_check_version() {
if [[ $1 =~ ^(0|[1-9][0-9]*)\.(0|[1-9][0-9]*)\.(0|[1-9][0-9]*)(-((0|[1-9][0-9]*|[0-9]*[a-zA-Z-][0-9a-zA-Z-]*)(\.(0|[1-9][0-9]*|[0-9]*[a-zA-Z-][0-9a-zA-Z-]*))*))?(\+([0-9a-zA-Z-]+(\.[0-9a-zA-Z-]+)*))?$ ]]; then
echo "$1"
else
echo ""
fi
}