Skip to content

Instantly share code, notes, and snippets.

View ikarius's full-sized avatar
🏠
Working from home

ikarius ikarius

🏠
Working from home
View GitHub Profile
@0xjac
0xjac / private_fork.md
Last active June 28, 2024 19:27
Create a private fork of a public repository

The repository for the assignment is public and Github does not allow the creation of private forks for public repositories.

The correct way of creating a private frok by duplicating the repo is documented here.

For this assignment the commands are:

  1. Create a bare clone of the repository. (This is temporary and will be removed so just do it wherever.)

git clone --bare git@github.com:usi-systems/easytrace.git

@kachayev
kachayev / css-parser.md
Last active November 12, 2022 04:20
Parsing CSS file with monadic parser in Clojure

Virtual DOM and diffing algorithm

There was a [great article][1] about how react implements it's virtual DOM. There are some really interesting ideas in there but they are deeply buried in the implementation of the React framework.

However, it's possible to implement just the virtual DOM and diff algorithm on it's own as a set of independent modules.

@adambard
adambard / errors.clj
Created May 13, 2013 05:48
An example of functional error handling in clojure.
(ns example.errors)
(defn clean-address [params]
"Ensure (params :address) is present"
(if (empty? (params :address))
[nil "Please enter your address"]
[params nil]))
(defn clean-email [params]
"Ensure (params :email) matches *@*.*"
@0xced
0xced / README.md
Last active November 1, 2018 14:56
How to class-dump an iOS static framework

Using HockeySDK as an example

  1. Download HockeySDK 3.0.0
  2. Run these commands:
ARCH=armv7
FRAMEWORK_DIRECTORY="${HOME}/Downloads/HockeySDK-iOS-3/HockeySDK.embeddedframework"
FRAMEWORK_NAME=$(basename `echo "${FRAMEWORK_DIRECTORY}"/*.framework` .framework)
@ericmoritz
ericmoritz / bbeat.clj
Created March 2, 2012 16:09 — forked from damionjunk/gist:1500336
Binaural Beats with Overtone and Clojure
(ns overtone-clj-toys.binaural
(:use [overtone.live]))
;;
;; Binaural Beat Synthesis:
;; Generates binaural beats given the provided carrier and desired
;; frequency. Brown noise is used to soften the background and
;; block out outside noise.
;; freq effect
@superchink
superchink / show
Created April 20, 2011 22:42 — forked from tekacs/show
This does something essentially equivalent to showoff.io if you have a publicly facing server...
# Usage: show <local-port> <subdomain>
function show() {
DOMAIN=".webhostology.com"
REMOTE="$2$DOMAIN"
ssh -tR 8080:127.0.0.1:$1 vps "sudo ssh -Nl \$USER -L $REMOTE:80:127.0.0.1:8080 localhost"
}
@ikarius
ikarius / Orientation.m
Created March 24, 2011 09:10
Simple (but effecive) workaround for dynamic AND selective orientation change in a UI(View|TabBar|Navigation)Controller
/* Selective / dynamic UI orientation
Simply add this method (updateOrientation) to your class and call it in:
-(void) viewWillAppear:(BOOL)animated
{
[super viewWillAppear:animated];
[self updateOrientation];
}