grantnicholas.io
A blog about my adventures in programming
Expressjs no such file or directory error
There are two packages in ubuntu: node and nodejs Most nodejs programs and libraries assume nodejs binary is node. The fix involves symlinking the two together: sudo ln -s /usr/bin/nodejs /usr/local/bin/node Taken from here: http://stackoverflow.com/questions/14914715/express-js-no-such-file-or-directory
Favorite xkcd
Keeping this here so it does not get lost http://xkcd.com/304/
Git clear cache
To untrack a file that has been added/initialized to your repository ie) stop tracking the file but do not delete it Commit any outstanding code changes To remove any changed files from the index use: git rm -r --cached . git add -A git commit -m ".gitignore is now working"...
Remote connection to MySQL via SSH
Was trying to connect to MySQL on a remote server via SSH. Was getting permission errors so needed to remotely connect to MySQL via an SSH tunnel ssh login@serverip -L 3306:127.0.0.1:3306 -N mysql -u username -p enter your password and you are in! Really simple. You might have to change...
Bypass sql file upload limits
Was trying to upload a sql file through drupal's built in FTP in order to migrate a database. There was an upload limit that I needed to bypass. By zipping up the file I was able to get around the upload limit. navigate to your mysql/bin directory mysqldump -u username...