Skip to content

Instantly share code, notes, and snippets.

Avatar

Андрей Листочкин (Andrey Listochkin) listochkin

View GitHub Profile
@listochkin
listochkin / README.md
Created Jul 9, 2018 — forked from andyshinn/README.md
pbcopy over SSH
View README.md

Install

  • Add pbcopy.plist to your ~/Library/LaunchAgents/ folder.
  • Launch the listener with launchctl load ~/Library/LaunchAgents/pbcopy.plist.
  • Add RemoteForward 2224 127.0.0.1:2224 in your ~/.ssh/config file under your Host * or specific hosts sections.
  • Add [ -n "$SSH_CLIENT" ] && alias pbcopy="nc localhost 2224" to your remote ~/.bash_profile or other shell profile.
  • Enjoy pbcopy remotely!
@listochkin
listochkin / 2018.js
Last active Nov 23, 2020 — forked from Jack-Works/2018.js
cRAzY eSnEXt (*all* proposals mixed in)
View 2018.js
#! Aaaaaaaaaaa this is JS!!!
// https://github.com/tc39/proposal-hashbang
// This file is mixing all new syntaxes in the proposal in one file without considering syntax conflict or correct runtime semantics
// Enjoy!!!
// Created at Nov 23, 2018
for await(const x of (new A // https://github.com/tc39/proposal-pipeline-operator
|> do { // https://github.com/tc39/proposal-do-expressions
case(?) { // https://github.com/tc39/proposal-pattern-matching
when {val}: class {
@listochkin
listochkin / barinfuck.lol
Last active Sep 16, 2020 — forked from DrAzraelTod/gist:1710332
Brainfuck interpreter in Lolcode
View barinfuck.lol
HAI
BTW This is a BrainFuck interpreter written in LOLCode
BTW It accepts as input a BF program, followed by a "!", followed by any input to the BF program.
BTW Since BrainFuck is turing-complete, this proves that LOLCode is too
I HAS A INSTRUCTIONS BTW Array for BF instructions
I HAS A IPTR BTW Pointer to first empty element in INSTRUCTIONS
IPTR R 0
I HAS A LOOPZ BTW Array of loop start/end addresses
I HAS A LOOPSTACKZ BTW Loop stack for building the above two
@listochkin
listochkin / README.md
Last active May 31, 2016 — forked from thequux/README.md
Multirust-compatible racer wrapper with OS X support
View README.md

This wrapper automatically sets the RUST_SRC_DIRECTORY environment variable for whatever rust compiler is currently active, automatically creating a new checkout whenever necessary. This should be compatible with all of the multirust-alike tools, but it has only been tested with rustup.rs

Installation

Simply place this somewhere on your path before the main racer binary and set the execute bit.

Uninstallation

View domain.js
var domain = require('domain');
var mysql = require('mysql');
var pool = mysql.createPool({
host: '127.0.0.1',
port: 3306,
database: 'test',
user: 'localuser',
password: 'localpass',
});
View gist:c617dd54cb90137f97aa

Установка Node и NPM

Для воркшопа nodeschool необходимо установить платформу node.js и пакетный менеджер npm.

для Windows, MacOS самый простой способ установки через официальный сайт в автоматическом режиме, нажав на кнопку Install.

для Linux/Unix систем самый надежный способ через командную строку, использую подходы: