I hereby claim:
- I am stepankuzmin on github.
- I am stepankuzmin (https://keybase.io/stepankuzmin) on keybase.
- I have a public key ASCTIo2LNjSpYsNdpAt8RuqIfr8_ORUCtsPkkXO28Cp3ZQo
To claim this, I am signing this object:
| version: '2' | |
| services: | |
| galton_dnsmasq: | |
| image: andyshinn/dnsmasq:2.76 | |
| restart: always | |
| container_name: galton_dnsmasq | |
| cap_add: | |
| - NET_ADMIN | |
| galton_nginx: | |
| image: nginx |
| import psycopg2 | |
| conn = psycopg2.connect("dbname=db host=/var/run/postgresql/ user=user") | |
| cur = conn.cursor() | |
| cur.execute("select * from datasets.intervals;") | |
| cur.fetchone() | |
| cur.close() | |
| conn.close() |
| const R = require('ramda'); | |
| const mapIndexed = R.addIndex(R.map); | |
| // notEmpty : a -> Bool | |
| const notEmpty = R.converge(R.compose(R.not, R.or), [isNaN, R.isEmpty]); | |
| // buildDict : String -> [{ k: v }] -> { k: v } | |
| const buildDict = R.uncurryN(2, key => R.pipe( | |
| R.map(R.compose(R.toLower, R.prop(key))), |
I hereby claim:
To claim this, I am signing this object:
| with | |
| avg_by_hour as ( | |
| select | |
| id, | |
| date_trunc('hour', time) + (round(extract('minute' from time) / 15) * 15) * interval '1 minute' as interval, | |
| trunc(avg(free)) as free | |
| from velobike_2016_09_05 | |
| group by id, interval | |
| order by id, interval | |
| ) |
| version: '2' | |
| services: | |
| fluentd: | |
| container_name: fluentd | |
| image: fluent/fluentd | |
| environment: | |
| FLUENTD_CONF: fluent.conf | |
| ports: | |
| - 24224:24224 |
| import { call, put, takeLatest } from 'redux-saga/effects'; | |
| import { AUTH_REQUEST, AUTH_SUCCESS, AUTH_FAILURE } from './reducer'; | |
| const fetchJSON = (url, options = {}) => | |
| new Promise((resolve, reject) => { | |
| return fetch(url, options) | |
| .then(response => (response.status !== 200 ? reject(response) : response)) | |
| .then(response => response.json()) | |
| .then(response => resolve(response)) |
| import React from 'react'; | |
| import { Route, Switch } from 'react-router-dom'; | |
| import { ConnectedRouter } from 'react-router-redux'; | |
| import Main from './Main'; | |
| import Login from './Login'; | |
| const App = props => { | |
| const { history } = props; |
| import React from 'react'; | |
| import ReactDOM from 'react-dom'; | |
| import createHistory from 'history/createBrowserHistory'; | |
| import createSagaMiddleware from 'redux-saga'; | |
| import { Provider } from 'react-redux'; | |
| import { routerMiddleware } from 'react-router-redux'; | |
| import { applyMiddleware, createStore } from 'redux'; | |
| import App from './App'; | |
| import Saga from './saga'; |