Skip to content

Instantly share code, notes, and snippets.

View kevinfiol's full-sized avatar
🌔
man on the moon

kevinfiol

🌔
man on the moon
View GitHub Profile
@x43x61x69
x43x61x69 / vnc_install.sh
Last active April 29, 2024 05:04
Steam Deck VNC Installation
#!/bin/bash
#
# Script for installing x11vnc on Steam Deck.
#
# Install:
#
# sh -c "$(curl -fsSL https://gist.githubusercontent.com/x43x61x69/9a5a231a25426e8a2cc0f7c24cfdaed9/raw/vnc_install.sh?$RANDOM)"
#
# This will modify root filesystem so it will probably get
# overwrite on system updates but is totally ok executing
@ef4
ef4 / examples.md
Last active May 23, 2024 04:31
Webpack 5 Node Polyfills Upgrade Cheatsheet

Webpack 5 Node Polyfills Upgrade Cheatsheet

Webpack 4 automatically polyfilled many Node APIs in the browser. This was not a great system, because it could lead to surprisingly giant libraries getting pulled into your app by accident, and it gave you no control over the exact versions of the polyfills you were using.

So Webpack 5 removed this functionality. That means you need to make changes if you were relying on those polyfills. This is a quick reference for how to replace the most common patterns.

List of polyfill packages that were used in webpack 4

For each automatically-polyfilled node package name on the left, this shows the name of the NPM package that was used to polyfill it on the right. Under webpack 5 you can manually install these packages and use them via resolve.fallback.

@Alloyed
Alloyed / ugh.md
Last active April 28, 2021 03:49
how to install luarocks on windows in 2020 :(
  1. get python (lol). make sure you check the box that says "add python to PATH", this will be important later

https://www.python.org/

  1. get a visual studio compiler. make sure to select either desktop development with C++ or, game dev with C++, or both~

https://visualstudio.microsoft.com/downloads/

  1. open a native tools command prompt: select x64 native tools command prompt for VS2019 from the start menu
@rufoa
rufoa / patch.sh
Last active May 24, 2024 04:22
sublime merge 2 build 2068 linux
#!/bin/bash
set -o errexit
set -o nounset
set -o pipefail
target="${1:-/opt/sublime_merge/sublime_merge}"
check_sha() {
local sha_valid
@tesselode
tesselode / swept-aabb.lua
Last active March 31, 2023 04:18
swept AABB collision detection implemented in Lua (commentated)
--[[
moves rectangle A by (dx, dy) and checks for a collision
with rectangle B.
if no collision occurs, returns false.
if a collision does occur, returns:
- the time within the movement when the collision occurs (from 0-1)
- the x component of the normal vector
- the y component of the normal vector
@JAMSUPREME
JAMSUPREME / README.md
Last active March 24, 2020 16:22
CI/CD Primer

CI/CD Primer

This is designed to be a quick primer on Continuous Integration and Continuous Delivery. We will also use the term "Continuous Deployment" to mean a subset of Continuous Delivery in which you are delivering with every commit.

Acronyms and Terms

II/ID: Intermittent Integration & Delivery

For the sake of this discussion, we should have a term for "The opposite of CI/CD" and we'll call that "Intermittent Integration" and "Intermittent Delivery" so that we have a shared vocabulary.

@TehShrike
TehShrike / eslint cli arguments.txt
Last active August 11, 2022 16:11
Ignore fixable eslint rules
eslint --rule 'no-extra-boolean-cast: 0' --rule 'no-extra-parens: 0' --rule 'no-extra-semi: 0' --rule 'no-regex-spaces: 0' --rule 'no-unsafe-negation: 0' --rule 'curly: 0' --rule 'dot-location: 0' --rule 'dot-notation: 0' --rule 'eqeqeq: 0' --rule 'no-else-return: 0' --rule 'no-extra-bind: 0' --rule 'no-extra-label: 0' --rule 'no-floating-decimal: 0' --rule 'no-implicit-coercion: 0' --rule 'no-multi-spaces: 0' --rule 'no-unused-labels: 0' --rule 'no-useless-return: 0' --rule 'wrap-iife: 0' --rule 'yoda: 0' --rule 'strict: 0' --rule 'no-undef-init: 0' --rule 'array-bracket-newline: 0' --rule 'array-bracket-spacing: 0' --rule 'array-element-newline: 0' --rule 'block-spacing: 0' --rule 'brace-style: 0' --rule 'capitalized-comments: 0' --rule 'comma-dangle: 0' --rule 'comma-spacing: 0' --rule 'comma-style: 0' --rule 'computed-property-spacing: 0' --rule 'eol-last: 0' --rule 'func-call-spacing: 0' --rule 'function-paren-newline: 0' --rule 'implicit-arrow-linebreak: 0' --rule 'indent: 0' --rule 'jsx-quotes: 0' --ru
function ConvertGamesToITAD ($allGames) {
foreach ($group in $allGames | Group-Object -Property Name) {
$games = $group.Group
$playtime = ($games.Playtime | Sort-Object)[-1]
$status = ($games.CompletionStatus | Sort-Object)[-1]
@{
title = $games[0].Name
status = ([string]$status).ToLower()
playtime = $playtime / 60
copies = @(foreach ($game in $games) {
@panoply
panoply / index.html
Last active March 19, 2021 07:20
Rollup Configuration – Uses Buble, SASS and Serve. Use with Mithril.js
<!doctype html>
<html>
<head>
<meta charset="UTF-8">
<title>Mithril Rollup.js</title>
<meta name="viewport" content="width=device-width, initial-scale=1" />
<link href="bundle.css" rel="stylesheet" />
</head>
<body>
<div id="app"></div>
@dorelljames
dorelljames / letsencrypt-guide-nginx-acme.sh.md
Last active March 16, 2024 10:34
SSL via Let's Encrypt (nginx server)

Nginx SSL via Let's Encrypt and acme.sh

This guide is intended to walk you through installation of a valid SSL on your server for your site at example.com. This example is using root user, you may need to use sudo if you encounter problems such as write permissions.

Pre-requisites

  • Install acme.sh on your server. This will create a acme.sh folder in your home directory and more importantly create an everyday cron job to check and renew certificates if needed.
  • Install nginx server (different per distibution so just make sure you have it up and running)