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
import 'package:flutter/material.dart'; | |
const String words1 = "Almost before we knew it, we had left the ground."; | |
const String words2 = "A shining crescent far beneath the flying vessel."; | |
const String words3 = "A red flair silhouetted the jagged edge of a wing."; | |
const String words4 = "Mist enveloped the ship three hours out from port."; | |
void main() { | |
runApp(new MyApp()); | |
} |
# first: | |
lsbom -f -l -s -pf /var/db/receipts/org.nodejs.pkg.bom | while read f; do sudo rm /usr/local/${f}; done | |
sudo rm -rf /usr/local/lib/node /usr/local/lib/node_modules /var/db/receipts/org.nodejs.* | |
# To recap, the best way (I've found) to completely uninstall node + npm is to do the following: | |
# go to /usr/local/lib and delete any node and node_modules | |
cd /usr/local/lib | |
sudo rm -rf node* |
package main | |
import ( | |
"fmt" | |
"gopkg.in/mgo.v2" | |
"gopkg.in/mgo.v2/bson" | |
) | |
type msg struct { | |
// Msg string `bson:"msg"` |
if _, err := os.Stat("/path/to/whatever"); os.IsNotExist(err) { | |
// path/to/whatever does not exist | |
} | |
if _, err := os.Stat("/path/to/whatever"); !os.IsNotExist(err) { | |
// path/to/whatever exists | |
} |
#import <UIKit/UIKit.h> | |
@interface UILabel (ContentSize) | |
- (CGSize)contentSize; | |
@end |
#import <Foundation/Foundation.h> | |
@interface NSObject (LogDealloc) | |
- (void)logOnDealloc; | |
@end |
<?php | |
/* | |
Plugin Name: Disable Admin and Login | |
Plugin URI: http://wordpress.stackexchange.com/a/106437/12615 | |
Requires: PHP 5.3 | |
*/ | |
add_action( 'init', function() | |
{ | |
$currentURL = $_SERVER["HTTP_HOST"] . $_SERVER["REQUEST_URI"]; |
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
At the top of the file there should be a short introduction and/ or overview that explains what the project is. This description should match descriptions added for package managers (Gemspec, package.json, etc.)
Show what the library does as concisely as possible, developers should be able to figure out how your project solves their problem by looking at the code example. Make sure the API you are showing off is obvious, and that your code is short and concise.