-
Make sure
noauth = true
is uncommented at/etc/mongodb.conf
(enabled by default, but just in case) -
Create admin user:
# undo last N commits | |
git reset --hard HEAD~3 | |
git push origin HEAD --force | |
# push to several remotes | |
git remote add all origin-host:path/proj.git | |
git remote set-url --add all a-host:path/proj.git | |
git remote set-url --add all b-host:path/proj.git |
--[[ | |
-- multisource lib | |
-- A multisource is a wrapper on top of a LÖVE source. It allows | |
-- creating multiple sounds easily. It uses an internal pool of | |
-- resources. | |
-- * multisource:play() finds a stopped resource from the pool, | |
-- or creates a new one, and plays and returns it. | |
-- * multisouce:cleanup() liberates the memory of old unplayed sources. | |
]] |
# Symfony2 uses app/console, while Symfony3 uses bin/console | |
# Clear cache and update db data | |
php app/console cache:clear | |
php app/console doctrine:schema:update --force | |
Make sure noauth = true
is uncommented at /etc/mongodb.conf
(enabled by default, but just in case)
Create admin user:
<?php | |
# Tested on Ubuntu 14.04 with Opera Developer 25 Bookmarks file and imported successfully to Google Chrome. | |
# Opera developer folder in Ubuntu 14.04: ~/.config/opera-developer. See Opera About dialog for other OSes. | |
# The JSON file that we have to parse is in /$OPERA_FOLDER/Bookmarks | |
# Usage: php opera25_to_html_bookmarks.php Bookmarks output_file.html | |
if( count($argv) != 3 ) echo "Usage: php opera25_to_html_bookmarks.php Bookmarks output_file.html\n\n"; |
<?php | |
$buffer = ""; | |
while($f = fgets(STDIN)) | |
{ | |
$buffer = $buffer . $f; | |
} | |
function valid_byte($str) | |
{ |
#include <stdio.h> | |
#include <errno.h> | |
#include <string.h> | |
#include <assert.h> | |
/** | |
* http://c.learncodethehardway.org/book/ex20.html | |
*/ | |
#define clean_errno() (errno == 0 ? "None" : strerror(errno)) |
// http://roy-t.nl/index.php/2010/03/04/getting-the-left-forward-and-back-vectors-from-a-view-matrix-directly/ | |
mat4 matrix; | |
vec3 right ( matrix(0,0), matrix(1,0), matrix(2,1) ); | |
vec3 up ( matrix(0,1), matrix(1,1), matrix(2,2) ); | |
vec3 back ( matrix(0,2), matrix(1,2), matrix(2,2) ); |
# LuaRocks for 5.1 | |
./configure --lua-version=5.1 --versioned-rocks-dir --lua-suffix=5.1 | |
make build | |
sudo make install | |
# LuaRocks for 5.2 | |
./configure --lua-version=5.2 --versioned-rocks-dir --lua-suffix=5.2 | |
make build | |
sudo make install |
def upload_to_rename(instance, filename): | |
# handle instance and filename | |
return "sample" | |
def build_concat(basepath, f): | |
def _ret(instance, filename): | |
return basepath + f(instance, filename) | |
return _ret | |