Skip to content

Instantly share code, notes, and snippets.

View shizzard's full-sized avatar

Denis Fakhrtdinov shizzard

View GitHub Profile
-module(huify).
-export([huify/1]).
-define(cl_vowels(),
[$а, $е, $ё, $и, $о, $у, $ы, $э, $ю, $я]).
-define(cl_consonants(),
[$б, $в, $г, $д, $ж, $з, $к, $л, $м, $н, $п, $р, $с, $т, $ф, $х, $ц, $ч,
$ш, $щ]).
-define(cl_etc(),
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
%%% RELOADERS %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
lm() ->
[c:l(M) || M <- mm()].
mm() ->
modified_modules().
modified_modules() ->
new_spec__() ->
?es:attribute(?es:atom(spec), [
?es:tuple([
?es:tuple([
?es:atom(?cloak_generated_function_new),
?es:integer(?cloak_generated_function_new_arity)
]),
?es:list([
?es:tuple([?es:atom(type), ?es:integer(0), ?es:atom('fun'), ?es:list([
?es:tuple([?es:atom(type), ?es:integer(0), ?es:atom(product), ?es:list([
{tree,attribute,
{attr,8,[],none},
{attribute,
{tree,atom,{attr,8,[],none},spec},
[{tree,tuple,
{attr,8,[],none},
[{tree,tuple,
{attr,0,[],none},
[{tree,atom,{attr,0,[],none},some_function},
{tree,integer,{attr,0,[],none},1}]},
-module(priv_basic).
-compile({parse_transform, cloak_transform}).
-record(?MODULE, {
a,
b = atom,
prot_c = 0,
priv_d = 0
}).
@shizzard
shizzard / remsh.erl
Created November 20, 2015 14:24 — forked from davisp/remsh.erl
A remsh that logs every session to ~/.remsh.log
#! /usr/bin/env escript
%%! -hidden -noshell -noinput
-mode(compile).
-export([
init_shell_log/1
]).
resolve_family({_,_,_,_}, auto) ->
inet;
resolve_family({_,_,_,_,_,_,_,_}, auto) ->
inet6;
resolve_family(IP, auto) ->
throw({error, {strange_family, IP}});
resolve_family(_, F) ->
2014-08-21 09:48:32 <0.19122.49> [c] <?xml version='1.0' ?><stream:stream to='wotqa706.loc' xmlns='jabber:client' xmlns:stream='http://etherx.jabber.org/streams' xml:lang='en' version='1.0'>
2014-08-21 09:48:32 <0.19122.49> [s] <?xml version='1.0'?><stream:stream xmlns='jabber:client' xmlns:stream='http://etherx.jabber.org/streams' from='wotqa706.loc' version='1.0' >
2014-08-21 09:48:32 <0.19122.49> [s] <stream:features><mechanisms xmlns='urn:ietf:params:xml:ns:xmpp-sasl'><mechanism><![CDATA[PLAIN]]></mechanism></mechanisms></stream:features>
2014-08-21 09:48:33 <0.19122.49> [c] <auth xmlns='urn:ietf:params:xml:ns:xmpp-sasl' mechanism='PLAIN'>APIwMTEAMTc0NDUxMw==</auth>
2014-08-21 09:48:34 <0.19122.49> [s] <success xmlns='urn:ietf:params:xml:ns:xmpp-sasl'/>
2014-08-21 09:48:34 <0.19122.49> [c] <?xml version='1.0' ?><stream:stream to='wotqa706.loc' xmlns='jabber:client' xmlns:stream='http://etherx.jabber.org/streams' xml:lang='en' version='1.0'>
2014-08-21 09:48:34 <0.19122.49> [s] <?xml version='1.0'
2014-08-21 13:07:35 <0.227.1> [c] <?xml version='1.0' ?><stream:stream to='admin.localhost' xmlns='jabber:client' xmlns:stream='http://etherx.jabber.org/streams' version='1.0'>
2014-08-21 13:07:35 <0.227.1> [s] <?xml version='1.0'?><stream:stream xmlns='jabber:client' xmlns:stream='http://etherx.jabber.org/streams' from='admin.localhost' version='1.0' >
2014-08-21 13:07:35 <0.227.1> [s] <stream:features><mechanisms xmlns='urn:ietf:params:xml:ns:xmpp-sasl'><mechanism><![CDATA[PLAIN]]></mechanism></mechanisms></stream:features>
2014-08-21 13:07:35 <0.227.1> [c] <auth xmlns='urn:ietf:params:xml:ns:xmpp-sasl' mechanism='PLAIN' xmlns:ga='http://www.google.com/talk/protocol/auth' ga:client-uses-full-bind-result='true'>AGFkbWluLTEAZDUwODVmMmM5ZA==</auth>
2014-08-21 13:07:35 <0.227.1> [s] <success xmlns='urn:ietf:params:xml:ns:xmpp-sasl'/>
2014-08-21 13:07:35 <0.227.1> [c] <stream:stream to='admin.localhost' xmlns='jabber:client' xmlns:stream='http://etherx.jabber.org/streams' version='1.0'>
2014-08-21 13:07:35
INFO global: Vagrant version: 1.6.2
INFO global: Ruby version: 2.0.0
INFO global: RubyGems version: 2.0.14
INFO global: VAGRANT_DEFAULT_PROVIDER="parallels"
INFO global: VAGRANT_EXECUTABLE="/Applications/Vagrant/bin/../embedded/gems/gems/vagrant-1.6.2/bin/vagrant"
INFO global: VAGRANT_LOG="debug"
INFO global: VAGRANT_INSTALLER_EMBEDDED_DIR="/Applications/Vagrant/bin/../embedded"
INFO global: VAGRANT_INSTALLER_VERSION="2"
INFO global: VAGRANT_DETECTED_OS="Darwin"
INFO global: VAGRANT_INSTALLER_ENV="1"