wget http://tiles.kerbalmaps.com/mun/sat/2/0/3.png -O 0000.png \
&& wget http://tiles.kerbalmaps.com/mun/sat/2/1/3.png -O 0001.png \
&& wget http://tiles.kerbalmaps.com/mun/sat/2/2/3.png -O 0002.png \
&& wget http://tiles.kerbalmaps.com/mun/sat/2/3/3.png -O 0003.png \
&& wget http://tiles.kerbalmaps.com/mun/sat/2/4/3.png -O 0004.png \
&& wget http://tiles.kerbalmaps.com/mun/sat/2/5/3.png -O 0005.png \
&& wget http://tiles.kerbalmaps.com/mun/sat/2/6/3.png -O 0006.png \
&& wget http://tiles.kerbalmaps.com/mun/sat/2/7/3.png -O 0007.png \
&& wget http://tiles.kerbalmaps.com/mun/sat/2/0/2.png -O 0100.png \
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
🌮Tacos | |
☑️Ricotta salata | |
☑️Cotija | |
☑️Monterey Jack | |
☑️Swiss | |
☑️Sour cream | |
☑️Tomato | |
☑️Red onion | |
☑️Green chilli |
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
f=T_coolingfan.gcode && cat $f | sed 's/M109 S/M104 S/g' | sed 's/M190 /M109 /g' | /Users/tsnoad/Things/GPX/gpx -s > ${f%.*}.x3g |
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
f=T_coolingfan.gcode && cat $f | sed 's/M109 S/M104 S/g' | sed 's/M190 /M109 /g' | /Users/tsnoad/Things/GPX/gpx -s > ${f%.*}.x3g |
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
module m5_thread(height=1,quality=4) { | |
r_maj = 5/2; | |
pitch = 0.8; | |
iso_h = sqrt(3)/2*pitch; | |
r_min = r_maj - 5/8 * iso_h; | |
linear_extrude(height=height,twist=360*height/pitch) hull() for(j=[0,1]) mirror([j,0,0]) for(i=[0:(180/8)/quality:180]) { | |
if (i==0) { | |
square([0.01,r_maj]); | |
} else if (i==180) { |
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 -r '<?php $i = 500295; $reg = 0; $xi = strrev($i); for($j=0;$j<strlen($xi);$j++) { $reg += substr($xi, $j, 1)*pow(2,$j+1); } var_dump($i."\t".($reg)."\t".fmod(fmod((11-fmod($reg,11)),11),10));' | |
<?php | |
for ($i=1;$i<100;$i++) { | |
$reg = 0; | |
$xi = strrev($i); | |
for($j=0;$j<strlen($xi);$j++) { |
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
#!/usr/bin/env ruby | |
require 'base64' | |
require 'digest' | |
# get 16 random hex bytes | |
# | |
def new_salt | |
16.times.inject('') {|t| t << rand(16).to_s(16)} | |
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
<?php | |
if ($_FILES['userfile']['size'] > 5 * 1024 * 1024) { | |
$error = 'File is too large.'; | |
@unlink($_FILES['userfile']['tmp_name']) || $error .= $php_errormsg; | |
} |
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
with dates as ( | |
select sysdate-240 as sometime from dual | |
union select sysdate-180 as sometime from dual | |
union select sysdate-120 as sometime from dual | |
union select sysdate-60 as sometime from dual | |
union select sysdate as sometime from dual | |
union select sysdate+60 as sometime from dual | |
union select sysdate+120 as sometime from dual | |
union select sysdate+180 as sometime from dual | |
union select sysdate+240 as sometime from dual |
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 checkPhone($int_dial_code, $area_code, $local_number) { | |
//try to check and reformat australian numbers | |
if ($int_dial_code == "61") { | |
//combine the area code and local number | |
$full_phone = $area_code.$local_number; | |
//strip spaces and hyphens | |
$full_phone = str_replace(array(" ", "-"), "", $full_phone); | |
NewerOlder