Skip to content

Instantly share code, notes, and snippets.

View AlexeyKhristov's full-sized avatar

Alexey Khristov AlexeyKhristov

View GitHub Profile
@AlexeyKhristov
AlexeyKhristov / 2018-09-10_0-user-tx-add-new-type.js
Last active September 10, 2018 13:53
user tx add new type
const TABLE_NAME = 'user_transactions';
const OLD_TYPES = {
SUBMIT_ORDER: 'SUBMIT_ORDER',
EXCHANGE: 'EXCHANGE',
EXCHANGE_FEE: 'EXCHANGE_FEE',
NON_ERC20_WRAPPING: 'NON_ERC20_WRAPPING',
BTC_DEPOSIT: 'BTC_DEPOSIT',
BTC_ISSUE: 'BTC_ISSUE',
EXCHANGE_REQUEST: 'EXCHANGE_REQUEST',
@AlexeyKhristov
AlexeyKhristov / 1. mailer daemon
Created November 25, 2015 12:48
simple API example && mailer daemon
'use strict';
var pmx = require('./common/pmx')('mailer');
const config = require('config');
var co = require('co');
var fs = require('fs');
var nodemailer = require('nodemailer');
var signer = require('nodemailer-dkim').signer;
var debug = require('debug')('mailer');
@AlexeyKhristov
AlexeyKhristov / gist:7880351db64add86a48e
Created November 16, 2015 13:43
tmux config (~/.tmux.conf)
set-option -g status-utf8 on
set-option -g utf8 on
# http://habrahabr.ru/post/127133/
setw -g xterm-keys on
# http://net.tutsplus.com/tutorials/tools-and-tips/intro-to-tmux/?search_index=1
#set -g prefix C-a
#unbind C-b
#bind C-a send-prefix
{
"errors": {
"email": [
{
"message": "Email address must be valid email",
"type": "Validation error"
}
],
"username": [
{
@AlexeyKhristov
AlexeyKhristov / domains.cql
Last active August 29, 2015 14:01
cassandra
CREATE TABLE domains (
domain text PRIMARY KEY,
created_at timestamp,
tags set<text>,
seo_counters map<text, float>,
techs map<text, text>
) WITH comment='domains';