Skip to content

Instantly share code, notes, and snippets.

View kernelp4nic's full-sized avatar

Sebastián Moreno kernelp4nic

  • Prisma Campaigns
  • Montevideo-Uruguay
View GitHub Profile
var crypto = require("crypto")
var User = function(attributes) {
this._attributes = attributes || {}
}
User.KEY_LENGTH = 32
User.WORK_FACTOR = 20000
User.prototype.setPassword = function(password, callback) {
@elcuervo
elcuervo / DashCat.md
Last active October 13, 2015 23:18
Suggestions and bug reports of DashCat

What is DashCat?

It's a twitter-like GitHub browser. I've made it the last weekend for me but seems to be something cool for some people.

DashCat

What is this Gist

It's a place where I can discuss stuff of the app

#!/usr/bin/env bash
# For opening a file from the heads up display of Figwheel in IntelliJ IDEA
# Made for OS X but should work similarly on Linux with a different CMD variable
# Add this script to your path (ex. ~/bin) and use from
# :open-file-command in the :figwheel section of project.clj
INTELLIJ_VERSION=14 # Change for your (whole number) version of IntelliJ IDEA
CMD="/Applications/IntelliJ IDEA ${INTELLIJ_VERSION}.app/Contents/MacOS/idea"
"$CMD" "$PWD" --line $2 "$PWD/$1"
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE plist PUBLIC "-//Apple Computer//DTD PLIST 1.0//EN" "http://www.apple.com/DTDs/PropertyList-1.0.dtd">
<plist version="1.0">
<dict>
<key>name</key>
<string>TestConsoleTheme</string>
<key>settings</key>
<array>
<dict>
<key>settings</key>
@karmi
karmi / _readme.markdown
Created April 19, 2011 16:05
Simplistic Full-Text Search With Redis' Sorted Sets

Simplistic Full-Text Search With Redis's Sorted Sets

Howto

git clone git://gist.github.com/923934.git redisearch

cd redisearch
@swannodette
swannodette / core.cljs
Created September 20, 2013 16:23
The fact this won't type check is unbelievably cool
(ns typed-play.core
(:require-macros [cljs.core.typed :as t])
(:require [cljs.core.typed :as t]))
(t/ann my-identity (All [x] (Fn [x -> x])))
(defn my-identity [x]
(if (number? x)
(inc x)
x))
@lukebrooker
lukebrooker / gmail.css
Last active February 13, 2017 18:49
Custom gmail css when using preview pane
/* Hide to menu bar until hover */
.nH.w-asV.aiw {
-webkit-transform: translateY(-80%);
transition: all .2s cubic-bezier(0.18, 0.89, 0.32, 1.28);
transition-delay: .2s;
z-index: 1000;
background-color: #eee;
}
@nvbn
nvbn / core.cljs
Created May 28, 2015 01:31
svg animation
(ns ^:figwheel-always svg-image-example.core
(:require-macros [cljs.core.async.macros :refer [go-loop]])
(:require [cljs.core.async :refer [<! timeout]]
[om.core :as om :include-macros true]
[om-tools.core :refer-macros [defcomponent]]
[om-tools.dom :as dom]))
(enable-console-print!)
(defcomponent rotated-rect-rect
@leighmcculloch
leighmcculloch / NSString_stripHtml.h
Last active February 21, 2018 22:45
NSString + Strip HTML
// NSString_stripHtml.h
// Copyright 2011 Leigh McCulloch. Released under the MIT license.
#import <Foundation/Foundation.h>
@interface NSString (stripHtml)
- (NSString*)stripHtml;
@end
@leafo
leafo / gist:6788652
Last active May 1, 2019 13:28
Making nonblocking http requests with lua-ev and LuaSocket
bit = require "bit"
ev = require "ev"
ltn12 = require "ltn12"
socket = require "socket"
-- make protect and newtry coroutine friendly
socket.protect = (fn) -> fn
socket.newtry = (finalizer) ->
(...) ->