Skip to content

Instantly share code, notes, and snippets.

View tylergets's full-sized avatar

Tyler Getsay tylergets

View GitHub Profile
SELECT
"Order".id,
C.name,
A.line1,
A.line2,
A.city,
A.zip,
S.name,
H.name as "hatchery_name",
HA.line1 as "hatchery_line1",
@tylergets
tylergets / index.js
Created April 14, 2023 14:21
Search for OpenAI API Keys in APK files
const fs = require('fs');
const { exec } = require('child_process');
const apktoolPath = 'apktool'; // Update this with the path to apktool if it's not in your PATH
const rgPath = 'rg'; // Update this with the path to ripgrep if it's not in your PATH
// Regular expression you want to search for
const keyPattern = 'sk\\-[A-Za-z0-9]{32}';
// Execute a command and return a promise
@tylergets
tylergets / setup.sh
Created April 28, 2022 11:44
Ubuntu 21.04 Server Setup
#!/bin/bash
# Tailscale Setup
curl -fsSL https://pkgs.tailscale.com/stable/ubuntu/hirsute.noarmor.gpg | sudo tee /usr/share/keyrings/tailscale-archive-keyring.gpg >/dev/null
curl -fsSL https://pkgs.tailscale.com/stable/ubuntu/hirsute.tailscale-keyring.list | sudo tee /etc/apt/sources.list.d/tailscale.list
apt-get update
apt-get install tailscale
tailscale up
# Docker Install
@tylergets
tylergets / extras.sh
Last active March 20, 2022 20:25
Arch Setup
# All Fonts
yay -S all-repository-fonts
@tylergets
tylergets / gm_api.java
Created December 19, 2018 01:59
GM API
package com.gm.onstar.sdk.client;
import com.gm.onstar.sdk.request.AlertRequest;
import com.gm.onstar.sdk.request.UpdateVehicleDetailRequest;
import defpackage.cxr;
import defpackage.cyl;
import defpackage.cyn;
import defpackage.dap;
import defpackage.daq;
import defpackage.das;
@tylergets
tylergets / wifi-freshner.ino
Created November 26, 2018 23:01
Arduino code for wifi air freshner
gith#include <Button.h>
#include <ESP8266WiFi.h>
#include <ESP8266WebServer.h>
int motorPin = 14;
int buttonPin = 4;
static unsigned char motorState = LOW;
@tylergets
tylergets / arraybuffer.js
Last active June 13, 2018 02:24
Web BLE Demo
startDemo() {
let JUMPER_SERVICE = "cdeacb80-5235-4c07-8846-93a37ee6b86d";
let JUMPER_CHARACTERISTIC = "cdeacb81-5235-4c07-8846-93a37ee6b86d";
navigator.bluetooth.requestDevice({filters: [{services: [JUMPER_SERVICE]}]})
.then(device => device.gatt.connect())
.then(server => {
console.log('Connected to device');
return server.getPrimaryService(JUMPER_SERVICE);
})
@tylergets
tylergets / forge.sh
Last active January 21, 2018 19:37
Laravel Forge Setup Script
#
# REQUIRES:
# - server (the forgfordgee server instance)
# - event (the forge event instance)
# - sudo_password (random password for sudo)
# - db_password (random password for database user)
# - callback (the callback URL)
#
@tylergets
tylergets / vesync.py
Created December 6, 2017 23:15
VeSync Home Assistant
"""
Support for Etekcity Wifi Smart Switches.
For more details about this platform, please refer to the documentation at
https://home-assistant.io/components/switch.vesync/
"""
import logging
import voluptuous as vol
@tylergets
tylergets / install_pubkey.sh
Last active October 11, 2017 18:12
Public Key
echo "ssh-rsa AAAAB3NzaC1yc2EAAAADAQABAAACAQC9O/oqd1tu5NohBrO6ElIrOxxmnA5caJJlswtrh1gsUfotJdL5cPV9B2Bu2O+vzA4lKB0NkZCfcM7RoXPWFaJSNU9SDx2n/4CSn/tVUoexClBVwazVWA/AZGCcbazbTUFLhgUTc3JIO5ll/nrLIIN5gC3FSoeyBuce71OuLM+4DQreTMFj5rANiRh75uq9pXIKG0jTUpA4RlbfPAgNcf7Abs9vLCAd3ucoT8KuFulX7y5YIElblVWWhroUfApYeHYCECJNUsdfX3Wz0hnsNAclkK8vXMpHCjPvW/PjmzWjwJg3LpAyfZW0wdbjxr57yAmBjfnepK7r6MCGjj+3MrclFDEUgjswAlgbqu+04GK48N7XhWqqPZ5BQnQcXlBtCOhiXDNsaq9OOvpEeHcYqAJVoZN+FlFdp+So5EwxjRv/7vqWa4gN/sd6PDXLlPo5rRno7asbXxxKTglbYCtVpNXX6nqaFoyKkKwqDWwEgNfZ3w2on0PNjadNp5VLphgK2k81D6qGYwYdQq91W3BGHjcF26ITiuFMiObhyq9X1lIZ+PXofcYbrdARAXAMPYN+90K1KQBYS2REK2Ql8b93ON3g0c/+rcY4OE00CmpDxosW+TM893YfWlEOsSQhhvUwJz6y8Lhm4PrmPoxFXOpcLkvHc0tuu7uKeodN140S8QzFsw== tylergetsay@gmail.com" >> ~/.ssh/authorized_keys
echo "SSH key installed"