[Pkg-javascript-devel] pkg-js-tools auto install

Xavier yadd at debian.org
Tue Jul 30 09:06:46 BST 2019


Le 30/07/2019 à 09:34, Jérémy Lal a écrit :
> 
> 
> Le mar. 30 juil. 2019 à 08:31, Xavier <yadd at debian.org
> <mailto:yadd at debian.org>> a écrit :
> 
>     Hi all,
> 
>     I continue to improve auto_install. Here is a resume (from doc). Do you
>     thinks it's in the right way to provide an auto-installer? (this part is
>     not published in experimental but ready and with tests on salsa repo)
> 
>     NB: debian/nodejs/
> 
>     - - - 8< - - -
>     pkg-js-tools provides:
>     * dh_auto_configuration for embedded components: it automatically
>     creates links in node_modules/ directory and removes them during clean
>     * dh_auto_install: automatic install (0.8.4)
>       * main module: if no debian/install exists, pkg-js-tools will read
>     package.json#files field to install files. If not, it install all files
> 
>     except *.md, doc*, example*, test*.
> 
> 
> Maybe it would be better to strictly follow rules from
> https://github.com/npm/npm-packlist
> ... but maybe not ! i don't know. I mention it to make sure you're aware
> of that one.

npm modules often install docs and license, that's why I removed them
except if they are listed by the DD in debian/nodejs/**/files or
debian/nodejs/**/install

>     If install is not good, use
>     debian/nodejs/files to fix the list. Files are installed following
>     "Architecture" field in /usr/share/nodejs or /usr/lib/<gnu-arch>/nodejs
>       * components: pkg-js-tools does the same for each component in
>     <module/path>/node_modules/<component-package-name>. To restrict this
>     behavior, write a debian/node_submodules and list the components to
>     install. An empty debian/node_submodules installs no component.
> 
> 
> "debian/node_submodules" -> "debian/nodejs/submodules" ?

Fixed, thanks

>     * dh_auto_test: launch test written in debian/tests/pkg-js/test (using
>     sh -e). If you use pkg-js-autopkgtest, you can also use the same test
>     during build.
> 
>     Files:
> 
>     * debian/nodejs/submodules lists components to install (all if missing)
>     * debian/nodejs/files overwrites package.json#files field.
>     * debian/nodejs/<component>/files overwrites package.json#files field.
>                                       Use component name, not module name
>                                       here if different. An empty file avoid
>                                       any install
>     * debian/nodejs/install overwrite debian/nodejs/files: same usage as
>                             debian/install except that destination not
>                             starting with / are related to arch path
>                            (/usr/share/nodejs or /usr/lib/<gnu-arch>/nodejs)
>     * debian/nodejs/<component>/install overwrite
>                                         debian/nodejs/<component>/files,
>                                         same as debian/nodejs/install for
>                                         components
>     * debian/nodejs/<component>/nolink avoid node_modules links creation for
>                                        this component (configuration step)
> 
> 
> Thanks !

;-)




More information about the Pkg-javascript-devel mailing list