This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
ssh-rsa AAAAB3NzaC1yc2EAAAADAQABAAABAQC1HU7tOnkxGkEG417gQUGBpIudcaRHRNIymYwRLaYdjYLmgC5ds0aMO1i71Qh/p/AT9877DaDmXZKHQgesypc9Zjcrlz4mTA4WI8oMu14yXU8uoMJg4IJ7VM4ig5ywADUf452y/HDdxRh1XEpAp8tbCGtFYJIUj6KV7sCRl/yTIwzEr29bSQKOh8qJrY2NcCZmwEyP2p8SqZsGQBmZWdWzeVvtxDZRZWOjcUixLvJAsPAIAWL3Bgjonb/TKj+YyIOfjbEZ+ZXceucgjvTnqEaCxeCx/OgKM+bjPjNYwjjxtBRqmHzrZcE7LeLUFCSC9z8dj6SW5MGNcGN4zlQIZr+N ondrej@eduroam-95.felk.cvut.cz |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
export PS1="\u:\W $ " | |
#GIT bash by HABR (modified by Dundee) | |
export PSORIG="$PS1" | |
function GITBRANCH() { | |
BRANCH="$(git branch 2>/dev/null | grep '*' | cut -d" " -f2-)" | |
if [ -n "$BRANCH" ] ; then | |
export PS1="\u:\W " | |
export PS1=$PS1$(echo -en "\[\033[00;37m\]$BRANCH \[\033[00m\]") |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php | |
function mb_str_split($string,$string_length=1) { | |
if(mb_strlen($string) > $string_length || !$string_length) { | |
do { | |
$c = mb_strlen($string); | |
$parts[] = mb_substr($string,0,$string_length); | |
$string = mb_substr($string,$string_length); | |
}while(!empty($string)); | |
} else { |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php | |
$keys = array( | |
'scheme', | |
'user', | |
'pass', | |
'host', | |
'port', | |
'path', | |
'query', |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php | |
$array = array_filter(array('yx', 'y', 'z')); | |
$exists = count(array_filter($array, function($item) { | |
return substr($item, 0, 1) === 'x'; | |
})) > 0; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
-(BOOL)textField:(UITextField *)textField shouldChangeCharactersInRange:(NSRange)range replacementString:(NSString *)string | |
{ | |
if (textField == self.amountInput) { | |
if (string.length == 0) { | |
return YES; // backspace | |
} | |
NSNumberFormatter* numberFormatter = [[NSNumberFormatter alloc] init]; | |
[numberFormatter setFormatterBehavior: NSNumberFormatterBehavior10_4]; | |
[numberFormatter setNumberStyle: NSNumberFormatterDecimalStyle]; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
/** | |
* @SuppressWarnings(PHPMD.UnusedPrivateField) using GetSet | |
* @Entity | |
*/ | |
class AffiliatePartner extends User | |
{ | |
/** | |
* @var string | |
* @Column |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#import <Foundation/Foundation.h> | |
@interface AnimateSequence : NSObject | |
+ (void)animate:(NSArray*)blocks duration:(NSTimeInterval)duration; | |
@end |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
var WebSocketWrapper = function(url) { | |
this.url = url; | |
this.registeredFunctions = {}; | |
this.ws = null; | |
this.retry = true; | |
}; | |
WebSocketWrapper.prototype.send = function(message) { | |
this.ws.send(JSON.stringify(message)); | |
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php | |
use Guzzle\Http\Url; | |
use Nette\Diagnostics\Debugger; | |
use Nette\Utils\Strings; | |
use React\Http\Request; | |
use React\Http\Response; | |
use React\SocketClient\ConnectionManager; | |
use React\Stream\Stream; |