Skip to content

Instantly share code, notes, and snippets.

Avatar

SamwiseFilmore MggMuggins

View GitHub Profile
@MggMuggins
MggMuggins / md2pdf.fish
Created Mar 2, 2018
A little fish function that converts a github md doc to a pdf. Depends grip (https://github.com/joeyespo/grip) and wkhtmltopdf
View md2pdf.fish
# Usage is something like `render_md_to_pdf hi.md`
function md-to-pdf
set name (basename -s .md "$argv[1]")
grip "$argv[1]" --export "$name.html5"
sed -i 's/border:\([0-9]*\)px solid #ddd/border:\1px solid #FF0000/g' "$name.html5"
sed -i 's/#FF0000}\.markdown-body/#ddd}\.markdown-body/g' "$name.html5"
sed -i 's/FF0000/FFF/g' "$name.html5"
sed -i -e '/margin-top: 64px;/d' "$name.html5"
awk " \
BEGIN { count_o = 0; count_c = 0; } \
View .tmux.conf
# Prefix Binding to Ctrl-a
unbind C-b
set -g prefix C-a
# Bindings for Window Splitting
unbind '"'
unbind %
unbind c
unbind &
bind | split-window -h
View Dockerfile
FROM andrewbenton/alpine-ldc
RUN adduser coder -h /home/coder -D
ADD --chown=coder:coder code /home/coder/code.d
WORKDIR /home/coder
RUN sed -i '1s/^/void main() {\n/' code.d
RUN sed -i '$s/$/\n}/' code.d
View errors - linux
warning: package replacement is not used: https://github.com/rust-lang/crates.io-index#net2:0.2.32
warning: package replacement is not used: https://github.com/rust-lang/crates.io-index#thrussh-keys:0.9.5
Checking thrussh-agent v0.1.0 (file:///home/wesley/Workspace/Rust/Redox/redox/cookbook/recipes/thrussh/source/thrussh-agent)
error[E0061]: this function takes 1 parameter but 2 parameters were supplied
--> thrussh-agent/src/thrussh-add.rs:43:22
|
43 | let stream = tokio_uds::UnixStream::connect(&agent_path, &h).unwrap();
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ expected 1 parameter
error[E0061]: this function takes 1 parameter but 2 parameters were supplied
@MggMuggins
MggMuggins / log
Last active Feb 11, 2019
Josharias' Survival when creating a world.
View log
Exception in thread "Thread-8" java.lang.NoClassDefFoundError: org/terasology/core/world/generator/facetProviders/SurfaceObjectProvider
at java.lang.ClassLoader.defineClass1(Native Method)
at java.lang.ClassLoader.defineClass(ClassLoader.java:763)
at java.lang.ClassLoader.defineClass(ClassLoader.java:642)
at org.terasology.module.sandbox.ModuleClassLoader.access$200(ModuleClassLoader.java:49)
at org.terasology.module.sandbox.ModuleClassLoader$1.run(ModuleClassLoader.java:151)
at org.terasology.module.sandbox.ModuleClassLoader$1.run(ModuleClassLoader.java:142)
at java.security.AccessController.doPrivileged(Native Method)
at org.terasology.module.sandbox.ModuleClassLoader.findClass(ModuleClassLoader.java:142)
at java.lang.ClassLoader.loadClass(ClassLoader.java:424)