Debugging fixed, .gitignore added

- Fixed all the if statements relating to debugging
- Added a .gitignore as to ignore the package build folders
- Added _version() function to report version/date from top of file