Skip to content

Instantly share code, notes, and snippets.

View Rulexec's full-sized avatar
💭
It's complicated

Alexander Ruliov Rulexec

💭
It's complicated
View GitHub Profile
@Rulexec
Rulexec / kml2json.js
Created July 10, 2013 13:38
node.js kml to json converter
var sax = require('sax');
var saxStream = sax.createStream(true, {
lowercase: true
});
var layout = {};
saxStream.on('error', function() {
console.log('error', arguments);
1. Hello World! Программирование — это просто.
Что такое программирование. План. «Следите за руками»: пишем Pong (демонстрация).
2. Стек технологий.
Немного истории развития, стеки (железо, ОС, приложения, или библиотеки над библиотеками библиотек) и уровни технологий (машинные коды, ассемблеры, низкоуровневые, высокоуровневые ЯП).
3. Если так, то вот так, иначе вот эдак!
allprojects {
repositories {
flatDir {
dirs '/home/ruliov/gradleJarsRepo'
}
};
{ initFile ->
if (initFile.exists()) {
apply from: initFile, to: project
@Rulexec
Rulexec / resume.md
Last active February 27, 2024 04:16

Alexander Ruliov

  • Written my first "Hello, World!" in 2006 (16 years ago).
  • 28 y.o., Belarus, Minsk (born in Brest).

Experience

Gurtam (4 years, [2017; 2021))

Worked as frontend-developer from 15 December 2016 to 4 January 2021 in Gurtam on Wialon product.

Initially project was built on Vanilla JS (with jQuery) plus there was server-generated HTML by TCL (which was used as PHP). After 2-3 years we started to implement new features on React, eliminated TCL pages, and migrated them to OpenResty (Lua). I hope that it will be migrated then to nodejs/will be fully static frontend (at the time of first migration there was no expertise with nodejs in the company, but there was a team that used Lua).

// by Alexander Ruliov
// vk.com/alexander_ruliov
var jq = document.createElement('script');
jq.src = "//ajax.googleapis.com/ajax/libs/jquery/1/jquery.min.js";
document.getElementsByTagName('head')[0].appendChild(jq);
// wait here
jQuery.noConflict();
// by Rulexec
// http://com.muna.by/people/ruliov
var net = require('net'),
CRC32Stream = require('crc32-stream').CRC32Stream;
var client = net.connect(443, '149.154.167.50', function() {
console.log('connected');
var packet = createPacket();
import System.IO
import Control.Monad
whileFM :: (Monad m) => m Bool -> (s -> m s) -> s -> m s
whileFM b f s = b >>= while' where
while' False = return s
while' True = (f s) >>= (\newS -> whileFM b f newS)
andM :: (Monad m) => m Bool -> m Bool -> m Bool
andM a b = a >>= (\x ->
function showLobby(session) {
var lobby = new LobbyClient({session: session});
var lobbyUi = new LobbyUi({element: rootElement});
var processLobbyEventsUntilNotJoinRoom = lobbyUi.poll().bind(function(event) {
if (event.type === LobbyUi.EVENTS.JOIN_ROOM) {
this.cont(null, event.id);
} else {
return processLobbyEventsUntilNotJoinRoom;
}
import sys
numbers = [2, 0, 1, 5, 2, 0, 1, 5]
k = len(numbers) - 1
indexed_tail = list(zip(range(k), numbers[1:]))
to_bin = 2 ** k - 1
variants = []
(defn id (x) x)
(defn inRange (c start end) (and (>= (ord c) (ord start)) (<= (ord c) (ord end))))
(defn tryParse (pattern text)
(let (patternType (head pattern))
(switch patternType
'single' (let
(parser (get 1 pattern)
handler (getOrDef id 2 pattern)