Skip to content

Instantly share code, notes, and snippets.

View kalambet's full-sized avatar
👾
The price of freedom is eternal vigilance

Peter Kalambet kalambet

👾
The price of freedom is eternal vigilance
View GitHub Profile
@kalambet
kalambet / ton-transfer.zsh
Last active October 4, 2019 21:54
Transfer Grams from wallet to account
#!/bin/zsh
# Script to tranfer grams from wallet to address
if [[ -z $3 ]]; then
echo ""
echo " Usage: ton-transfer <your-wallet-id> <destination-addr> <gram-amount>"
echo ""
echo " Note: needs to be called from the folder you store your wallet files"
echo ""
@kalambet
kalambet / double.sort.java
Created September 15, 2017 14:56
Java Stream API double sort
package com.example;
import java.util.ArrayList;
import java.util.Comparator;
class Enrty {
private int one;
public int getOne(){
return this.one;
}
"""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""
" => General
"""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""
" Sets how many lines of history VIM has to remember
set history=500
" Enable filetype plugins
filetype plugin on
filetype indent on
@kalambet
kalambet / keybase.md
Created April 14, 2015 21:18
keybase.md

Keybase proof

I hereby claim:

  • I am kalambet on github.
  • I am kalambet (https://keybase.io/kalambet) on keybase.
  • I have a public key whose fingerprint is 6F0C 224C 31D0 3EA1 C62F 0828 37E8 2ADC EF6E 9477

To claim this, I am signing this object:

@kalambet
kalambet / gist:dac760f7afae0d5c8a6b
Created April 11, 2015 18:49
Logitech and foobar
<device displayname="##" class="KeyboardDevice" model="##" numberofbuttons="##" connectionid="">
<button number="##" name="Play">
<param iconloc="" type="">
<trigger class="ButtonPress">
<param button="##" firstrepeatdelay="0" repeatdelay="0" silent="1" type="0"><!-- Править тут -->
<triggerstate name="ButtonDownUp" handlerset="MM PLAY">
<handler class="MMPlayer">
<param action="PLAY" osdtext="Play/Pause">
</handler>
</triggerstate>
@kalambet
kalambet / gist:9be7f6d879c44d3a2a59
Created April 11, 2015 18:38
Time sync for VirtualPC Part2
<integration>
<microsoft>
<mouse>
<allow type="boolean">true</allow>
</mouse>
<components>
<host_time_sync>
<enabled type="boolean">false</enabled>
</host_time_sync>
</components>
@kalambet
kalambet / gist:ab440c7139394c6e7ed2
Last active August 29, 2015 14:18
Time sync for VirtualPC Part1
<integration>
<microsoft>
<mouse>
<allow type="boolean">true</allow>
</mouse>
...
</microsoft>
</integration>
@kalambet
kalambet / gist:92647c46b64dd2ffaf5f
Created April 11, 2015 18:32
DTO in C# 4 Part6
Assembly assembly = Assembly.LoadFrom(@"./delme.ext.dll");
object instance = assembly.CreateInstance("delme.ext.CDelmeExt");
CSharpCallPayload payload =
new CSharpCallPayload(
RuntimeBinder.GetInstance(),
false,
false,
"WhoAreYou",
typeof(object),
null);
@kalambet
kalambet / gist:8e3c925b020290fa582d
Created April 11, 2015 18:30
DTO in C# 4 Part5
.method private hidebysig static void Main() cil managed
{
.entrypoint
.custom instance void [mscorlib]System.STAThreadAttribute::.ctor() = ( 01 00 00 00 )
// Code size 123 (0x7b)
.maxstack 7
.locals init ([0] class [mscorlib]System.Reflection.Assembly 'assembly',
[1] object 'instance',
[2] object res,
[3] bool CS$4$0000)
@kalambet
kalambet / gist:03d7d1170dfed51f5dac
Created April 11, 2015 18:29
DTO in C# 4 Part4
.entrypoint
.custom instance void [mscorlib]System.STAThreadAttribute::.ctor() = ( 01 00 00 00 )
// Code size 95 (0x5f)
.maxstack 8
.locals init ([0] class [mscorlib]System.Reflection.Assembly 'assembly',
[1] object 'instance',
[2] class [mscorlib]System.Type delmeext,
[3] object res,
[4] object[] CS$0$0000)
IL_0000: ldstr "./delme.ext.dll"