Skip to content

Developer Workflow

Daniel Weck edited this page Aug 9, 2019 · 14 revisions

Ace App (ace-gui)

Note that a special branch and build system is required to integrate the Ace core components (i.e. this ace mono-repository) into the Ace App project (ace-gui repository). Please visit this dedicated wiki page to learn more.

Prerequisites

Initial Setup

  • cd MY_ACE_FOLDER (choose your folder name / filesystem location)
  • git clone https://github.com/daisy/ace.git
  • cd ace
  • git checkout master (or any other suitable branch)
  • rm -rf node_modules && rm -rf packages/*/node_modules (this is really only needed if yarn install was already invoked)
  • rm -rf packages/*/lib (this is really only needed if yarn build was already invoked)
  • rm yarn.lock (advanced step: this is not normally necessary, and should only be used to upgrade NPM dependencies, use with caution!)
  • yarn cache clean (this step is optional, only necessary if the package cache is causing issues)
  • yarn install (this will automatically invoke yarn build)
  • git status && git --no-pager diff (advanced step: this should show yarn.lock changes if rm yarn.lock was previously called)

Unit Tests

  • yarn test
  • yarn test-cli
  • yarn test-electron
  • yarn test-electron-cli

Build, Run

  • yarn build: invoke this script any time the source code is modified, in order to ensure the lib subfolders of each Ace package are re-generated.
  • node packages/ace-cli/bin/ace.js -V -f -o "PATH_TO_OUTPUT_FOLDER" "PATH_TO_EPUB_FILE": this is just an example of how to run the locally-built Ace CLI.

Dependency Maintenance

  • ncu is recommended to discover out of date NPM packages, and to subsequently yarn upgrade or rm -rf node_modules && rm yarn.lock && yarn install (which, in both cases, will update yarn.lock to match frozen versions of the latest available and approved dependencies).

Localization (Translations)

Please visit this dedicated wiki page to learn more about how language resources are created and maintained.

Clone this wiki locally