Skip to content

Instantly share code, notes, and snippets.

@ryanwr
ryanwr / gist:b63db0957710a430c6ef
Created February 6, 2016 20:14
Convert source code to PDF
Generate PDF file of source code using enscript and ps2pdf
enscript -r \
--columns=2 \
--file-align=1 \
--highlight \
--color=1 \
--line-numbers \
--header='$N|Page $% of $=' \
-o - \
@ryanwr
ryanwr / gist:199fd1d3da02f9dfdbe5
Last active February 6, 2016 20:09
Using NPM inside a VirtualBox shared folder
Installing a popular build tool such as grunt or gulp on a virtualbox share and a Windows host will cause issues due to Windows not being able to deal with long path names. Below is a solution to install node modules to an internal location rather than the virtualbox share.
Note: In npm 3 this should be a non-issue as it deals with nested dependencies better
"We found that mounting the node_modules folder instead of making a symlinc was a better solution,
but not the easiest one to work with, because mount folders does not persist after VM shutdown."
Source: https://github.com/fideloper/Vaprobash/issues/183
### Bind local folder to node_modules
cd /shared_workspace/project