Skip to content

Instantly share code, notes, and snippets.

View supermarsx's full-sized avatar
💫

Mariana supermarsx

💫
  • Δ on earth™
  • 23:51 (UTC)
View GitHub Profile
@supermarsx
supermarsx / unlock-files.ps1
Created November 7, 2025 15:24
Mass unblock files recursively on Windows
# without progress
Get-ChildItem -Path "C:\Your\Path\Here" -Recurse -File | Unblock-File
# with progress
Get-ChildItem -Path "C:\Your\Path\Here" -Recurse -File | ForEach-Object { Write-Host "Unblocking $($_.FullName)" ; Unblock-File $_ }
@supermarsx
supermarsx / shutdown-all-docker-compose.sh
Created November 4, 2025 15:47
Shutdown and remove all Docker Compose containers subfolders within a directory
find . -type f \( -name "docker-compose.yml" -o -name "compose.yaml" \) -execdir sh -c 'echo "↓ Stopping in $(pwd)"; docker compose down' \;
@supermarsx
supermarsx / storesace-product-scraper.user.js
Created November 3, 2025 18:27
StoresAce Product Scraper — CSV Export with UI (parallel per-item)
// ==UserScript==
// @name StoresAce Product Scraper — CSV Export with UI (parallel per-item)
// @namespace https://supermarsx.github.io/userscripts
// @version 1.1.0
// @description Scrape all product data and export a flattened CSV. Now requests per-item HTML, KPIs, composition (and optionally cardex) IN PARALLEL so each product is fetched “all at once”. Includes overlay UI with Start/Cancel, progress bar, retry/backoff, and failure list.
// @author Supermarsx
// @match https://COMPANYID.storesace.com/*
// @run-at document-end
// @grant none
// ==/UserScript==
@supermarsx
supermarsx / portainer-ce-auto-install-update.sh
Last active October 31, 2025 16:52
Portainer CE Auto-Installer and Auto-Updater Script
#!/usr/bin/env bash
# =============================================================================
# Portainer Auto-Installer & Auto-Updater
# =============================================================================
# Purpose
# Idempotently install or update Portainer CE to the latest image and
# automatically keep it up-to-date via cron. The script only recreates the
# container when a newer image is available and verifies successful startup.
#
# What it does
@supermarsx
supermarsx / force-enable-windows-11-25h2.bat
Created October 31, 2025 16:20
Force enable Windows 11 25H2 update availability
REG ADD HKEY_LOCAL_MACHINE\SOFTWARE\Policies\Microsoft\Windows\WindowsUpdate /v DeferFeatureUpdates /t REG_DWORD /d "0" /f
REG ADD HKEY_LOCAL_MACHINE\SOFTWARE\Policies\Microsoft\WindowsStore /v DisableOSUpgrade /t REG_DWORD /d "0" /f
REG ADD HKEY_LOCAL_MACHINE\SYSTEM\Setup\UpgradeNotification /v UpgradeAvailable /t REG_DWORD /d "1" /f
REG ADD HKEY_LOCAL_MACHINE\SOFTWARE\Policies\Microsoft\Windows\WindowsUpdate /v ProductVersion /t REG_SZ /d "Windows 11" /f
REG ADD HKEY_LOCAL_MACHINE\SOFTWARE\Policies\Microsoft\Windows\WindowsUpdate /v TargetReleaseVersion /t REG_DWORD /d "1" /f
REG ADD HKEY_LOCAL_MACHINE\SOFTWARE\Policies\Microsoft\Windows\WindowsUpdate /v TargetReleaseVersionInfo /t REG_SZ /d "25H2" /f
@supermarsx
supermarsx / reverse-nginx-rds.conf
Created October 20, 2025 15:49
Reverse proxy setup to access RDP Remote Apps portal, useful for SSL Certificate setup.
location /rpc/ {
proxy_pass https://IPADDRESS/rpc/;
proxy_ssl_server_name on;
proxy_ssl_verify off;
proxy_set_header Host $host;
proxy_set_header X-Real-IP $remote_addr;
proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for;
proxy_set_header X-Forwarded-Proto $scheme;
proxy_http_version 1.1;
proxy_buffering off;
@supermarsx
supermarsx / iisstart.html
Last active October 20, 2025 15:44
Simple drop-in replacement for an easy RDWeb redirect. Simple IIS RDS redirect
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="refresh" content="0; URL='/RDWeb'"/>
<script>window.location.href='/RDWeb';</script>
<meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1" />
<title>Please wait...</title>
</head>
<body>
<h1>Please wait...</h1>
@supermarsx
supermarsx / exchange-remove-auto-mapping.ps1
Created September 8, 2025 15:06
Exchange remove auto mapping mailboxes for user
# Set the user to fix
$user = "DOMAIN\UserName"
# Reapply FullAccess with AutoMapping disabled on every mailbox where the user currently has FullAccess
Get-Mailbox -ResultSize Unlimited -RecipientTypeDetails UserMailbox,SharedMailbox,RoomMailbox,EquipmentMailbox |
Where-Object {
Get-MailboxPermission -Identity $_.Identity -User $user -ErrorAction SilentlyContinue |
Where-Object { $_.AccessRights -contains "FullAccess" -and -not $_.IsInherited }
} | ForEach-Object {
Remove-MailboxPermission -Identity $_.Identity -User $user -AccessRights FullAccess -Confirm:$false
@supermarsx
supermarsx / prompt-codex-cli-agents-instruction.md
Created September 7, 2025 10:39
Codex CLI agents.md generation instruction/prompt

Generate a file named AGENTS.md that serves as a contributor guide for this repository. Your goal is to produce a clear, concise, and well-structured document with descriptive headings and actionable explanations for each section. Follow the outline below, but adapt as needed — add sections if relevant, and omit those that do not apply to this project.

Document Requirements

  • Title the document "Repository Guidelines".
  • Use Markdown headings (#, ##, etc.) for structure.
@supermarsx
supermarsx / wifiqr.sh
Created August 27, 2025 17:32
Wi-Fi QR Forge, create QR codes for Wi-Fi networks fast
#!/usr/bin/env bash
# Wi‑Fi QR Forge — a Wi‑Fi QR code generator with optional password creation
#
# Requirements: qrencode (preferred). Optional: xclip/wl-copy/pbcopy to copy payload to clipboard.
#
# Examples:
# ./wifiqr.sh -s "MySSID" -p "s3cretpass" -t WPA -o ./mywifi.png
# ./wifiqr.sh -s "Café do Bairro" -t nopass -f ansi # print QR to terminal
# ./wifiqr.sh -s Net -g 16 -o wifi.svg -f svg -C # generate 16‑char password, SVG, copy payload
# ./wifiqr.sh -s Net -p pass -o out.png -R # add R:1 (WPA3 transition mode disabled)