DI
diegohenicka/barcode-to-pc-server
Barcode to PC server
Barcode to PC server
Useful links
Downloads
- Server: https://barcodetopc.com/#download-server
- Android: https://play.google.com/store/apps/details?id=com.barcodetopc
- iOS: https://itunes.apple.com/app/id1180168368
Repositories
Build status
Setup
- Install the required dependencies:
- Node.js: https://nodejs.org
- RobotJS: https://github.com/octalmage/robotjs#building
- electron-builder: https://github.com/electron-userland/electron-builder/wiki/Multi-Platform-Build#linux
- node_mdns: https://github.com/agnat/node_mdns#installation
- Clone the repository
git clone https://github.com/fttx/barcode-to-pc-server/ cd barcode-to-pc-server npm install- If you get errors related to cairo.h: https://github.com/SuperiorJT/angular2-qrcode#woah-whats-this-npm-error
- If you're building on Windows, you may need to install these packages: Bonjour SDK for Windows v3.0 (bonjoursdksetup.exe)
- If you're building on macOS, you may need to install these packages:
brew install glib - If you're building on Linux, you may need to install these packages:
sudo apt-get install -y libx11-dev libxtst-dev libpng-dev zlib1g-dev icnsutils graphicsmagick
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 all platforms and uploads them to GitHub releases
npm run publish-win # build the angular project in prod mode, generate the app installer for Windows x32, for Windows x64 and uploads them to GitHub releases
npm run publish-ml # build the angular project in prod mode, generate the app installer for macOS, Linux and uploads them to GitHub releases- To sign the installers follow the electron-builder code-signing tutorial. TL;DR: set
CSC_LINKandCSC_KEY_PASSWORDenvironment variables. - To enable the publishing to GitHub releases set
GH_TOKENenvironment variable and give all therepopermissions - The installer will be put in the dist/dist/ folder.
- If you get sass errors run
npm run fix-sass
Run
- If you're working on the angular project (src):
# run npm build before
npm start # run electron with dev tools and the webserver with livereload- If you want to open it on your browser without electron:
npm run browser # run the webserver with livereload only- If you're working on the electron/main.ts file:
npm run watch # run the webserver with livereload and also watch the electron/main.ts file
npm run electron-dev # run electron with dev tools or press F5 if you're using VSCode to start debuggingPublishing updates
The server implements electron-update.
To publish an update:
- Increase the version number of the package.json
- Commit & push the changes
- Add a tag and name it
v<new version number> - Push the tag
Upon the tag push, travis and appveyor will build and sign the new installers. At this point if all looks good the only thing left to do is to publish the Github release draft.
On this page
Languages
TypeScript72.4%HTML16.0%CSS8.4%JavaScript1.7%Shell1.1%NSIS0.4%
Contributors
MIT License
Created March 29, 2018
Updated February 23, 2024