Skip to content

Instantly share code, notes, and snippets.

View Lomeli12's full-sized avatar
🏳️‍🌈
Playing way too much FFXIV

Anthony Lomeli Lomeli12

🏳️‍🌈
Playing way too much FFXIV
View GitHub Profile
@Lomeli12
Lomeli12 / ArchWiki_Redirector.json
Created May 16, 2022 20:08
My Redirector settings to use the normal desktop arch wiki theme instead of the default mobile theme.
{
"createdBy": "Redirector v3.5.3",
"createdAt": "2022-01-14T02:40:38.201Z",
"redirects": [
{
"description": "ArchWiki Mobile Disable 1",
"exampleUrl": "https://wiki.archlinux.org/index.php?title=Main_page#The_distribution",
"exampleResult": "https://wiki.archlinux.org/index.php?title=Main_page&useskinversion=1#The_distribution",
"error": null,
"includePattern": "https://wiki.archlinux.org*?*#*",
@Lomeli12
Lomeli12 / build.gradle
Created February 2, 2022 02:38
Custom task for multi-mod projects
// The following is a custom gradle task to make setting up a multimod project in IntelliJ less painful
// Setup a base project (I just use the examplemod from the MDK) and setup like normal. Then import your
// other mods as modules. Run the genIntelliJRuns task like normal, but then follow up with the updateRuns
// task written below, making sure to replace the items in the modProjects array with your own. It might
// also be a good idea to edit the run configurations in IntelliJ to build the whole project instead of just
// the base project (Edit Configuration -> For each run<blank> remove the "Build" step -> Click the + ->
// Add "Build Project" task -> drag to begining before "prepareRun<blank>" task)
def updateXMLRuns(String runName) {
def modProjects = [
@Lomeli12
Lomeli12 / TwitchChatOverlay.css
Last active January 5, 2022 04:51
Custom Twitch Chat OBS Widget
/**
This is just the very basic CSS for having a Twitch Chat widget on OBS
How to use:
1. Add a Browser Widget to your OBS Sources (I use SE.Live [https://streamelements.com/obslive] since newer versions of OBS don't have a
Browser widget, but any Browser widget that allow custom CSS should work)
2. Set the URL to your channel's popup chat (https://www.twitch.tv/popout/<channel>/chat?popout=)
3. Copy paste the CSS below into the Custom CSS text box, or the equivalent for your widget.
4. Adjust the values of font-size and line-height as needed for how you want it to appear on stream.
#!/bin/bash
reset
set +x
echo "------- LE2117 to LE2115 Conversion Bash Script by Lomeli12@xda -------"
echo "Please make sure you are in bootloader, your screen should say \"Fastboot Mode\" in red."
echo "You should be using the latest Google platform tools from your system's package manager (Apt, Yay, Brew, Scoop, etc)."
echo -e "Do not continue if you are unsure. \n"
# Make sure the user knows the risk and wants to continue
while true; do
@Lomeli12
Lomeli12 / install.sh
Last active August 16, 2019 06:24
Beaver Install Script
#!/bin/bash
#
# MIT License
#
# Copyright (c) 2019 Anthony Lomeli
#
# Permission is hereby granted, free of charge, to any person obtaining a copy
# of this software and associated documentation files (the "Software"), to deal
# in the Software without restriction, including without limitation the rights
# to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
@Lomeli12
Lomeli12 / RemoveSlotsCommand.java
Created March 3, 2019 05:12
What the hell did I just write?
@Override
public void accept(CommandDispatcher<ServerCommandSource> commandDispatcher) {
commandDispatcher.register(ServerCommandManager.literal(getName()).requires(
(commandSource) -> commandSource.hasPermissionLevel(2))
.then(ServerCommandManager.literal("all")
.executes((commandContext) -> removePlayersSlots(commandContext.getSource(), null,
InventoryUtils.MAX_SLOTS))
.then(ServerCommandManager.argument("targets", GameProfileArgumentType.create())
.executes((commandContext) -> removePlayersSlots(commandContext.getSource(),
GameProfileArgumentType.getProfilesArgument(commandContext, "targets"),

How to use your Keybase.io PGP key to sign commits


  1. Download and install GnuPG.
  2. Download and install Keybase, then sign into the app.
  3. Get the hexadecimal fingerprint for your key. You can find this on your Keybase public profile page, and ignore the spaces. For this tutorial, I'll use my key as an example.

  1. Import you Keybase keys into GnuPG.
@Lomeli12
Lomeli12 / ControllerInput.kt
Created April 1, 2018 06:15
LibGDX PS4 Controller Reference
import com.badlogic.gdx.controllers.Controller
import com.badlogic.gdx.controllers.ControllerAdapter
import com.badlogic.gdx.controllers.PovDirection
import ktx.log.info
object ControllerInput : ControllerAdapter() {
override fun connected(controller: Controller?) {
if (controller != null) info { "Controller Connected: $controller" }
}
@Lomeli12
Lomeli12 / CPOL.txt
Created September 14, 2017 03:30
The CPOL License as text. Since Code Project only provides it in the form of an HTML document, I took the time to make it a text document like every other license out there.
The Code Project Open License (CPOL) 1.02
Preamble
This License governs Your use of the Work. This License is intended to allow
developers to use the Source Code and Executable Files provided as part of the
Work in any application in any form.
The main points subject to the terms of the License are:
@Lomeli12
Lomeli12 / Program.cs
Created May 8, 2017 22:06
Hasher Source
using System;
using System.IO;
using System.Text;
using System.Reflection;
using System.Diagnostics;
using System.Windows.Forms;
using System.Collections.Generic;
using System.Security.Cryptography;
namespace hasher {