-
switch to or branch from
develop
-
npm install
(make sure to use Node 12.14.0, see troubleshooting) -
if not installed;
npm install foreman -g
-
run
npm run electron-rebuild
-
run
npm run pre-build-iohook-win
If this is the first time after installing:
npm run build
or npm run electron-build
Once finished simply do npm run start
If electron fails use these to debug the problem:
electron .
npm run electron
-
npm run build
for desktop -
npm run build:web
for web
To open DevTools (show console errors, add breakpoints, etc) to the renderer use the keys Alt + Shift + D
To open the DevTools and the window of the background (used for OpenCv template matching) process you can use Alt + Shift + E
npm run jest:ci:watch
opens jest watcher with common CI tests
npm run test:all
Runs a single pass of lint + jest
To run or develop visual tests;
- Build for web:
npm run build:web
- Start Jest server:
npm run jest-server
- Start Jest server:
npm run jest-server
(dont close it) - Start Jest watcher:
npm run jest:watch
All visual tests are declared in src/__tests__/electron.ts
and the code for the test component is in src/renderer/views/tests/index.tsx
-
For every new task Branch from
develop
-
Submit PR, merge into
develop
We use commitzen to enforce commits format, You can use npx cz
or npm run cm
to create a new valid commit. Releases, semantic version numbers, tags, changelogs and publishing will automatically be handled based on these commits thanks to semantic-release (WIP).
Try to keep develop
in a buildable and runnable state.
- Node 12.14.0 is required, you can use nvm-windows or nvm to manage multiple versions of Node
- Download the nvm installer
- In a new command prompt, install Node:
nvm install 12.14.0
- After that, use that version:
nvm use 12.14.0
- If you get an error about not being able to find the
/fx
folder try runningnpm run electron-build
again