Skip to content

Instantly share code, notes, and snippets.

View 32teeth's full-sized avatar
:octocat:
Get it done. Right.

Eugene Andruszczenko 32teeth

:octocat:
Get it done. Right.
View GitHub Profile
@32teeth
32teeth / Using Random Chance in GitHub Actions Workflows.md
Created June 25, 2025 20:23
Explores the strategic use of random chance in GitHub Actions workflows

Using Random Chance in GitHub Actions Workflows

Because... ...Why Not!

Introduction

This document explores the strategic use of random chance in GitHub Actions workflows. By introducing probabilistic execution paths, teams can simulate real-world unpredictability, optimize resource usage, and experiment with delivery strategies. This approach supports goals such as chaos engineering, canary releases, CI load management, A/B testing, observability validation, and developer engagement.

Stochastic Testing (Chaos Engineering Lite)

@32teeth
32teeth / DebouncedInputComponent.cpp
Created November 15, 2024 17:46
Debounced Input Component
#include "DebouncedInputComponent.h"
#include "TimerManager.h"
UDebouncedInputComponent::UDebouncedInputComponent()
{
PrimaryComponentTick.bCanEverTick = false;
DebounceDelay = 0.2f; // Default debounce delay in seconds
Threshold = 0.05f; // Default movement threshold
LastProcessedValue = 0.0f; // Initial value for comparison
@32teeth
32teeth / colors.sh
Created October 9, 2024 17:46
Color Generator
IndianRed=''
LightCoral=''
Salmon=''
DarkSalmon=''
LightSalmon=''
Crimson=''
Red=''
FireBrick=''
DarkRed=''
Pink=''
@32teeth
32teeth / console.js
Created October 2, 2024 18:18
Mynah-UI Console Test
const removeAllTabs = () => {
const tabs = mynahUI.getAllTabs();
Object.keys(tabs).forEach(key => mynahUI.removeTab(key, mynahUI.lastEventId));
};
const createTabs = (count) => {
const addTabButton = document.querySelector('.mynah-ui-icon.mynah-ui-icon-plus');
for (let i = 0; i < count; i++) {
addTabButton.click();
}
@32teeth
32teeth / convert_html_case.sh
Created September 27, 2024 11:53
HTML uppercase to lowercase
#!/bin/bash
# Check if directory is provided
if [ -z "$1" ]; then
echo "Usage: $0 <directory>"
exit 1
fi
DIRECTORY="$1"
/**
* Ask clarifying questions:
* - What types of input are we expecting (valid HTML strings)?
* - What should happen in the event of invalid or non-HTML inputs?
* - Should we focus solely on HTML or handle any generic XML/HTML-like string input?
*
* Analyze various solutions and tradeoffs:
* - We could use `DOMParser()` to parse the HTML and detect structural errors.
* - Alternative methods like regular expressions are not suitable for parsing HTML due to its complexity.
@32teeth
32teeth / mypy.ini
Created August 19, 2024 20:27
mypy ini file (generic)
# mypy.ini
[mypy]
python_version = 3.10
strict = True
warn_unused_ignores = True
warn_redundant_casts = True
warn_unused_configs = True
warn_unreachable = True
show_error_codes = True
@32teeth
32teeth / challenge.c
Last active July 8, 2024 22:10
CODE100 - GSM-7 or UCS-2
#include <stdio.h>
#include <string.h>
#include <stdbool.h>
#define GSM7_BITSET_SIZE 32 // 256 / 8
unsigned char gsm7_bitset[GSM7_BITSET_SIZE] = {0};
void init_gsm7_bitset() {
const char *gsm7_chars = "@£$¥èéùìòÇ\nØø\rÅåΔ_ΦΓΛΩΠΨΣΘΞ\x1BÆæßÉ "
"!\"#¤%&'()*+,-./0123456789:;<=>?"
@32teeth
32teeth / variables.css
Created March 29, 2024 00:31
CSS Variables: Used as a CDN for multiple projects
:root {
--scale-0: 1rem;
--scale-1: 1.125rem;
--scale-2: 1.25rem;
--scale-3: 1.5rem;
--scale-4: 1.875rem;
--scale-5: 2.25rem;
--scale-6: 3rem;
--scale-7: 3.75rem;
--scale-8: 4.5rem;
# Update your EV2 Amazon Linux box to whatever version you want
sudo apt purge nodejs npm
curl -o- https://raw.githubusercontent.com/creationix/nvm/v0.33.8/install.sh | bash
nvm install node
source ~/.bashrc
nvm install latest
# LIVE THE DREAM