Skip to content

Instantly share code, notes, and snippets.

Avatar

jared shmup

View GitHub Profile
@shmup
shmup / semantic-layout.html
Created Oct 29, 2020 — forked from thomd/semantic-layout.html
Standard HTML5 Semantic Layout
View semantic-layout.html
<!DOCTYPE html>
<html>
<head>
<meta charset="utf-8" />
<title>Title</title>
<link href="stylesheets/main.css" rel="stylesheet" />
</head>
<body>
<header>
<hgroup>
@shmup
shmup / vr
Last active Oct 1, 2020
open all currently (and previously) modified files in vim
View vr
#!/usr/bin/env bash
# http://ix.io/2zhL/sh
# vr is "vim resume"
# open all currently (and previously) modified files in vim
# tell me‡ if it doesn't work for you, please
function help {
cat << EOF
@shmup
shmup / j2html.py
Created Sep 23, 2020
renders and prints a jinja2 template with optional json to STDOUT
View j2html.py
#!/usr/bin/env python3
# http://ix.io/2ykn/py
# renders and prints a jinja2 template with optional json to STDOUT
# requires: python3, jinja2
# usage
# $ ./j2html /path/to/template
# $ ./j2html /path/to/template --json_data /path/to/json
@shmup
shmup / scream.vim
Last active Apr 16, 2020
When intently combing code and comment relevancy, I want 'em to scream
View scream.vim
" scream.vim, so comments stand out when I'm intently combing code
" :SCREAM - Grey100 on IndianRed
" :WHISPER - Apprentice defaults
function! LouderComments() abort
highlight Comment ctermbg=131 ctermfg=231
highlight Todo ctermbg=131 ctermfg=231 cterm=reverse
endfunction
command! SCREAM silent! call LouderComments()
@shmup
shmup / nonymous-ix.vim
Last active Aug 8, 2020
nonymous-ix.vim uses .netrc for auth, and fucks with ix.io
View nonymous-ix.vim
" nonymous-ix.vim uses .netrc for auth, and fucks with ix.io
" insert :IX [optional visual selection] - copies url to system clipboard
" replace :RX <URL> [optional visual selection]
" delete :DX <URL>
if has('win64') || has('win32') || has('win16')
let s:env = 'WINDOWS'
else
let s:env = toupper(substitute(system('uname'), '\n', '', ''))
endif
View isaac.md

finding secret rooms

  1. a room touching 3 other rooms, with no obstacles on the walls (like rocks, spikes, gaps, etc)
  2. a room touching 2 other rooms
  1. cannot border a boss room

NOTE: a small (thinner) room doesn't count as touching: https://i.imgur.com/XN1qn1d.png

NOTE: can technically touch 4 rooms

@shmup
shmup / K.md
Created Oct 8, 2018
search duckduckgo (or google) via vim's keywordprg
View K.md

Search DuckDuckGo (or Google) via vim's keywordprg

This will search DDG or Google (using Firefox) with the filetype+keyword and go to the first result

This is related to :help keywordprg and pressing K on a keyword

Probably you can swap firefox with chrome in the snippets, idk

Put this in your $HOME/.vim/vimrc and swap the commented out line if you don't use vim-dispatch

@shmup
shmup / amfv_decoder.txt
Created May 15, 2018
simulation decoder
View amfv_decoder.txt
Item #603475 Valid March 15-31, 2031
PRISM PROJECT FACILITY
Class One Security Mode Access Decoder
Wheel # |89|61|50|18|29|52|46|77|27|68|22|95|40|58|15|86|28|33|94|11|64|98|34|49|60|16|85|52|37|53|93|91
Dk. Green |73|36|90|41|19|48|62|92|55|23|84|99|57|20|78|67|51|88|17|31|70|39|96|25|81|83|47|54|13|43|12|66
Blue |90|41|19|48|62|92|55|23|84|99|57|20|78|67|51|88|17|31|70|39|96|25|81|83|47|54|13|43|12|66|73|36
Pink |19|48|62|92|55|23|84|99|57|20|78|67|51|88|17|31|70|39|96|25|81|83|47|54|13|43|12|66|73|36|90|41
Orange |62|92|55|23|84|99|57|20|78|67|51|88|17|31|70|39|96|25|81|83|47|54|13|43|12|66|73|36|90|41|19|48
@shmup
shmup / vimclj.md
Last active May 3, 2018
vim prefs for clojure
View vimclj.md

Vim preferences for Clojure

I want to learn Clojure and I don't want to think about a new editor, or a bunch of new mappings

These are my minimum requirements that make me happy

TL;DR

1) install vim 2) install vim-fireplace and vim-cljfmt 3) add some shit to your ~/.lein/profile.clj