This file contains 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
<!DOCTYPE html> | |
<html ng-app="videoGameStore"> | |
<head> | |
<script src="http://code.jquery.com/jquery-2.1.1.min.js"></script> | |
<meta name="description" content="Angular Bootstrap Product List" /> | |
<link href="http://maxcdn.bootstrapcdn.com/bootstrap/3.2.0/css/bootstrap.min.css" rel="stylesheet" type="text/css" /> | |
<script src="http://maxcdn.bootstrapcdn.com/bootstrap/3.2.0/js/bootstrap.min.js"></script> | |
<script src="http://ajax.googleapis.com/ajax/libs/angularjs/1.2.14/angular.min.js"></script> | |
<meta charset="utf-8"> | |
<title>Angular Bootstrap Product List</title> |
This file contains 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
<!DOCTYPE html> | |
<html> | |
<head> | |
<meta name="description" content="Famo.us Mobile App Example" /> | |
<meta charset="utf-8"> | |
<title>Famo.us Mobile App Example</title> | |
<meta name="viewport" content="width=device-width, maximum-scale=1, user-scalable=no" /> | |
<meta name="mobile-web-app-capable" content="yes" /> | |
<meta name="apple-mobile-web-app-capable" content="yes" /> | |
<meta name="apple-mobile-web-app-status-bar-style" content="black" /> |
This file contains 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
<!DOCTYPE html> | |
<html> | |
<head> | |
<meta name="description" content="Famo.us FormContainerSurface" /> | |
<meta charset="utf-8"> | |
<title>Famo.us FormContainerSurface</title> | |
<meta name="viewport" content="width=device-width, maximum-scale=1, user-scalable=no" /> | |
<meta name="mobile-web-app-capable" content="yes" /> | |
<meta name="apple-mobile-web-app-capable" content="yes" /> | |
<meta name="apple-mobile-web-app-status-bar-style" content="black" /> |
This file contains 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
#!/bin/sh | |
find . -name '*.js' | xargs wc -l |
This file contains 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
Open up a terminal and type: | |
$ cd /home/somedir | |
$ python -m SimpleHTTPServer | |
That's it! Now your http server will start in port 8000. You will get the message: | |
Serving HTTP on 0.0.0.0 port 8000 ... | |
Now open a browser and type the following address: | |
http://192.168.1.2:8000 |
This file contains 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
$ mongo --quiet dbname --eval 'printjson(db.collection.find().toArray())' > output.json |
This file contains 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
ps ax | grep node | grep meteor | |
kill -9 <id> |
This file contains 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
#!/bin/bash | |
#add a smart package and reset meteorite | |
PACKAGE=$1 | |
mrt add $PACKAGE | |
rm -rf /home/$USER/.meteorite | |
mrt install |
This file contains 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
upstream my_upstream { #this line starts the list of real resources that exist behind the nginx server | |
server 127.0.0.1:1337; | |
server 127.0.0.1:1338; #these servers are used in the order they are defined, in round robin fashion. there's more ways of load balancing in the docs | |
server 127.0.0.1:1339 backup; #amazingness no.1, the keyword "backup" means that this server should only be used when the rest are non-responsive | |
keepalive 64; | |
} | |
server { | |
listen 80; | |
location /resource.html { #in my example the server only responds to requests for the file /request.html |
This file contains 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
#!/bin/sh | |
export MONGO_URL='mongodb://localhost:27017/appname' | |
export ROOT_URL='http://domain.com' | |
export MAIL_URL='smtp://[email protected]:587' | |
node main.js | |
#forever main.js |