Skip to content

Instantly share code, notes, and snippets.

@tararoys
tararoys / May12knausj-master-cheatsheet.pdf
Last active April 9, 2025 09:47
Code to print out all voice commands in the knausj talon repository,
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.

Encoder/Decoder System

.enc File

Data Types

Basic Types

  • bool
@aashari
aashari / 00 - Cursor AI Prompting Rules.md
Last active April 9, 2025 09:45
Cursor AI Prompting Rules - This gist provides structured prompting rules for optimizing Cursor AI interactions. It includes three key files to streamline AI behavior for different tasks.

Cursor AI Prompting Framework

This repository provides a structured set of prompting rules to optimize interactions with Cursor AI. It includes three key files to guide the AI’s behavior across various coding tasks.

Files and Their Roles

core.md

  • Purpose: Establishes foundational rules for consistent AI behavior across all tasks.
  • Usage: Place this file in your project’s .cursor/rules/ folder to apply it persistently:
  • Save core.md under .cursor/rules/ in the workspace root.
@parmentf
parmentf / GitCommitEmoji.md
Last active April 9, 2025 09:44
Git Commit message Emoji
@joaopfsilva
joaopfsilva / iban.js
Created September 27, 2019 07:40
IBAN validator
// https://github.com/arhs/iban.js
(function (root, factory) {
if (typeof define === 'function' && define.amd) {
// AMD. Register as an anonymous module.
define(['exports'], factory);
} else if (typeof exports === 'object' && typeof exports.nodeName !== 'string') {
// CommonJS
factory(exports);
} else {
// Browser globals
@BuonOmo
BuonOmo / .gitconfig
Last active April 9, 2025 09:38
Git blame color scale from 20 month ago to now (https://stackoverflow.com/a/66250482/6320039)
[color "blame"]
highlightRecent = 234, 23 month ago, 235, 22 month ago, 236, 21 month ago, 237, 20 month ago, 238, 19 month ago, 239, 18 month ago, 240, 17 month ago, 241, 16 month ago, 242, 15 month ago, 243, 14 month ago, 244, 13 month ago, 245, 12 month ago, 246, 11 month ago, 247, 10 month ago, 248, 9 month ago, 249, 8 month ago, 250, 7 month ago, 251, 6 month ago, 252, 5 month ago, 253, 4 month ago, 254, 3 month ago, 231, 2 month ago, 230, 1 month ago, 229, 3 weeks ago, 228, 2 weeks ago, 227, 1 week ago, 226
[blame]
coloring = highlightRecent
date = human
@coltenkrauter
coltenkrauter / fix-wsl2-dns-resolution
Last active April 9, 2025 09:37
Fix DNS resolution in WSL2
More recent resolution:
1. cd ~/../../etc (go to etc folder in WSL).
2. echo "[network]" | sudo tee wsl.conf (Create wsl.conf file and add the first line).
3. echo "generateResolvConf = false" | sudo tee -a wsl.conf (Append wsl.conf the next line).
4. wsl --terminate Debian (Terminate WSL in Windows cmd, in case is Ubuntu not Debian).
5. cd ~/../../etc (go to etc folder in WSL).
6. sudo rm -Rf resolv.conf (Delete the resolv.conf file).
7. In windows cmd, ps or terminal with the vpn connected do: Get-NetIPInterface or ipconfig /all for get the dns primary and
secondary.
#!/bin/bash
# Prompt the user to specify whether they want to remove the downloaded files or not
read -p "Do you want to remove the downloaded files? (y/n): " remove_files
# Loop through a range of numbers from 7422 to 17000
for i in $(seq 7422 17000); do
# Construct the filename based on the current loop iteration
filename="BoltApp-$i.apk"
@imerfanahmed
imerfanahmed / env_updater.sh
Created April 9, 2025 09:28
Update .env Variables for All Apps in a Single Directory with One Command
#!/bin/bash
# Script to add or update environment variables in Laravel .env files
# Usage: ./env_updater.sh [webapps_directory] [env_key] [env_value]
WEBAPPS_DIR=${1:-"webapps"}
ENV_KEY=$2
ENV_VALUE=$3
# Check if required parameters are provided
@Aldaviva
Aldaviva / Windows 10 & 11 services.md
Last active April 9, 2025 09:34
Safety of disabling services in Windows 10 and 11

These settings apply to normal, functioning Windows 10 and 11 Pro desktops and laptops with

  • wired Ethernet
  • Wi-Fi
  • Bluetooth
  • IPv4
  • IPv6
  • no touch screen

Safe to disable