Navigation Menu

Skip to content

Instantly share code, notes, and snippets.

View tpanum's full-sized avatar

Thomas Kobber Panum tpanum

View GitHub Profile
@tpanum
tpanum / packages.el
Last active August 29, 2015 14:08
Emacs 24.4 updates to JEG2's packages.el
(defun jeg2/package-version-for (package)
"Get the version of a loaded package."
(package-desc-version (car (cdr (assoc package package-alist)))))
(defun jeg2/package-requirements (package)
"List of recursive dependencies for a package."
(let ((package-info (car (cdr (assoc package package-alist)))))
(cond ((null package-info) (list package))
(t
(jeg2/flatten
@tpanum
tpanum / jekyll.el
Last active August 29, 2015 14:07
Create Jekyll post from Emacs
(defun tpanum/create-jekyll-post
(title)
"Creates a new buffer and file for a blog post"
(interactive "sTitle of blog post: ")
(let
((filename
(concat
(format-time-string "%Y-%m-%d-")
(replace-regexp-in-string " " "-"
(downcase
package main
import (
"io"
"log"
"os"
"os/exec"
"io/ioutil"
"bytes"
)
$ make
/Applications/Xcode.app/Contents/Developer/usr/bin/make -f objs/Makefile
cc -c -Wno-unused-function -Wno-missing-field-initializers -D_POSIX_C_SOURCE=200112L --std=c99 -Isrc -I src/core -I src/event -I src/event/modules -I src/os/unix -I objs \
-o objs/src/core/nginx.o \
src/core/nginx.c
In file included from src/core/nginx.c:8:
In file included from src/core/ngx_config.h:34:
In file included from src/os/unix/ngx_darwin_config.h:30:
In file included from /usr/include/sys/mount.h:76:
In file included from /usr/include/sys/attr.h:42:
ERROR: generate failed while processing /personal/path/to/project/myproject/rel: {'EXIT',{{badmatch,{error,"Module iconv potentially included by two different applications: eiconv and iconv."}},
[{rebar_reltool,generate,2,[]},
{rebar_core,run_modules,4,[]},
{rebar_core,execute,5,[]},
{rebar_core,process_dir1,6,[]},
{rebar_core,process_each,5,[]},
{rebar_core,process_dir1,6,[]},
{rebar_core,process_commands,2,[]},
{rebar,main,1,[]}]}}
5> Conn:gfsOpen(#gfs_file{filename = <<"Noir sax.mp3">>}).
** exception error: no function clause matching mongoapi:gfsOpen(<<"fd">>,
#gfs_file{recindex = 3,
docid = {oid,<<"0000c1d78e4f8828b7000002">>},
filename = <<"Noir sax.mp3">>,contentType = undefined,
length = 157696,chunkSize = 262144,
uploadDate = {1394,972127,93000},
aliases = undefined,
metadata = [{<<"parentObject">>,
{oid,<<"0000c1d78e4f8828b7000001">>}}]
@tpanum
tpanum / gist:6883550
Created October 8, 2013 11:54
gfortran brew failed 8/10/13
$ brew install gfortran
Warning: Building source; cellar of gfortran's bottle is /usr/local/Cellar
==> Downloading http://ftpmirror.gnu.org/gcc/gcc-4.8.1/gcc-4.8.1.tar.bz2
Already downloaded: /opt/boxen/cache/homebrew/gfortran-4.8.1.tar.bz2
==> ../configure --prefix=/opt/boxen/homebrew/Cellar/gfortran/4.8.1/gfortran --datarootdir=/opt/boxen/homebrew/Cellar/gfortran/4.8.1/share --bindir=/opt/boxen/homebrew/Cellar/gfortran/4.8.1/bin --enabl
==> make bootstrap
Bootstrap comparison failure!
x86_64-apple-darwin12.5.0/libstdc++-v3/src/c++98/math_stubs_float.o differs
make[2]: *** [compare] Error 1
make[1]: *** [stage3-bubble] Error 2
$ brew doctor
Warning: Your Homebrew is not installed to /usr/local
You can install Homebrew anywhere you want, but some brews may only build
correctly if you install in /usr/local. Sorry!
$ brew install gfortran
Warning: Building source; cellar of gfortran's bottle is /usr/local/Cellar
==> Downloading http://ftpmirror.gnu.org/gcc/gcc-4.8.1/gcc-4.8.1.tar.bz2
Already downloaded: /opt/boxen/cache/homebrew/gfortran-4.8.1.tar.bz2
==> ../configure --prefix=/opt/boxen/homebrew/Cellar/gfortran/4.8.1/gfortran --datarootdir=/opt/boxen/homebrew/Cellar/gfortran/4.8.1/share --bindir=/opt/boxen/homebrew/Cellar/gfortran/4.8.1/bin --enabl
# Reconstructed via infocmp from file: TERMCAP
eterm-color,
am, mir, xenl,
colors#8, cols#40, it#8, lines#16, pairs#64,
bel=^G, bold=\E[1m, clear=\E[H\E[J, cr=^M,
csr=\E[%i%p1%d;%p2%dr, cub=\E[%p1%dD, cub1=^H,
cud=\E[%p1%dB, cud1=^J, cuf=\E[%p1%dC, cuf1=\E[C,
cup=\E[%i%p1%d;%p2%dH, cuu=\E[%p1%dA, cuu1=\E[A,
dch=\E[%p1%dP, dch1=\E[P, dl=\E[%p1%dM, dl1=\E[M, ed=\E[J,
el=\E[K, el1=\E[1K, home=\E[H, ht=^I, ich=\E[%p1%d@,
Script started on Sun Aug 18 01:06:40 2013
%
]2;panum@MacBook-Pro: ~/Desktop]1;~/Desktop
☁  Desktop  
%
]2;panum@MacBook-Pro: ~/Desktop]1;~/Desktop
☁  Desktop