Skip to content

Instantly share code, notes, and snippets.

View IrakliJani's full-sized avatar
🇬🇪

Irakli Janiashvili IrakliJani

🇬🇪
View GitHub Profile
@IrakliJani
IrakliJani / do.md
Last active August 29, 2015 14:11
DigitalOcean with Docker

Fresh Ubuntu with Docker on my DigitalOcean

General stuff

package updates

sudo apt-get update
sudo apt-get upgrade
@IrakliJani
IrakliJani / jshint_stats.txt
Created December 2, 2014 21:40
JSHint Stats
before:
There are 2 functions in this file.
Function with the largest signature take 2 arguments, while the median is 1.5.
Largest function has 11 statements in it, while the median is 8.
The most complex function has a cyclomatic complexity value of 5 while the median is 4.
after:
There are 18 functions in this file.
@IrakliJani
IrakliJani / stats_after
Created December 2, 2014 21:26
Stats After
◆ node file_stats.js after.js ~/Desktop
Total lines count => 82
Total token count => 465
Tokens by fruequency:
( => 49
) => 49
; => 30
, => 28
@IrakliJani
IrakliJani / stats_before
Last active August 29, 2015 14:10
Stats Before
◆ node file_stats.js before.js ~/Desktop
Total lines count => 39
Total token count => 212
Tokens by fruequency:
. => 15
= => 15
; => 14
cn => 12
@IrakliJani
IrakliJani / path.md
Last active August 29, 2015 14:06
True Path

True learning path one should follow

Deep Dive in Programming, Algorithms and Math

fractal

"Any fool can know. The point is to understand" - Albert Einstein

1: Babysteps with C

@IrakliJani
IrakliJani / langs.md
Last active August 29, 2015 14:05
Languages I want to learn - With resources
function defaultArguments(func, defaults) {
return function () {
var params = Array.prototype.slice.call(arguments);
var args = func
.toString()
.match(/\((.*)\)/)[1]
.split(/\s*,\s*/)
.filter(Boolean)
.map(function (e, i) { return params[i] || defaults[e]; });
'use strict';
var crypto = require('crypto');
exports.generate_signature = function (params, api_secret) {
var sorted = [];
var pre_sig;
Object.keys(params).sort().forEach(function (key) {
sorted.push([key, params[key]].join('='));
function sum (a) {
return function (b) {
return a + b;
};
}
console.log(sum(1)(2));
fs
.readdirSync(__dirname)
.filter(function (file) { return /\.json$/.test(file); })
.reduce(function (config, file) { return extend(config, require(__dirname + '/' + file)); }, {});