Skip to content

Instantly share code, notes, and snippets.

View effrenus's full-sized avatar
🖖
(๑•́ ₃ •̀๑)

Sazonov Alexey effrenus

🖖
(๑•́ ₃ •̀๑)
View GitHub Profile
### Keybase proof
I hereby claim:
* I am effrenus on github.
* I am effrenus (https://keybase.io/effrenus) on keybase.
* I have a public key ASD_vOyOYMb530AUQL2F4KYf_O8iFtAQwcpcy790IwP6gQo
To claim this, I am signing this object:
@effrenus
effrenus / Makefile
Created November 29, 2017 14:21 — forked from mpneuried/Makefile
Simple Makefile to build, run, tag and publish a docker containier to AWS-ECR
# import config.
# You can change the default config with `make cnf="config_special.env" build`
cnf ?= config.env
include $(cnf)
export $(shell sed 's/=.*//' $(cnf))
# import deploy config
# You can change the default deploy config with `make cnf="deploy_special.env" release`
dpl ?= deploy.env
include $(dpl)
// https://pikabu.ru/page/interview/frontend/
const check = (taskNum, fn, cmp = (a,b) => a === b) =>
(expected, ...vals) =>
console.assert(
cmp(fn(...vals), expected),
`\n[Task #${taskNum}] Test failed: \n\t\texpected [${expected}] \n\t\treturns [${fn(...vals)}] \n\t\tFunction args: (${vals.map(v => typeof v == 'string' ? `'${v}'` : v).join(', ')})`
)
// Task 14.
/**
Владей собой среди толпы смятенной,
Тебя клянущей за смятенье всех,
Верь сам в себя наперекор вселенной,
И маловерным отпусти их грех;
Пусть час не пробил, жди, не уставая,
Пусть лгут лжецы, не снисходи до них;
Умей прощать и не кажись, прощая,
Великодушней и мудрей других.
{
const globalScope = new Map();
const getVar = (name) => {
if (!globalScope.has(name)) {
throw new Error("Unknown variable name");
}
return globalScope.get(name);
};
const filterEmpty = (arr) => arr.filter(v => typeof v === "number" || !v);
<?xml version="1.0" encoding="UTF-8"?>
<gpx creator="GPS to GPX (https://npm.im/gps-to-gpx)" version="1.1" xmlns="http://www.topografix.com/GPX/1/1" xmlns:gpxx="http://www.garmin.com/xmlschemas/GpxExtensions/v3" xmlns:gpxtpx="http://www.garmin.com/xmlschemas/TrackPointExtension/v2" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://www.topografix.com/GPX/1/1 http://www.topografix.com/GPX/1/1/gpx.xsd http://www.garmin.com/xmlschemas/GpxExtensions/v3 http://www.garmin.com/xmlschemas/GpxExtensionsv3.xsd http://www.garmin.com/xmlschemas/TrackPointExtension/v2 http://www.garmin.com/xmlschemas/TrackPointExtensionv2.xsd">
<metadata>
<name>Bar tour</name>
</metadata>
<trk>
<name>Bar tour</name>
<trkseg>
<trkpt lat="55.768249" lon="37.598339"></trkpt>
<trkpt lat="55.768308999999995" lon="37.598448000000005"></trkpt>