Under Terminal > Preferences... > (Profile) > Advanced, "Declare terminal as:" should be set to xterm-256color
.
This is easy with homebrew:
brew install screen
#!/bin/sh | |
#sudo apt-get install -y curl | |
#curl -L tinyurl.com/dxgshortcuts | sh | |
sudo apt-get install -y git | |
curl https://gist.githubusercontent.com/daxxog/615fae60e1974828e865/raw/rmr-dg-clone-install.sh | sh | |
curl https://gist.githubusercontent.com/daxxog/202792236c0a21339ab4/raw/install-git-shortcuts.sh | sh | |
curl https://gist.githubusercontent.com/daxxog/cfb990f5cbe6805c0cf7/raw/uid-gid-install.sh | sh | |
curl https://gist.githubusercontent.com/daxxog/8d9895d01f4f1ffea1a1/raw/pushbranch-install.sh | sh |
/ipv6 firewall filter | |
add action=accept chain=input comment="Allow established connections" connection-state=established disabled=no | |
add action=accept chain=input comment="Allow related connections" connection-state=related disabled=no | |
add action=accept chain=input comment="Allow limited ICMP" disabled=no limit=50/5s,5 protocol=icmpv6 | |
add action=accept chain=input comment="Allow UDP" disabled=no protocol=udp | |
add action=drop chain=input comment="" disabled=no | |
add action=accept chain=forward comment="Allow any to internet" disabled=no out-interface=sit1 | |
add action=accept chain=forward comment="Allow established connections" connection-state=established disabled=no | |
add action=accept chain=forward comment="Allow related connections" connection-state=related disabled=no | |
add action=drop chain=forward comment="" disabled=no |
Under Terminal > Preferences... > (Profile) > Advanced, "Declare terminal as:" should be set to xterm-256color
.
This is easy with homebrew:
brew install screen
var mongoObjectId = function () { | |
var timestamp = (new Date().getTime() / 1000 | 0).toString(16); | |
return timestamp + 'xxxxxxxxxxxxxxxx'.replace(/[x]/g, function() { | |
return (Math.random() * 16 | 0).toString(16); | |
}).toLowerCase(); | |
}; |
<?php | |
/** | |
* This is an example of a practical encoder and decoder for base-62 data in PHP | |
* It differs from the majority of examples in that it's fast enough for moderate data sizes, unlike multiprecision converters | |
* To be practical, base-62 encoding needs to use internal chunking and padding because base-62 does not fit exactly into any integral number of bits | |
* This means the output is not quite compatible with multiprecision conversions, | |
* but the encoded data retains all the desirable properties of base-62, so (unlike any base-64 encoding) it's URL, DNS, email address and pathname safe | |
* @author Marcus Bointon <[email protected]> | |
* @copyright 2011 Marcus Bointon | |
* @license http://www.opensource.org/licenses/mit-license.html MIT License |