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
http://invisible-island.net/xterm/ | |
XTerm Control Sequences | |
Edward Moy | |
University of California, Berkeley | |
Revised by |
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
<? | |
function make_salt($salt_size=32) { | |
//list of possible characters from which to cerate the salt | |
$sea = "abcdefghijklmnopqrstuvwxyzABCDEFGHIJKLMNOPQRSTUVWXYZ0123456789"; | |
//how many possible characters are there | |
$sea_size = strlen($sea); | |
$salt = ""; |
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
# Advanced Bash :: Array slicing and compaction in bash | |
# TL;DR | |
X=(something 'whatever' "i have more S P A C E S than i can give away. arent you jealous?") | |
# ${X[@]} the usual whole array | |
# ${X[@]:index:length} slice from index to index+length-1 inclusive | |
# ${X[@]::length} slice from 0 to length-1 inclusive | |
# ${X[@]:index} slice from index to end of array inclusive |