Closed sbs20 closed 1 year ago
Hi, so I've noticed that the systemd service has been integrated into the Debian packaging script, but this is not a problem, since I can just put the service inside the AUR git repo (and I suppose there won't be any big changes there). Also as I am not totally fond with vue and npm in its specifics, I want to verify that the building commands looks correct to you:
npm run build:version && npm run build --workspaces && node build.js --assemble npm install --production
I've adopted the PKGBUILD file, and it builds succesfully, but I didn't have time yet to test it.
Ah yes, the build.
The minimum you need to do is:
# Run clean-install instead of just npm install - you can google the behaviour but
# in short it's faster and more reliable for deployment
npm clean-install .
# You can just do this instead which will call the same commands you added above
npm run build
# This is the final step for you though which is to install the node_modules you need
# only at runtime. See:
# https://github.com/sbs20/scanservjs/blob/f25d6ceec45f7b8318219ccf50a40b1e745e60e9/makedeb.sh#L37
npm clean-install --omit=dev --only=prod --loglevel=error --prefix dist
So your build becomes the following (diffed from AUR):
build() {
cd scanservjs-${pkgver}
- export NODE_OPTIONS=--openssl-legacy-provider
- npm run install
+ npm clean-install .
npm run build
- cd dist
- npm install --production
+ npm clean-install --omit=dev --only=prod --loglevel=error --prefix dist
+
+ # Get rid of map files (only used for development debugging)
+ find dist/node_modules -name "*.map" -type f -delete
}
I'm still a little way off actually releasing this new version, but wanted to keep you in the loop.
Thank you so much for your help. It assisted with #662!
Also you may wish to take depends
and optdepends
from Depends
and Recommends
here
Closing because there's nothing more I can do here. If you need any assistance drop a note here and I'll do whatever I can to help.
With version 3 coming up, there are some notable changes to the overall build.
.deb
package. This anar
archive with some nested tarballs and installation scriptsBefore everything is committed to mainline and released I wanted to see if there was anything I could do to make things better or easier for the Arch AUR maintenance.