Skip to content

Instantly share code, notes, and snippets.

View ianfabs's full-sized avatar

Ian Fabs ianfabs

View GitHub Profile
@ianfabs
ianfabs / attach_vhd_at_startup_windows_10.md
Last active June 28, 2023 14:59
How to Automount VHD on windows 10

So here's a pretty neat thing, I use VHD's to organize the space on my computer. You can too!

  • Click Start

  • Type in the search bar "Disk par" =>

  • Click first result =>

  • In the program, click "Action" =>

@ianfabs
ianfabs / kitty-themes.conf
Last active April 21, 2021 21:04
Kittens for kitty-themes!
kitten_alias ~/.config/kitty/try-theme.py try-theme
kitten_alias ~/.config/kitty/set-theme.py set-theme
" vim:fileencoding=utf-8:foldmethod=marker
if &compatible
set nocompatible " Be iMproved
endif
" Required:
set runtimepath+=~/.cache/dein/repos/github.com/Shougo/dein.vim
" Required:
@ianfabs
ianfabs / tuple.rs
Created November 15, 2019 20:49
A rust macro definition for creating tuples. Kinda useless, kinda cool.
#[macro_export]
#[doc = " generate tuple"]
macro_rules! tuple {
($($n: expr),*) => {($($n,)*)};
}
@ianfabs
ianfabs / element.js
Created November 14, 2019 02:45
A really dumb JSX library using the regular DOM. Needs work
const query = q => document.querySelector(q);
const queryAll = q => document.querySelectorAll(q);
const append = (p, c) => {
p.appendChild(c);
return p;
};
const text = t => document.createTextNode(t);
const element = (tag, attrs, children) => {
@ianfabs
ianfabs / README.md
Last active November 5, 2019 19:01
```hljs-meta
~/workspace
```$ export PATH
@ianfabs
ianfabs / list.md
Created September 3, 2019 23:46
A List of really cool web-based tools
@ianfabs
ianfabs / index.js
Created May 21, 2019 23:44
Zero-width char exploit
const toZW = (text) => {
const zeroPad = num => '00000000'.slice(String(num).length) + num;
const textToBinary = username => (
username.split('').map(char => zeroPad(char.charCodeAt(0).toString(2))).join(' ')
);
const binaryToZeroWidth = binary => (
binary.split('').map((binaryNum) => {
const num = parseInt(binaryNum, 10);
@ianfabs
ianfabs / gist:d2663f80da08da55ad497fb7f280006b
Last active May 21, 2019 22:13 — forked from xvrdm/gist:72e7eb17fa0f351a1d7550663f8bf713
Gruvbox Colorscheme for Kitty Terminal
#: Color scheme {{{
foreground #ebdbb2
background #282828
#: black
color0 #282828
color8 #928374
#: red
@ianfabs
ianfabs / index.js
Last active May 15, 2019 05:12 — forked from JonathanMH/index.js
JSON Web Token Tutorial: Express
//Original article
//https://jonathanmh.com/express-passport-json-web-token-jwt-authentication-beginners/
//loadash is stupid bloatware stop using it
//var _ = require("lodash");
var express = require("express");
var bodyParser = require("body-parser");
var jwt = require('jsonwebtoken');
var passport = require("passport");