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| <?php | |
| include '../vendor/autoload.php'; | |
| $classLoader = new \Doctrine\Common\ClassLoader('Entities', __DIR__); | |
| $classLoader->register(); | |
| $classLoader = new \Doctrine\Common\ClassLoader('Proxies', __DIR__); | |
| $classLoader->register(); | |
| // config | |
| $config = new \Doctrine\ORM\Configuration(); |
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| #!/usr/bin/perl | |
| use strict; | |
| use warnings; | |
| # install libio-socket-ssl-perl to get this | |
| use IO::Socket::SSL; | |
| my $hostname = shift or die "Usage: $0 www.example.com\n"; | |
| IO::Socket::SSL->new( | |
| PeerHost => "$hostname:443", |
| #!/bin/bash | |
| # https://gist.github.com/949831 | |
| # http://blog.carbonfive.com/2011/05/04/automated-ad-hoc-builds-using-xcode-4/ | |
| # command line OTA distribution references and examples | |
| # http://nachbaur.com/blog/how-to-automate-your-iphone-app-builds-with-hudson | |
| # http://nachbaur.com/blog/building-ios-apps-for-over-the-air-adhoc-distribution | |
| # http://blog.octo.com/en/automating-over-the-air-deployment-for-iphone/ | |
| # http://www.neat.io/posts/2010/10/27/automated-ota-ios-app-distribution.html |
| dmg=$1 | |
| # A script to install Unity3d automatically from the command line given a dmg file. | |
| # The resulting file is stored under /Applications/Unity$VERSION | |
| # check assumptions | |
| unityhome=/Applications/Unity | |
| if [[ -d "$unityhome" ]]; then | |
| echo "ERROR: $unityhome already present" |
| <?php | |
| //////////////////////////////////////////// | |
| // sanitize function | |
| // thanks to: http://www.programmingtalk.com/showthread.php?t=47560&page=2&highlight=injection | |
| function sanitize($dtype, $dlen, $data){ | |
| // dtype 1: allow numbers, space, and '-' | |
| // dtype 2: allow alpha and spaces only |
| define accounts::virtual ($uid,$realname,$pass,$sshkeytype,$sshkey) { | |
| include accounts::params | |
| # Pull in values from accounts::params | |
| $homepath = $accounts::params::homepath | |
| $shell = $accounts::params::shell | |
| # Create the user | |
| user { $title: | |
| ensure => 'present', |
| // C# example | |
| using UnityEditor; | |
| using System.IO; | |
| using System.Collections; | |
| using UnityEngine; | |
| using System.Collections.Generic; | |
| class PerformBuild | |
| { | |
| static string[] GetBuildScenes() |
| ############################################################################### | |
| ## Monit control file | |
| ############################################################################### | |
| ## | |
| ## Comments begin with a '#' and extend through the end of the line. Keywords | |
| ## are case insensitive. All path's MUST BE FULLY QUALIFIED, starting with '/'. | |
| ## | |
| ## Below you will find examples of some frequently used statements. For | |
| ## information about the control file, a complete list of statements and | |
| ## options please have a look in the monit manual. |
| // Basic XMPP bot example for HipChat using node.js | |
| // To use: | |
| // 1. Set config variables | |
| // 2. Run `node hipchat_bot.js` | |
| // 3. Send a message like "!weather 94085" in the room with the bot | |
| var request = require('request'); // github.com/mikeal/request | |
| var sys = require('sys'); | |
| var util = require('util'); |