This file contains hidden or 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
| # v0.03 // added preformat sanitizer for hyphenation and other text formatting | |
| import shutil | |
| import sys | |
| import os | |
| import re | |
| # print term width horizontal line | |
| def hz_line(character='-'): | |
| terminal_width = shutil.get_terminal_size().columns |
This file contains hidden or 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 | |
| # | |
| # >>> SCANLAN <<< | |
| # | |
| # this script can used for i.e. checking out what's on your LAN | |
| # requires `nmap`, `xmlstarlet` and `lolcat` (just because) | |
| # adjust to your own ip range as needed. | |
| # NO WARRANTIES, use only for your own LAN diagnostics and at your own risk | |
| # | |
| # |
This file contains hidden or 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
| # async_tts.py, for `TTS` pypi package (also requires `pydub`) | |
| # $ pip install -U tts pydub | |
| # | |
| # v0.02 | |
| # changes: | |
| # - now uses pydub, normalizes audio | |
| # | |
| # performs a staggered execution / playback of the audio, | |
| # where the next chunk is being processed while the previous is still playing | |
| # |
This file contains hidden or 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 | |
| # This script is designed to identify and list all USB cameras and audio devices connected to a system. | |
| # It provides detailed information about each device, including vendor ID, product ID, serial number, | |
| # device description, and supported video modes for cameras. It also identifies audio devices and | |
| # lists their card and device numbers, names, and descriptions. | |
| # Required Packages: | |
| # - udevadm: Provides information about device attributes. | |
| # - v4l2-ctl: A utility to control video4linux devices and list video formats. |
This file contains hidden or 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 python3 | |
| # word_letter_counter_for_llm_datasets.py | |
| """ | |
| A training set generator to assist an LLM in actually being able to count | |
| the letters in a given word. A model that can't count letters in a word isn't | |
| usable for critical tasks; incorrect letter counts lead to compounding mistakes. | |
| Outputs in JSON, can also use the NLTK corpus for a word dictionary, offering | |
| a quick way to create a massive letter counting dataset for different words. |
This file contains hidden or 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 | |
| # Function to print usage | |
| usage() { | |
| echo "Usage: $0 [-c <checksum file>] <tarball>" | |
| echo " -c <checksum file> : Optional, specify the checksum file to verify the tarball against" | |
| exit 1 | |
| } | |
| # Check if no arguments were provided |
This file contains hidden or 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 | |
| # ffmpeg_dump-a-video-dvd.sh | |
| # === INFO === | |
| # This is just a simple processing script that does the following: | |
| # | |
| # 1) Takes in all the ISO files in the directory; intended for video-DVD's. | |
| # 2) Extracts the contents (according to the minimum duration; change the variable below). | |
| # 3) Re-encodes the contents with HEVC/H.265, deinterlaces the video, and creates an output directory for each disc. | |
| # |
This file contains hidden or 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 | |
| # | |
| # Disable and Mask CUPS & Avahi Services | |
| # | |
| # ~~~ Overview ~~~ | |
| # | |
| # This script is designed to disable and mask specific CUPS (Common Unix Printing System) | |
| # and Avahi services and sockets on your Debian/Ubuntu tree Linux systems. | |
| # | |
| # It reduces possible attack vectors and mitigates several security vulnerabilities |
This file contains hidden or 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 | |
| # Script Name: manage_docker_services.sh | |
| # Description: Enables or disables Docker-related services on Ubuntu 24.04 LTS. | |
| # Usage: | |
| # - To disable Docker services: | |
| # sudo ./manage_docker_services.sh --disable | |
| # - To enable Docker services: | |
| # sudo ./manage_docker_services.sh --enable | |
| # - To be prompted for action: |
This file contains hidden or 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
| #> Created by FlyingFathead, Oct. 14th, 2024 | |
| #> https://github.com/FlyingFathead/ | |
| # | |
| # Here's an extremely simple example of a reverse tunnel proxy for serving | |
| # i.e. a local Flask over a remote VPS running nginx with htpasswd auth. | |
| # | |
| # .htpasswd with nginx requires 'apache2-utils'. | |
| # Install it with: `sudo apt-get install apache2-utils` | |
| # (on Debian/Ubuntu tree Linux systems) | |
| # |