From d5ac7aff1f5a7b2ae291ff5b2d4904d526f4c77f Mon Sep 17 00:00:00 2001 From: Joel Chen Date: Wed, 28 Oct 2020 10:18:36 -0700 Subject: [PATCH] add getDevTaskRunner for loading custom dev tasks --- .../src/config/opt2/xarc-options.ts | 1 - packages/xarc-app-dev/src/lib/dev-tasks.ts | 33 ++- samples/hapi-app/fyn-lock.yaml | 232 ++++++++++++++---- samples/hapi-app/xclap.js | 9 +- 4 files changed, 221 insertions(+), 54 deletions(-) diff --git a/packages/xarc-app-dev/src/config/opt2/xarc-options.ts b/packages/xarc-app-dev/src/config/opt2/xarc-options.ts index d3fba22a9..6e538b666 100644 --- a/packages/xarc-app-dev/src/config/opt2/xarc-options.ts +++ b/packages/xarc-app-dev/src/config/opt2/xarc-options.ts @@ -4,7 +4,6 @@ import { BabelOptions } from "./babel-options"; export type XarcOptions = { // configurations from env-app.ts - /** * hostname to listen on for serving your application * diff --git a/packages/xarc-app-dev/src/lib/dev-tasks.ts b/packages/xarc-app-dev/src/lib/dev-tasks.ts index 97a19ef93..37ec09d06 100644 --- a/packages/xarc-app-dev/src/lib/dev-tasks.ts +++ b/packages/xarc-app-dev/src/lib/dev-tasks.ts @@ -65,13 +65,40 @@ function setWebpackDev() { export { XarcOptions } from "../config/opt2/xarc-options"; +/** + * Get the dev task runner (xclap) from Electrode module's perspective. + * + * @returns the instance of xclap that's required + */ +export function getDevTaskRunner(): any { + return requireAt(process.cwd())("xclap") || require("xclap"); +} + /** * Load xarc development tasks that can be invoked using @xarc/run * + * You can override any of the tasks here by loading your own using the same + * name with a different namespace (ie: "user"). + * + * **For example:** + * + * ```js + * import { getDevTaskRunner, loadXarcDevTasks } from "@xarc/app-dev/lib/dev-tasks" + * + * const xclap = getDevTaskRunner(); + * + * xclap.load("user", { + * check: xclap.exec("echo my custom check task") + * }); + * + * loadXarcDevTasks(); + * ``` + * * @param xrun - `@xarc/run` (or xclap) task runner. pass `null` and an * internal version will be used. * @param xarcOptions user provided options to configure features etc - * @returns void + * + * @returns The xclap task runner instance that was used. */ export function loadXarcDevTasks(xrun, xarcOptions: XarcOptions = {}) { // lazy require modules that have effects so as to permit customization @@ -1234,11 +1261,13 @@ You only need to run this if you are doing something not through the xarc tasks. // require.resolve(`${archetype.devArchetypeName}/package.json`); // } - xrun = xrun || requireAt(process.cwd())("xclap") || require("xclap"); + xrun = xrun || getDevTaskRunner(); process.env._ELECTRODE_DEV_ = "1"; if (!process.env.hasOwnProperty("FORCE_COLOR")) { process.env.FORCE_COLOR = "1"; // force color for chalk } xrun.load("electrode", makeTasks(xrun), -10); generateBrowsersListRc(); + + return xrun; } diff --git a/samples/hapi-app/fyn-lock.yaml b/samples/hapi-app/fyn-lock.yaml index 444f0891a..854bf2b56 100644 --- a/samples/hapi-app/fyn-lock.yaml +++ b/samples/hapi-app/fyn-lock.yaml @@ -22,6 +22,12 @@ _latest: 7.8.3 _: '^7.0.0,^7.8.3': 7.8.3 + ^7.10.4: 7.10.4 + 7.10.4: + $: sha512-vG6SvB6oYEhvgisZNFRmRCUkLz11c7rp+tbNTynGqc6mS1d5ATd/sGyV6W0KZZnXRKMTzZDRgQT3Ou9jhpAfUg== + _: 'https://registry.npmjs.org/@babel/code-frame/-/code-frame-7.10.4.tgz' + dependencies: + '@babel/highlight': ^7.10.4 7.8.3: $: sha512-a9gxpmdXtZEInkCSHUJDLHZVBgb1QS0jhss4cPP93EW7s+uC5bikET2twEF3KV+7rDblJcmNvTR7VJejqd2C2g== _: 'https://registry.npmjs.org/@babel/code-frame/-/code-frame-7.8.3.tgz' @@ -64,7 +70,15 @@ '@babel/generator': _latest: 7.8.4 _: + ^7.12.1: 7.12.1 ^7.8.4: 7.8.4 + 7.12.1: + $: sha512-DB+6rafIdc9o72Yc3/Ph5h+6hUjeOp66pF0naQBgUFFuPqzQwIlPTm3xZR7YNvduIMtkDIj2t21LSQwnbCrXvg== + _: 'https://registry.npmjs.org/@babel/generator/-/generator-7.12.1.tgz' + dependencies: + '@babel/types': ^7.12.1 + jsesc: ^2.5.1 + source-map: ^0.5.0 7.8.4: $: sha512-PwhclGdRpNAf3IxZb0YVuITPZmmrXz9zf6fH8lT4XbrmfQKr6ryBzhv593P5C6poJRciFCL/eHGW2NuGrgEyxA== _: 'https://registry.npmjs.org/@babel/generator/-/generator-7.8.4.tgz' @@ -131,7 +145,19 @@ '@babel/helper-create-class-features-plugin': _latest: 7.8.3 _: + ^7.12.1: 7.12.1 ^7.8.3: 7.8.3 + 7.12.1: + $: sha512-hkL++rWeta/OVOBTRJc9a5Azh5mt5WgZUGAKMD8JM141YsE08K//bp1unBBieO6rUKkIPyUE0USQ30jAy3Sk1w== + _: 'https://registry.npmjs.org/@babel/helper-create-class-features-plugin/-/helper-create-class-features-plugin-7.12.1.tgz' + dependencies: + '@babel/helper-function-name': ^7.10.4 + '@babel/helper-member-expression-to-functions': ^7.12.1 + '@babel/helper-optimise-call-expression': ^7.10.4 + '@babel/helper-replace-supers': ^7.12.1 + '@babel/helper-split-export-declaration': ^7.10.4 + peerDependencies: + '@babel/core': ^7.0.0 7.8.3: $: sha512-qmp4pD7zeTxsv0JNecSBsEmG1ei2MqwJq4YQcK3ZWm/0t07QstWfvuV/vm3Qt5xNMFETn2SZqpMx2MQzbtq+KA== _: 'https://registry.npmjs.org/@babel/helper-create-class-features-plugin/-/helper-create-class-features-plugin-7.8.3.tgz' @@ -180,7 +206,15 @@ '@babel/helper-function-name': _latest: 7.8.3 _: + ^7.10.4: 7.10.4 ^7.8.3: 7.8.3 + 7.10.4: + $: sha512-YdaSyz1n8gY44EmN7x44zBn9zQ1Ry2Y+3GTA+3vH6Mizke1Vw0aWDM66FOYEPw8//qKkmqOckrGgTYa+6sceqQ== + _: 'https://registry.npmjs.org/@babel/helper-function-name/-/helper-function-name-7.10.4.tgz' + dependencies: + '@babel/helper-get-function-arity': ^7.10.4 + '@babel/template': ^7.10.4 + '@babel/types': ^7.10.4 7.8.3: $: sha512-BCxgX1BC2hD/oBlIFUgOCQDOPV8nSINxCwM3o93xP4P9Fq6aV5sgv2cOOITDMtCfQ+3PvHp3l689XZvAM9QyOA== _: 'https://registry.npmjs.org/@babel/helper-function-name/-/helper-function-name-7.8.3.tgz' @@ -191,7 +225,13 @@ '@babel/helper-get-function-arity': _latest: 7.8.3 _: + ^7.10.4: 7.10.4 ^7.8.3: 7.8.3 + 7.10.4: + $: sha512-EkN3YDB+SRDgiIUnNgcmiD361ti+AVbL3f3Henf6dqqUyr5dMsorno0lJWJuLhDhkI5sYEpgj6y9kB8AOU1I2A== + _: 'https://registry.npmjs.org/@babel/helper-get-function-arity/-/helper-get-function-arity-7.10.4.tgz' + dependencies: + '@babel/types': ^7.10.4 7.8.3: $: sha512-FVDR+Gd9iLjUMY1fzE2SR0IuaJToR4RkCDARVfsBBPSP53GEqSFjD8gNyxg246VUyc/ALRxFaAK8rVG7UT7xRA== _: 'https://registry.npmjs.org/@babel/helper-get-function-arity/-/helper-get-function-arity-7.8.3.tgz' @@ -209,7 +249,13 @@ '@babel/helper-member-expression-to-functions': _latest: 7.8.3 _: + ^7.12.1: 7.12.1 ^7.8.3: 7.8.3 + 7.12.1: + $: sha512-k0CIe3tXUKTRSoEx1LQEPFU9vRQfqHtl+kf8eNnDqb4AUJEy5pz6aIiog+YWtVm2jpggjS1laH68bPsR+KWWPQ== + _: 'https://registry.npmjs.org/@babel/helper-member-expression-to-functions/-/helper-member-expression-to-functions-7.12.1.tgz' + dependencies: + '@babel/types': ^7.12.1 7.8.3: $: sha512-fO4Egq88utkQFjbPrSHGmGLFqmrshs11d46WI+WZDESt7Wu7wN2G2Iu+NMMZJFDOVRHAMIkB5SNh30NtwCA7RA== _: 'https://registry.npmjs.org/@babel/helper-member-expression-to-functions/-/helper-member-expression-to-functions-7.8.3.tgz' @@ -241,7 +287,13 @@ '@babel/helper-optimise-call-expression': _latest: 7.8.3 _: + ^7.10.4: 7.10.4 ^7.8.3: 7.8.3 + 7.10.4: + $: sha512-n3UGKY4VXwXThEiKrgRAoVPBMqeoPgHVqiHZOanAJCG9nQUL2pLRQirUzl0ioKclHGpGqRgIOkgcIJaIWLpygg== + _: 'https://registry.npmjs.org/@babel/helper-optimise-call-expression/-/helper-optimise-call-expression-7.10.4.tgz' + dependencies: + '@babel/types': ^7.10.4 7.8.3: $: sha512-Kag20n86cbO2AvHca6EJsvqAd82gc6VMGule4HwebwMlwkpXuVqrNRj6CkCV2sKxgi9MyAUnZVnZ6lJ1/vKhHQ== _: 'https://registry.npmjs.org/@babel/helper-optimise-call-expression/-/helper-optimise-call-expression-7.8.3.tgz' @@ -283,7 +335,16 @@ '@babel/helper-replace-supers': _latest: 7.8.3 _: + ^7.12.1: 7.12.1 ^7.8.3: 7.8.3 + 7.12.1: + $: sha512-zJjTvtNJnCFsCXVi5rUInstLd/EIVNmIKA1Q9ynESmMBWPWd+7sdR+G4/wdu+Mppfep0XLyG2m7EBPvjCeFyrw== + _: 'https://registry.npmjs.org/@babel/helper-replace-supers/-/helper-replace-supers-7.12.1.tgz' + dependencies: + '@babel/helper-member-expression-to-functions': ^7.12.1 + '@babel/helper-optimise-call-expression': ^7.10.4 + '@babel/traverse': ^7.12.1 + '@babel/types': ^7.12.1 7.8.3: $: sha512-xOUssL6ho41U81etpLoT2RTdvdus4VfHamCuAm4AHxGr+0it5fnwoVdwUJ7GFEqCsQYzJUhcbsN9wB9apcYKFA== _: 'https://registry.npmjs.org/@babel/helper-replace-supers/-/helper-replace-supers-7.8.3.tgz' @@ -305,12 +366,25 @@ '@babel/helper-split-export-declaration': _latest: 7.8.3 _: + '^7.10.4,^7.11.0': 7.11.0 ^7.8.3: 7.8.3 + 7.11.0: + $: sha512-74Vejvp6mHkGE+m+k5vHY93FX2cAtrw1zXrZXRlG4l410Nm9PxfEiVTn1PjDPV5SnmieiueY4AFg2xqhNFuuZg== + _: 'https://registry.npmjs.org/@babel/helper-split-export-declaration/-/helper-split-export-declaration-7.11.0.tgz' + dependencies: + '@babel/types': ^7.11.0 7.8.3: $: sha512-3x3yOeyBhW851hroze7ElzdkeRXQYQbFIb7gLK1WQYsw2GWDay5gAJNw1sWJ0VFP6z5J1whqeXH/WCdCjZv6dA== _: 'https://registry.npmjs.org/@babel/helper-split-export-declaration/-/helper-split-export-declaration-7.8.3.tgz' dependencies: '@babel/types': ^7.8.3 +'@babel/helper-validator-identifier': + _latest: 7.10.4 + _: + ^7.10.4: 7.10.4 + 7.10.4: + $: sha512-3U9y+43hz7ZM+rzG24Qe2mufW5KhvFg/NhnNph+i9mgCtdTCtMJuI1TMkrIUiK7Ix4PYlRF9I5dhqaLYA/ADXw== + _: 'https://registry.npmjs.org/@babel/helper-validator-identifier/-/helper-validator-identifier-7.10.4.tgz' '@babel/helper-wrap-function': _latest: 7.8.3 _: @@ -337,7 +411,15 @@ '@babel/highlight': _latest: 7.8.3 _: + ^7.10.4: 7.10.4 ^7.8.3: 7.8.3 + 7.10.4: + $: sha512-i6rgnR/YgPEQzZZnbTHHuZdlE8qyoBNalD6F+q4vAFlcMEcqmkoG+mPqJYJCo63qPf74+Y1UZsl3l6f7/RIkmA== + _: 'https://registry.npmjs.org/@babel/highlight/-/highlight-7.10.4.tgz' + dependencies: + '@babel/helper-validator-identifier': ^7.10.4 + chalk: ^2.0.0 + js-tokens: ^4.0.0 7.8.3: $: sha512-PX4y5xQUvy0fnEVHrYOarRPXVWafSjTW9T0Hab8gVIawpl2Sj0ORyrygANq+KjcNlSSTw0YCLSNA8OyZ1I4yEg== _: 'https://registry.npmjs.org/@babel/highlight/-/highlight-7.8.3.tgz' @@ -349,6 +431,10 @@ _latest: 7.8.4 _: '^7.1.0,^7.8.3,^7.8.4': 7.8.4 + '^7.10.4,^7.12.1': 7.12.3 + 7.12.3: + $: sha512-kFsOS0IbsuhO5ojF8Hc8z/8vEIOkylVBrjiZUbLTE3XFe0Qi+uu6HjzQixkFaqr0ZPAMZcBVxEwmsnsLPZ2Xsw== + _: 'https://registry.npmjs.org/@babel/parser/-/parser-7.12.3.tgz' 7.8.4: $: sha512-0fKu/QqildpXmPVaRBoXOlyBb3MC+J0A66x97qEfLOMkn3u6nfY5esWogQwi/K0BjASYy4DbnsEWnpNL6qT5Mw== _: 'https://registry.npmjs.org/@babel/parser/-/parser-7.8.4.tgz' @@ -639,6 +725,17 @@ '@babel/helper-plugin-utils': ^7.8.3 peerDependencies: '@babel/core': ^7.0.0-0 +'@babel/plugin-syntax-typescript': + _latest: 7.12.1 + _: + ^7.12.1: 7.12.1 + 7.12.1: + $: sha512-UZNEcCY+4Dp9yYRCAHrHDU+9ZXLYaY9MgBXSRLkB9WjYFRR6quJBumfVrEkUxrePPBwFcpWfNKXqVRQQtm7mMA== + _: 'https://registry.npmjs.org/@babel/plugin-syntax-typescript/-/plugin-syntax-typescript-7.12.1.tgz' + dependencies: + '@babel/helper-plugin-utils': ^7.10.4 + peerDependencies: + '@babel/core': ^7.0.0-0 '@babel/plugin-transform-arrow-functions': _latest: 7.8.3 _: @@ -1082,6 +1179,19 @@ '@babel/helper-plugin-utils': ^7.8.3 peerDependencies: '@babel/core': ^7.0.0-0 +'@babel/plugin-transform-typescript': + _latest: 7.12.1 + _: + ^7.12.1: 7.12.1 + 7.12.1: + $: sha512-VrsBByqAIntM+EYMqSm59SiMEf7qkmI9dqMt6RbD/wlwueWmYcI0FFK5Fj47pP6DRZm+3teXjosKlwcZJ5lIMw== + _: 'https://registry.npmjs.org/@babel/plugin-transform-typescript/-/plugin-transform-typescript-7.12.1.tgz' + dependencies: + '@babel/helper-create-class-features-plugin': ^7.12.1 + '@babel/helper-plugin-utils': ^7.10.4 + '@babel/plugin-syntax-typescript': ^7.12.1 + peerDependencies: + '@babel/core': ^7.0.0-0 '@babel/plugin-transform-unicode-regex': _latest: 7.8.3 _: @@ -1176,6 +1286,18 @@ '@babel/plugin-transform-react-jsx-source': ^7.8.3 peerDependencies: '@babel/core': ^7.0.0-0 +'@babel/preset-typescript': + _latest: 7.12.1 + _: + ^7.0.0: 7.12.1 + 7.12.1: + $: sha512-hNK/DhmoJPsksdHuI/RVrcEws7GN5eamhi28JkO52MqIxU8Z0QpmiSOQxZHWOHV7I3P4UjHV97ay4TcamMA6Kw== + _: 'https://registry.npmjs.org/@babel/preset-typescript/-/preset-typescript-7.12.1.tgz' + dependencies: + '@babel/helper-plugin-utils': ^7.10.4 + '@babel/plugin-transform-typescript': ^7.12.1 + peerDependencies: + '@babel/core': ^7.0.0-0 '@babel/register': _latest: 7.8.3 _: @@ -1203,7 +1325,15 @@ '@babel/template': _latest: 7.8.3 _: + ^7.10.4: 7.10.4 '^7.3.3,^7.8.3': 7.8.3 + 7.10.4: + $: sha512-ZCjD27cGJFUB6nmCB1Enki3r+L5kJveX9pq1SvAUKoICy6CZ9yD8xO086YXdYhvNjBdnekm4ZnaP5yC8Cs/1tA== + _: 'https://registry.npmjs.org/@babel/template/-/template-7.10.4.tgz' + dependencies: + '@babel/code-frame': ^7.10.4 + '@babel/parser': ^7.10.4 + '@babel/types': ^7.10.4 7.8.3: $: sha512-04m87AcQgAFdvuoyiQ2kgELr2tV8B4fP/xJAVUL3Yb3bkNdMedD3d0rlSQr3PegP0cms3eHjl1F7PWlvWbU8FQ== _: 'https://registry.npmjs.org/@babel/template/-/template-7.8.3.tgz' @@ -1215,6 +1345,20 @@ _latest: 7.8.4 _: '^7.1.0,^7.8.3,^7.8.4': 7.8.4 + ^7.12.1: 7.12.1 + 7.12.1: + $: sha512-MA3WPoRt1ZHo2ZmoGKNqi20YnPt0B1S0GTZEPhhd+hw2KGUzBlHuVunj6K4sNuK+reEvyiPwtp0cpaqLzJDmAw== + _: 'https://registry.npmjs.org/@babel/traverse/-/traverse-7.12.1.tgz' + dependencies: + '@babel/code-frame': ^7.10.4 + '@babel/generator': ^7.12.1 + '@babel/helper-function-name': ^7.10.4 + '@babel/helper-split-export-declaration': ^7.11.0 + '@babel/parser': ^7.12.1 + '@babel/types': ^7.12.1 + debug: ^4.1.0 + globals: ^11.1.0 + lodash: ^4.17.19 7.8.4: $: sha512-NGLJPZwnVEyBPLI+bl9y9aSnxMhsKz42so7ApAv9D+b4vAFPpY013FTS9LdKxcABoIYFU52HcYga1pPlx454mg== _: 'https://registry.npmjs.org/@babel/traverse/-/traverse-7.8.4.tgz' @@ -1232,6 +1376,14 @@ _latest: 7.8.3 _: '^7.0.0,^7.0.0-beta.49,^7.3.0,^7.3.3,^7.8.3': 7.8.3 + '^7.10.4,^7.11.0,^7.12.1': 7.12.1 + 7.12.1: + $: sha512-BzSY3NJBKM4kyatSOWh3D/JJ2O3CVzBybHWxtgxnggaxEuaSTTDqeiSb/xk9lrkw2Tbqyivw5ZU4rT+EfznQsA== + _: 'https://registry.npmjs.org/@babel/types/-/types-7.12.1.tgz' + dependencies: + '@babel/helper-validator-identifier': ^7.10.4 + lodash: ^4.17.19 + to-fast-properties: ^2.0.0 7.8.3: $: sha512-jBD+G8+LWpMBBWvVcdr4QysjUE4mU/syrhN17o1u3gx0/WzJB1kwiVZAXRtWbsIPOwW8pF/YJV5+nmetPzepXg== _: 'https://registry.npmjs.org/@babel/types/-/types-7.8.3.tgz' @@ -2337,10 +2489,10 @@ '@webassemblyjs/wast-parser': 1.9.0 '@xtuc/long': 4.2.2 '@xarc/app': - _latest: 8.1.15-fynlocal_h + _latest: 8.1.21-fynlocal_h _: - ../../packages/xarc-app: 8.1.15-fynlocal_h - 8.1.15-fynlocal_h: + ../../packages/xarc-app: 8.1.21-fynlocal_h + 8.1.21-fynlocal_h: top: 1 $: local _: ../../packages/xarc-app @@ -2348,14 +2500,14 @@ '@babel/runtime': ^7.8.3 css-modules-require-hook: ^4.0.2 ignore-styles: ^5.0.1 - isomorphic-loader: ^3.2.0 + isomorphic-loader: ^4.0.3 optional-require: ^1.0.0 subapp-util: ^1.1.1 '@xarc/app-dev': - _latest: 8.1.15-fynlocal_h + _latest: 8.1.21-fynlocal_h _: - ../../packages/xarc-app-dev: 8.1.15-fynlocal_h - 8.1.15-fynlocal_h: + ../../packages/xarc-app-dev: 8.1.21-fynlocal_h + 8.1.21-fynlocal_h: top: 1 $: local _: ../../packages/xarc-app-dev @@ -2371,10 +2523,11 @@ '@babel/plugin-transform-runtime': ^7.1.0 '@babel/preset-env': ^7.1.6 '@babel/preset-react': ^7.0.0 + '@babel/preset-typescript': ^7.0.0 '@babel/register': ^7.0.0 '@jchip/redbird': ^1.1.2 '@loadable/babel-plugin': ^5.10.0 - '@xarc/webpack': ^8.1.5 + '@xarc/webpack': ^9.0.2 ansi-to-html: ^0.6.8 babel-plugin-dynamic-import-node: ^2.2.0 babel-plugin-lodash: ^3.3.4 @@ -2391,7 +2544,6 @@ fs-extra: ^9.0.1 identity-obj-proxy: ^3.0.0 is-ci: ^2.0.0 - isomorphic-loader: ^3.2.0 lodash: ^4.17.19 log-update: ^4.0.0 mime: ^2.4.6 @@ -2419,7 +2571,7 @@ xenv-config: ^1.3.1 xsh: ^0.4.5 peerDependencies: - '@xarc/app': ^8.0.21 + '@xarc/app': ^8.1.19 '@xarc/opt-jest': _latest: 1.0.0-fynlocal_h _: @@ -2501,15 +2653,15 @@ stylus: ^0.54.7 stylus-relative-loader: ^3.4.0 '@xarc/react': - _latest: 0.0.1-fynlocal_h + _latest: 0.0.2-fynlocal_h _: - ../../packages/xarc-react: 0.0.1-fynlocal_h - 0.0.1-fynlocal_h: + ../../packages/xarc-react: 0.0.2-fynlocal_h + 0.0.2-fynlocal_h: top: 1 $: local _: ../../packages/xarc-react dependencies: - '@xarc/subapp': ../xarc-subapp + '@xarc/subapp': ^0.0.2 react: ^16.13.1 react-dom: ^16.13.1 '@xarc/run': @@ -2534,17 +2686,17 @@ unwrap-npm-cmd: ^1.1.1 xsh: ^0.4.5 '@xarc/subapp': - _latest: 0.0.1-fynlocal_h + _latest: 0.0.2-fynlocal_h _: - ../xarc-subapp: 0.0.1-fynlocal_h - 0.0.1-fynlocal_h: + ../xarc-subapp: 0.0.2-fynlocal_h + 0.0.2-fynlocal_h: $: local _: ../../packages/xarc-subapp '@xarc/webpack': - _latest: 8.1.5-fynlocal_h + _latest: 9.0.2-fynlocal_h _: - ../xarc-webpack: 8.1.5-fynlocal_h - 8.1.5-fynlocal_h: + ../xarc-webpack: 9.0.2-fynlocal_h + 9.0.2-fynlocal_h: $: local _: ../../packages/xarc-webpack dependencies: @@ -2558,7 +2710,6 @@ electrode-node-resolver: ^2.0.1 file-loader: ^2.0.0 filter-scan-dir: ^1.0.9 - isomorphic-loader: ^3.2.0 lodash: ^4.17.19 mini-css-extract-plugin: ^0.9.0 mkdirp: ^1.0.3 @@ -2572,8 +2723,8 @@ webpack-stats-plugin: ^0.3.1 xsh: ^0.4.5 peerDependencies: - '@xarc/app': ^8.0.0 - '@xarc/app-dev': ^8.0.0 + '@xarc/app': ^8.1.19 + '@xarc/app-dev': ^8.1.19 '@xtuc/ieee754': _latest: 1.2.0 _: @@ -4596,13 +4747,6 @@ decode-uri-component: 0.2.0: $: sha1-6zkTMzRYd1y4TNGh+uBiEGu4dUU= _: 'https://registry.npmjs.org/decode-uri-component/-/decode-uri-component-0.2.0.tgz' -deep-extend: - _latest: 0.6.0 - _: - ^0.6.0: 0.6.0 - 0.6.0: - $: sha512-LOHxIOaPYdHlJRtCQfDIVZtfw/ufM8+rVj649RIHzcm/vGwQRXFt6OPqIFWsm2XEMrNIEtWR64sY1LEKD2vAOA== - _: 'https://registry.npmjs.org/deep-extend/-/deep-extend-0.6.0.tgz' deep-is: _latest: 0.1.3 _: @@ -4879,10 +5023,10 @@ electrode-node-resolver: dependencies: require-at: ^1.0.0 electrode-react-webapp: - _latest: 4.0.0-fynlocal_h + _latest: 4.0.1-fynlocal_h _: - ../../packages/electrode-react-webapp: 4.0.0-fynlocal_h - 4.0.0-fynlocal_h: + ../../packages/electrode-react-webapp: 4.0.1-fynlocal_h + 4.0.1-fynlocal_h: top: 1 $: local _: ../../packages/electrode-react-webapp @@ -6847,15 +6991,12 @@ isobject: dependencies: isarray: 1.0.0 isomorphic-loader: - _latest: 3.2.0 + _latest: 4.0.3 _: - ^3.2.0: 3.2.0 - 3.2.0: - $: sha512-7hbfhhrL8XIYIkh+HOq6R6TCxYUsDKFPvcwoC6iLG2SyL7DNS5pl8sJD+j35oRqqvkPTpt5kMYTvNpJomY83bg== - _: 'https://registry.npmjs.org/isomorphic-loader/-/isomorphic-loader-3.2.0.tgz' - dependencies: - deep-extend: ^0.6.0 - lockfile: ^1.0.4 + ^4.0.3: 4.0.3 + 4.0.3: + $: sha512-V7k4DMSa8DF+p/SXvOPTwmANyIa/mGDnT1RZ4iOsoizpEvYGOUteNRezdRbd/LikdTefp0SnNOfi2Wey0RRhnw== + _: 'https://registry.npmjs.org/isomorphic-loader/-/isomorphic-loader-4.0.3.tgz' isstream: _latest: 0.1.2 _: @@ -7823,15 +7964,6 @@ locate-path: dependencies: p-locate: ^3.0.0 path-exists: ^3.0.0 -lockfile: - _latest: 1.0.4 - _: - ^1.0.4: 1.0.4 - 1.0.4: - $: sha512-cvbTwETRfsFh4nHsL1eGWapU1XFi5Ot9E85sWAwia7Y7EgB7vfqcZhTKZ+l7hCGxSPoushMv5GKhT5PdLv03WA== - _: 'https://registry.npmjs.org/lockfile/-/lockfile-1.0.4.tgz' - dependencies: - signal-exit: ^3.0.2 lodash: _latest: 4.17.15 _: diff --git a/samples/hapi-app/xclap.js b/samples/hapi-app/xclap.js index b58906415..be270138c 100644 --- a/samples/hapi-app/xclap.js +++ b/samples/hapi-app/xclap.js @@ -46,6 +46,13 @@ process.env.ENABLE_SHORTEN_CSS_NAMES = true; // process.env.KARMA_BROWSER = "phantomjs"; -require("@xarc/app")(); +const { getDevTaskRunner, loadXarcDevTasks } = require("@xarc/app-dev/lib/dev-tasks"); + +const runner = getDevTaskRunner(); +runner.load({ + foo: runner.exec("echo hello from foo task") +}); + +loadXarcDevTasks(); //