Skip to content

Instantly share code, notes, and snippets.

View StrangeRanger's full-sized avatar

Hunter T. StrangeRanger

View GitHub Profile
@StrangeRanger
StrangeRanger / bulkUnbookmark.js
Last active March 7, 2026 19:10
Easily remove bookmarks en masse on Twitter/X via the browser's developer tools console. (status: personal)
// Easily remove bookmarks en masse on Twitter/X via the browser's developer tools console.
//
// NOTE: If you have many bookmarks, you WILL encounter the "429 (Too Many Requests)" error.
// The best way to resolve this is use a VPN to change your IP while still logged into your existing account.
//
// NOTE 2: Code was generated by ChatGPT and modified by me.
const bulkUnbookmark = (() => {
let running = false;
const sleep = (ms) => new Promise(r => setTimeout(r, ms));
@StrangeRanger
StrangeRanger / PrivateBin-setup.bash
Last active July 23, 2025 20:01
An easy way to install PrivateBin in a secure method, seperating files that can be publicly accessible and one's that can't. (status: personal)
#!/bin/bash
#
# An easy way to install PrivateBin in a secure method, seperating files that can be
# publicly accessible and ones that shouldn't be.
#
# NOTE:
# This script requires root privileges to modify ownership of the files.
#
# Version: v1.0.0
# License: MIT License
@StrangeRanger
StrangeRanger / _clang-format
Last active July 23, 2025 20:01
C# _clang-format configuration file (works for 'clang-format version 18.x.x') (status: personal)
---
Language: CSharp
# BasedOnStyle: Microsoft
AccessModifierOffset: -2
AlignAfterOpenBracket: Align
AlignArrayOfStructures: None
AlignConsecutiveAssignments:
Enabled: false
AcrossEmptyLines: false
AcrossComments: false
@StrangeRanger
StrangeRanger / dotnet-sdk-not-found.bash
Last active July 23, 2025 20:11
Fixes problems caused by micosoft making .NET natively available on Ubuntu 22.04. For more information, refer to https://github.com/dotnet/core/issues/7699. (status: finished)
#!/bin/bash
#
# Fixes problems caused by micosoft making .NET natively available on Ubuntu 22.04. For
# more information, refer to https://github.com/dotnet/core/issues/7699.
#
# NOTE:
# This script specifically install dotnet-sdk-6.0 on Ubuntu 22.04 and Linux Mint 21.
# If you are using a different version of Linux and/or dotnet-sdk, you may need to
# manually modify the script to suit your needs.
#
@StrangeRanger
StrangeRanger / if-statements.bash
Last active July 23, 2025 20:11
Shows the difference between different tests statements, and how they behave when working with different kinds of variables. (status: finished)
#!/usr/bin/env bash
#
# shellcheck disable=SC2016
#
# The point of this script is to show the difference between the different kinds of if
# and test statements, and how they behave differently when dealing with different kinds
# variables.
#
########################################################################################
####[ Setup ]###########################################################################
@StrangeRanger
StrangeRanger / Commit Types.md
Last active May 29, 2026 22:40
Outlines standardized commit types for all repositories, along with extended types for script/tool-focused repos. (status: personal)

Commit Conventions

This document outlines standardized commit types for all repositories, along with extended types for script/tool-focused repositories. The goal is to provide a clear, maintainable commit history, aid in automated changelog generation, and guide semantic versioning decisions.

These conventions are based on the Conventional Commits format:

<type>[optional scope]: <description>
@StrangeRanger
StrangeRanger / spinning-stick.bash
Last active July 23, 2025 20:04
Examples of how to implement a spinning stick in the terminal, when waiting for a process to finish. (status: finished)
#!/usr/bin/env bash
#
# Sometimes, it's helpful to show users that a background process is running and the
# script is awaiting its completion. A common approach is to display a spinner in the
# terminal until the process finishes. This script offers two methods to implement such
# a spinner, catering to different needs and scenarios.
#
########################################################################################
####[ Global Variables ]################################################################
@StrangeRanger
StrangeRanger / currency_converter.py
Last active July 23, 2025 20:05
Using the API (https://api.exchangeratesapi.io/latest), this script converts one currency into another. (status: unsupported)
#!/usr/bin/env python3
#
# Using the API (https://api.exchangeratesapi.io/latest), this script converts one
# currency into another.
#
# Prerequisites:
# - requests
#
# IMPORTANT:
# This script no longer works as the API now requires an API key.
@StrangeRanger
StrangeRanger / rock_paper_scissors.py
Last active July 23, 2025 20:06
A randomized rock paper scissors game for the purpose of observing probability. (status: finished)
#!/usr/bin/env python3
#
# A randomized rock paper scissors game for the purpose of observing probability.
#
# Reason For Creation:
# This little script was created because a math class required us to play rock paper
# scissors against someone to observe probability. I didn't have anyone to do it with
# at the time, so I created this.
#
# Version: v1.0.2
@StrangeRanger
StrangeRanger / heads_or_tails.py
Last active July 23, 2025 20:07
Digitally flip a coin x number of times and prints the number of times the outcome was heads and tails. (status: finished)
#!/usr/bin/env python3
#
# Digitally flip a coin x number of times and prints the number of times the outcome was
# heads and tails.
#
# Version: v1.0.3
# License: MIT License
# Copyright (c) 2020-2021 Hunter T. (StrangeRanger)
#
########################################################################################