This file contains hidden or 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
- Create EC2 instance - you should have your file.pem public key file saved somewhere. | |
- Assign Elastic IP. | |
- Configure security groups for ports 80, 20, pasv ftp range and if you want to enable ping: custom IMCP rule 'echo request' | |
ssh -i file.pem ubuntu@YOUR_IP | |
- INSTALL VSFTPD | |
sudo apt-get install vsftpd | |
to restart: |
This file contains hidden or 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 Foo = Class.extend(function() { | |
this.var1 = "var1 foo"; | |
}); | |
var Bar = Foo.extend(function() { | |
this.var1 = "var1 bar" | |
console.log(this.super.var1); // access var1 from the base class | |
}); |
This file contains hidden or 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 hsv2hex(hsv) { | |
return rgb2hex(hsv2rgb(hsv)); | |
} | |
function hex2hsv(hex) { | |
var dec = hex2dec(hex); | |
var rgb = dec2rgb(dec); | |
var hsv = rgb2hsv(rgb); | |
return hsv; | |
} |
This file contains hidden or 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 hex2dec(hex) { | |
hex = hex.toLowerCase(hex).split(''); | |
var dec = 0; | |
while(h = hex.shift()) { | |
var code = h.charCodeAt(0); | |
dec = dec << 4; | |
dec += code < 58 ? code - 48 : code - 87; | |
} | |
return dec; | |
} |
NewerOlder