Skip to content

Instantly share code, notes, and snippets.

View quienn's full-sized avatar

Martín Aguilar quienn

  • Mexico
  • 03:29 (UTC -06:00)
View GitHub Profile
@quienn
quienn / Set-LuaVersion.ps1
Last active November 26, 2022 19:22
Set-LuaVersion: hererocks Wrapper for Windows PowerShell
function Set-LuaVersion {
param(
[string]$Hererocks = "$HOME\Dev\Lua",
[switch]$Jit,
[Parameter(Mandatory=$true,Position=0)]
[string]$Version
)
$LuaVersion = $(if ($Jit) { "jit$Version" } else { $Version })
@quienn
quienn / lpm.cmd
Last active August 16, 2022 01:53
lite's Plugin Manager for Windows
@ECHO OFF
SET GITHUB_URL=https://raw.githubusercontent.com/rxi/lite-plugins/master/plugins
SET PLUGIN_DIR=%ProgramFiles%\lite\data\plugins
SET /A DOWNLOAD_COUNT=0
:main
FOR /F "tokens=*" %%A in (%USERPROFILE%\.lite_plugins) do (
IF EXIST "%PLUGIN_DIR%\%%A.lua" (
@quienn
quienn / youtube-adblock.user.js
Last active November 28, 2022 13:12
Userscript that blocks YouTube ads
if (window.location.hostname === 'www.youtube.com') {
const adBlocker = setInterval(() => {
const ad = [...document.querySelectorAll('.ad-showing')][0];
if (ad) {
document.querySelector('video').playbackRate = 10;
const btn = document.querySelector('.videoAdUiSkipButton,.ytp-ad-skip-button');
if (btn) {
btn.click();
}
} else {
@quienn
quienn / eftc.moon
Last active January 19, 2022 00:07
elementary OS Flatpak Theme Changer
--- Run this script using a cronjob. I'm running this according to my elementary OS settings:
--- From 06:00 AM (light theme) to 09:00 PM (dark theme) Mexico City Timezone
exec = (command, ...) ->
io.popen "#{command} #{table.concat (table.pack ...), ' '}"
FLATHUB_APPS = {}
local COLOR_SCHEME
local THEME