Each of these commands will run an ad hoc http static server in your current (or specified) directory, available at http://localhost:8000. Use this power wisely.
$ python -m SimpleHTTPServer 8000| # 30 minutes Lisp in Ruby | |
| # Hong Minhee <http://dahlia.kr/> | |
| # | |
| # This Lisp implementation does not provide a s-expression reader. | |
| # Instead, it uses Ruby syntax like following code: | |
| # | |
| # [:def, :factorial, | |
| # [:lambda, [:n], | |
| # [:if, [:"=", :n, 1], | |
| # 1, |
| #!/bin/sh | |
| # Quick start-stop-daemon example, derived from Debian /etc/init.d/ssh | |
| set -e | |
| # Must be a valid filename | |
| NAME=foo | |
| PIDFILE=/var/run/$NAME.pid | |
| #This is the command to be run, give the full pathname | |
| DAEMON=/usr/local/bin/bar |
| public static String integerToStringIP(int ip) { | |
| return ((ip >> 24 ) & 0xFF) + "." + | |
| ((ip >> 16 ) & 0xFF) + "." + | |
| ((ip >> 8 ) & 0xFF) + "." + | |
| ( ip & 0xFF); | |
| } |
| upstream rails { | |
| server 127.0.0.1:3000; | |
| #server unix:/tmp/thin.0.sock; | |
| } | |
| server { | |
| # we haven't checked to see if Rack::Deflate on the app server is | |
| # faster or not than doing compression via nginx. It's easier | |
| # to configure it all in one place here for static files and also | |
| # to disable gzip for clients who don't get gzip/deflate right. |
| http://blog.desgrange.net/2012/06/05/caldav-carddav-debian-davical-ios-ical.html | |
| mike@rbci:~$ psql -U postgres | |
| psql (9.0.3) | |
| Type "help" for help. | |
| postgres=# update pg_database set datallowconn = TRUE where datname = 'template0'; | |
| UPDATE 1 | |
| postgres=# \c template0 | |
| You are now connected to database "template0". |
| #!/usr/bin/env python | |
| from gevent import monkey | |
| monkey.patch_all() # Patch everything | |
| import gevent | |
| import time | |
| class Hub(object): | |
| """A simple reactor hub... In async!""" |
| #!/bin/bash | |
| /System/Library/Frameworks/CoreServices.framework/Frameworks/LaunchServices.framework/Support/lsregister -kill -r -domain local -domain system -domain user | |
| killall Finder |
| source "https://rubygems.org" | |
| gem "sinatra" | |
| gem "tilt-jbuilder", ">= 0.4.0", :require => "sinatra/jbuilder" | |
| gem "hashie" |
| #!/bin/bash | |
| # From http://tech.serbinn.net/2010/shell-script-to-create-ramdisk-on-mac-os-x/ | |
| # | |
| ARGS=2 | |
| E_BADARGS=99 | |
| if [ $# -ne $ARGS ] # correct number of arguments to the script; | |
| then |
Each of these commands will run an ad hoc http static server in your current (or specified) directory, available at http://localhost:8000. Use this power wisely.
$ python -m SimpleHTTPServer 8000