Skip to content

MadisonBarks/barcode-to-pc-server

 
 

Repository files navigation

Modified by wuvvy_

Version 3.13.1

Useful links

Barcode to PC server

Build status

Setup

  1. Install the required dependencies:

  2. Clone the repository

    git clone https://github.com/fttx/barcode-to-pc-server/
    cd barcode-to-pc-server
    npm install

Run

The npm start command:

  • Runs the Electron app in development mode
  • Launches the ionic project in livereload mode

Notes:

  • npm run build must be called at least once before using npm start
  • If you're editing the electron folder, you have to quit the server and run it again. Use the F6 button on Visual Studio Code.
  • If you're using Windows use cmd.exe

Release

npm run dist # build the angular project in prod mode and generate the app install files for the current platform, works with Windows/macOS/Linux. Out dir: dist/dist/
npm run publish # build the angular project in prod mode and generate the app installer for the current platform and uploads it to GitHub releases
  • To enable the publishing to GitHub releases set GH_TOKEN environment variable and give all the repo permissions
  • The installer will be put in the dist/dist/ folder.
  • If you get sass errors run cd ionic && npm rebuild node-sass --force

Code Signing

  1. Set certificateSubjectName or certificateSha1 parameter in the package.json
  2. Connect the physical token (Use the Microsoft Remote Desktop app to share the token with virtual machines)
  3. Run npm run publish

Resources:

Simulate updates

  1. Install minio as explained here
  2. Run ./node_modules/.bin/electron-builder --project ./dist/ -c.compression=store --config.publish.provider=s3 --config.publish.endpoint=http://IP:9000 --config.publish.bucket=test-update

Publishing updates

The server implements electron-update.

To publish an update:

  1. Draft a new release on GitHub and name it v<new version number>
  2. Increase the version number of the package.json
  3. Commit & push the changes
  4. Add a tag and name it v<new version number>
  5. Push the tag
  6. Run npm run publish

Note: for macOS delete the electron/electron-resources/*.rtf folder and run: npm run publish

At this point if all looks good the only thing left to do is to publish the Github release draft.

Packages

No packages published

Languages

  • TypeScript 53.6%
  • Rich Text Format 18.4%
  • HTML 17.1%
  • JavaScript 5.8%
  • SCSS 4.6%
  • Shell 0.3%
  • NSIS 0.2%