Skip to content

Instantly share code, notes, and snippets.

Arve Nygård arvearve

Block or report user

Report or block arvearve

Hide content and notifications from this user.

Learn more about blocking users

Contact Support about this user’s behavior.

Learn more about reporting abuse

Report abuse
View GitHub Profile
View dependencies.dot
digraph dependencies {
Log -> "AWS DB"
"AWS DB" -> "Migrations" -> Docker;
Log -> "Users resource access" -> Auth;
Docker -> "Measures resource access" -> "Measures manager";
"Actuator resource access" -> "Actuator Manager";
Docker -> "Customer resource access" -> "Measures manager";
"Prices resource access" -> "Consumption Engine";
"Customer resource access" -> "Consumption Engine";
View keybase.md

Keybase proof

I hereby claim:

  • I am arvearve on github.
  • I am arvearve (https://keybase.io/arvearve) on keybase.
  • I have a public key ASDsQ4MjkI3-0dVePNADk84-kpsLK7jd-Unz1qDanHy7Swo

To claim this, I am signing this object:

@arvearve
arvearve / Cornell point light
Created Mar 4, 2015
Simple Cornell box. No area light, just a point for now.
View Cornell point light
Composer format 2.1 ascii
camera {
position 0 0 -4
viewDirection 0 0 1
focalDistance 20
orthoUp 0 1 0
verticalFOV 0.7142857143
}
point_light {
position 0 0.7 0
View gist:3481ebc6026a29139df0
ray Ray
_id size_t 1 1
startPosition Pos
x float -9.58771991 -9.58771991
y float 4.26362991 4.26362991
z float 4.60778999 4.60778999
direction Vec3f
x float 0.103407018 0.103407018
y float -0.731793463 -0.731793463
z float -0.673635959 -0.673635959
View unix_tricks
I have marked with a * those which I think are absolutely essential
Items for each section are sorted by oldest to newest. Come back soon for more!
BASH
* In bash, 'ctrl-r' searches your command history as you type
- Input from the commandline as if it were a file by replacing
'command < file.in' with 'command <<< "some input text"'
- '^' is a sed-like operator to replace chars from last command
'ls docs; ^docs^web^' is equal to 'ls web'. The second argument can be empty.
* '!!:n' selects the nth argument of the last command, and '!$' the last arg
View whiteboardCleaner.md

Description

This simple function will take a picture of a whiteboard and use parts of the ImageMagick library with sane defaults to clean it up tremendously.

The script is here:

    function whiteboard(){
        convert $1 -morphology Convolve DoG:15,100,0 -negate -normalize -blur 0x1 -channel RBG -level 60%,91%,0.1  "${@:2}"     ${1%.*}.png
    }
@arvearve
arvearve / gist:9622831
Last active Aug 29, 2015
Pandoc markdown -> pdf macro
View gist:9622831
# Put in ~/.bashrc or similar
# requires pandoc and xelatex
#
# usage:
# $ mdpdf myfile.md
# outputs myfile.pdf in same directory
#
# Additional flags are passed:
# $ mdpdf myfile.md --toc
# outputs myfile.pdf with table of contents.
View gist:7237537
[user]
name =
email =
[github]
user =
token =
[alias]
co = checkout
ci = commit
st = status
@arvearve
arvearve / gist:5187999
Last active Dec 15, 2015
ImportError: No module named tools
View gist:5187999
######
/var/log/uwsgi/nerd.log
######
Content-Type: text/plain; charset="utf-8"
MIME-Version: 1.0
View gist:5187751
Content-Type: text/plain; charset="utf-8"
MIME-Version: 1.0
Content-Transfer-Encoding: 7bit
Subject: [Django] ERROR (EXTERNAL IP): Internal Server Error: /
From: root@localhost
To: djangoerrors@abakus.no
Date: Mon, 18 Mar 2013 14:58:03 -0000
Message-ID: <20130318145803.23500.42555@luke.abakus.no>
Traceback (most recent call last):
You can’t perform that action at this time.