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
sudo easy_install pyDes |
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
# Grep an object’s available methods | |
# http://rubyquicktips.tumblr.com/post/3360442904/grep-an-objects-available-methods | |
Object.methods.grep /inspect/ | |
=> ["inspect", "pretty_inspect", "pretty_print_inspect"] |
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
# change ssh welcome page | |
vim /etc/motd |
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
#route | |
config.add_route("servertime", "/servertime") | |
#server side | |
@view_config(route_name="servertime", renderer='string') | |
def serverTime(request): | |
return datetime.now() | |
#client | |
var timeStr = $.ajax({url: "/servertime", async: false}).responseText; |
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
from __future__ import absolute_import |
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
lsof -P -i -n |
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
<img height="300" style="border: 0px none; vertical-align: bottom;" src="xxxx.jpeg" /> |
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
area { cursor: pointer;} |
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
from pyramid_chameleon_genshi import renderer_factory | |
config.add_renderer('.genshi', renderer_factory) |
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
curl ifconfig.me/ip -> IP Adress | |
curl ifconfig.me/host -> Remote Host | |
curl ifconfig.me/ua ->User Agent | |
curl ifconfig.me/port -> Port | |
thonks to http://ifconfig.me/ |