Skip to content

Latest commit

 

History

History
70 lines (52 loc) · 2.8 KB

CONTRIBUTING.md

File metadata and controls

70 lines (52 loc) · 2.8 KB

Patchwork Contribution Guidelines

Hey, thanks for contributing to Patchwork! We've collected some useful info below, but if you have any questions please don't hesitate to create an issue!

If you're a new contributor you may want to browse the label "Good first issue".

Process

Patchwork is developed on GitHub using the usual GitHub flow. New releases are usually at least a week apart, and code in master should always work.

Style

Please ensure all submitted code conforms to StandardJS. This makes our code more consistent and accessible for people who are working on Patchwork.

You can run npm test or npx standard to run the linter. Lots of small issues can be automatically fixed using npx standard --fix.

Structure

Our directory structure isn't static, but generally it's pretty consistent.

  • assets: miscellaneous static files (images, HTML, XML, etc)
  • build: files for building Patchwork with electron-builder
  • docs: documents (like this one!) for working on Patchwork
  • dist: temporary build files generated by electron-builder
  • lib: JavaScript files that make Patchwork work!
  • locales: translations of Patchwork in lots of different languages
  • scripts: utility scripts designed to automate repetitive tasks
  • styles: interface styles written with micro-css

Debugging

You can increase Patchwork's logging output by making it more verbose. Try launching Patchwork with different logging levels to change the amount of console output:

npm start -- --logging.level info

Modules

Please consider depject deprecated in Patchwork! It should be removed in the future so please don't add new depject modules.

Currently patch-settings is the only dependency that includes depject modules, and that's for legacy reasons. Please don't treat this as a best practice or follow its example.

Please do as much as possible in the Patchwork repo rather than splitting your work into a bunch of modules. This makes it easier to maintain and update the over all application. Only modularize code that are clearly reusable and make sense as independent modules (algorithms, widgets, indexes) and use require() to include them.