Skip to content

Instantly share code, notes, and snippets.

Patrick Lehner nevik

Block or report user

Report or block nevik

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 gist:85b824652f2a3db83380
/tmp$ git init test
Initialized empty Git repository in /private/tmp/test/.git/
/tmp$ cd test
/tmp/test (master #)$ touch a b
/tmp/test (master #)$ ls
a b
/tmp/test (master #)$ git status -z | hexdump -C
00000000 3f 3f 20 61 00 3f 3f 20 62 00 |?? a.?? b.|
0000000a
/tmp/test (master #)$ git --version
View holler.md
git fetch --all
git checkout sprint015
git pull origin sprint015
git checkout -b my-new-feature
git add .
git commit -m "all my feature"
git checkout sprint015
git pull origin sprint015
git checkout my-new-feature
git rebase -i sprint015
View MonoidTest.scala
import scalaz._
object Main {
implicit def setMonoid[A] = new Monoid[Set[A]] {
def append(f1: Set[A], f2: => Set[A]) = f1 union f2
def zero = Set[A]()
}
def main(args: Array[String]) {
@nevik
nevik / inw-output-test-linux.txt
Last active Oct 6, 2016
Test and comparison of inotifywait vs. inotify-win output and exclusion pattern application
View inw-output-test-linux.txt
############################################################
## TEST GROUP 1: simple events, watching absolute path
############################################################
{$ inotifywait -qmr /tmp/inwtest/}
[/tmp/inwtest]$ touch testfile
/tmp/inwtest/ CREATE testfile
/tmp/inwtest/ OPEN testfile
@nevik
nevik / dual-output-jack-ubuntu13.10.markdown
Last active Feb 26, 2018
Simultaneous output to Analog and HDMI with Jack on Ubuntu 13.10
View dual-output-jack-ubuntu13.10.markdown

How to get simultaneous / dual output to both Analog out and HDMI out with Jack Audio on Ubuntu 13.10

Configuration used:

  • OS: Xubuntu (Ubuntu) 13.10 (saucy)
  • Audio: HDA Intel PCH (ALC269VB Analog) on an Intel Core i5 2557M (Sandy Bridge microarch)

Install below packages and set user group, then reboot

Packages you will need (and the versions I had when I did this):

  • jackd2, 1.9.9.5+20130622git7de15e7a-1
@nevik
nevik / git-add--interactive--words.pl
Created Feb 2, 2014
Fixed git-add-interactive script to use color-words-diff with interactive checkout
View git-add--interactive--words.pl
#!/usr/bin/perl
use lib (split(/:/, $ENV{GITPERLLIB} || "/usr/share/perl/5.14.2"));
use 5.008;
use strict;
use warnings;
use Git;
binmode(STDOUT, ":raw");
View Point.hpp
/* Software License Agreement (BSD License)
*
* Copyright (c) 2011, Willow Garage, Inc.
* All rights reserved.
*
* Redistribution and use in source and binary forms, with or without
* modification, are permitted provided that the following conditions
* are met:
*
* * Redistributions of source code must retain the above copyright
@nevik
nevik / payload.json
Created Jul 6, 2013
example webhook payload
View payload.json
{
"after":"98248f0e892ce4e4e37411730ac98b53f2aa1261",
"base_ref":"refs/heads/br2",
"before":"0000000000000000000000000000000000000000",
"commits":[
],
"compare":"https://github.com/nevik/testrepo/compare/tag2",
"created":true,
"deleted":false,
View readme.md
  1. Paradoxes
  • Page 17
  • Page 24
@nevik
nevik / gh-compare.md
Last active Aug 6, 2019
GitHub Compare view
View gh-compare.md

GitHub's compare view is available at:

https://github.com/$USER/$REPO/compare/$REV_A...$REV_B

Naturally, $USER and $REPO are the owner (user/organization) and repository names, respectively.

$REV{A,B} are the two sides of the compare view; they can either be a ref in $USER's repository, i.e. the name of a branch, tag or a commit SHA, or it can be a ref in $OWNER's fork of the repository by using the format $OWNER:$REF.

You can get a diff or patch for the result of the compare view by appending .diff or .patch to the URL, respectively.

You can’t perform that action at this time.