Skip to content

Instantly share code, notes, and snippets.

/* See LICENSE file for copyright and license details. */
#include <X11/XF86keysym.h>
/* appearance */
static const char *fonts[] = {
"IBM Plex Mono:size=10"
};
static const char dmenufont[] = "IBM Plex Mono:size=11";
set -g prefix C-a
unbind C-b
bind C-a send-prefix
set -sg escape-time 0
# Window and panes
set -g base-index 1
setw -g pane-base-index 1
@erikroyall
erikroyall / ssort.iris
Created November 13, 2016 17:33
Doesn't work :(
# Selection Sort
# Initialize array
array.init a
array.push a 3 2 4 5 1
array.tostring a
array.length a
let n %retval
# Start the outer loop
function parse(code) {
const flow = [];
const state = {
expectingNextLine: false
};
// Remove blank lines and generate an array containing
// each line of code
const xcode =
code
sudo apt update
sudo apt install build-essential git libssl-dev curl -y
# NVM
curl -o- https://raw.githubusercontent.com/creationix/nvm/v0.32.0/install.sh | bash
export NVM_DIR="$HOME/.nvm"
[ -s "$NVM_DIR/nvm.sh" ] && . "$NVM_DIR/nvm.sh" # This loads nvm
nvm install node
# Java
@erikroyall
erikroyall / not.c
Created October 3, 2016 16:06
`echo "potato" | ./not` after you compile
#include <stdio.h>
#include <stdlib.h>
int main(void) {
int inp;
fprintf(stdout, "not ");
while (1) {
inp = getchar();
@erikroyall
erikroyall / clone-macro.s.js
Last active September 25, 2016 04:09
Sweet.js for clone Potato => Object.create(Potato)
syntax clone = function (ctx) {
let ident = ctx.next().value;
return #`Object.create(${ident})`;
}
var Potato = {
meaningOfLife: 42
};
var potato = clone Potato;
if [ -n "$DISPLAY" ];
then
PS1=$'\[\e[1;36;46m\]\u250F\u2578\[\e[37m\]\u\[\e[36m\]\u257A\[\e[35;45m\]\u2578\[\e[37m\]\H\[\e[35m\]\u257A\[\e[33;43m\]\u2578\[\e[0;30;43m\]\w\[\e[1;33m\]:\[\e[0m\]\n\[\e[1;36m\]\u2517\u2578\[\e[37m\]\$\[\e[0m\] ';
# If running without X
else
PS1=$'\[\e[1;36;46m\]\u250C\u2500\[\e[37m\]\u\[\e[36m\]\u2500\[\e[35;45m\]\u2500\[\e[37m\]\H\[\e[35m\]\u2500\[\e[33;43m\]\u2500\[\e[0;30;43m\]\w\[\e[1;33m\]:\[\e[0m\]\n\[\e[1;36m\]\u2514\u2500\[\e[37m\]\$\[\e[0m\] ';
fi;
alias loop "load_itempreset 0; joinclass heavyweapons; wait 25; voicemenu 1 4; looptaunt_on"; looptaunt_on
alias redirect loop
bind F6 "redirect"
bind F7 "alias redirect break"
alias break "alias redirect loop"
@erikroyall
erikroyall / .Xresources
Last active October 20, 2016 21:53
My dotfiles
xterm*termName: xterm-256color
XTerm*locale: true
XTerm*metaSendsEscape: true
Xterm*saveLines: 4096
xterm*faceName: Inconsolata
xterm*faceSize: 13
! special
*.foreground: #d0d0d0
*.background: #151515