Skip to content

Instantly share code, notes, and snippets.

View pleabargain's full-sized avatar
🏠
office

Dennis pleabargain

🏠
office
View GitHub Profile
@pleabargain
pleabargain / storm.svg
Created November 21, 2025 15:51
storm in SVG
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
@pleabargain
pleabargain / unzipallindir.ps1
Created November 20, 2025 08:35
powershell script unzip all folders in current directory
Get-ChildItem -Filter "*.zip" | ForEach-Object { $folder = $_.BaseName; New-Item -ItemType Directory -Path $folder -Force | Out-Null; Expand-Archive -Path $_.FullName -DestinationPath $folder -Force; Write-Host "Extracted: $($_.Name) -> $folder\" -ForegroundColor Green }
@pleabargain
pleabargain / man.svg
Created November 20, 2025 08:20
SVG of man climbing mountain
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
@pleabargain
pleabargain / gist:b5ecf8698c9cfa727fe2f3ce729a0d32
Created October 22, 2025 11:09
google app script that loads random emojis into google doc
/**
* @fileoverview Google Apps Script for inserting random emojis into a Google Doc.
* This script creates a custom menu on document load and inserts five random emojis
* with a large font size when the menu item is clicked.
*/
// A list of diverse and common emojis to choose from.
const EMOJIS = [
'😀', '🤩', '🥳', '😎', '🤯', '😜', '😍', '😭', '🤯',
'🐶', '🐱', '🐭', '🐹', '🐰', '🐼', '🦊', '🐻', '🐨',
@pleabargain
pleabargain / randoimage.gs
Created October 22, 2025 10:57
google app script that loads a random image into a google doc
/**
* Creates a custom menu in the Google Doc interface when the document is opened.
*/
function onOpen() {
DocumentApp.getUi()
.createMenu('Random Image')
.addItem('Insert New Image', 'insertRandomPictureInDoc')
.addToUi();
}
@pleabargain
pleabargain / wsdash.py
Created October 20, 2025 08:19
Scans the specified directory and replaces whitespace in item names with dashes. python
import os
import re
import sys
def rename_items(directory, perform_rename=False):
"""
Scans the specified directory and replaces whitespace in item names with dashes.
:param directory: The directory path to scan.
:param perform_rename: If True, actually renames the files/folders. If False (preview mode),
@pleabargain
pleabargain / randofont.py
Created July 8, 2025 09:01
python random font to image
from PIL import Image, ImageDraw, ImageFont
import os
import random
import argparse
import sys
from datetime import datetime
def get_system_fonts():
"""Finds all usable TrueType font paths on the system."""
font_paths = []
@pleabargain
pleabargain / gemtravel.txt
Created June 10, 2025 10:39
gemini gem travel planner prompt with emphasis on budget and maps
LLM Travel Assistant Instructions
Objective
The LLM should provide personalized travel assistance, including itinerary creation, map guidance, and budget planning, tailored to the user's preferences and constraints.
Core Functions
@pleabargain
pleabargain / compress-video.ps1
Created May 30, 2025 07:54
powershell check for ffmpeg then list all vid files in directory then prompt user to compress video
# Check if FFmpeg is installed
$ffmpegInstalled = Get-Command ffmpeg -ErrorAction SilentlyContinue
if (-not $ffmpegInstalled) {
Write-Host "FFmpeg is not installed or not found in PATH. Please install it before running this script."
exit
}
# Get all video files in the current directory
$videoFiles = Get-ChildItem -Filter *.mp4
@pleabargain
pleabargain / llamarunandsavelocally.ps
Created May 27, 2025 09:23
run llama 3.2 locally get prompt and save output to file locally
# Prompt user for the prompt to Llama3.2
$llamaPrompt = Read-Host "Enter your prompt for Llama3.2"
# Take the first 10 characters of the prompt and remove all spaces
$filename = ($llamaPrompt.Substring(0, [Math]::Min(10, $llamaPrompt.Length))).Replace(" ", "")
# Set the desktop path
$desktopPath = [System.IO.Path]::Combine($env:USERPROFILE, "Desktop")
$filePath = "$desktopPath\$filename.txt"