Skip to content

Commit

Permalink
Move more files out of root
Browse files Browse the repository at this point in the history
  • Loading branch information
jkuester committed Jan 5, 2024
1 parent ced2627 commit c858286
Show file tree
Hide file tree
Showing 10 changed files with 31 additions and 34 deletions.
3 changes: 0 additions & 3 deletions all-chts-bundle.js

This file was deleted.

2 changes: 1 addition & 1 deletion build.sh
Original file line number Diff line number Diff line change
Expand Up @@ -41,7 +41,7 @@ for version in "${versions[@]}"; do
cp ./build/cht-core-4-6/api/src/enketo-transformer/xsl/* dist/"$version"/enketo-transformer/xsl
done

npx webpack --config webpack.config.cht-core.js --env.cht='cht-core-4-6'
npx webpack --config cht-bundles/webpack.config.cht-core.js --env.cht='cht-core-4-6'

npx webpack

Expand Down
3 changes: 3 additions & 0 deletions cht-bundles/all-chts-bundle.js
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
module.exports = {
'4.6': require('../dist/cht-core-4-6/cht-core-bundle.dev'),
};
1 change: 0 additions & 1 deletion cht-bundles/cht-core-4-6/bundle.js
Original file line number Diff line number Diff line change
@@ -1,4 +1,3 @@
const path = require('path');
module.exports = {
ddocs: require('../../build/cht-core-4-6-ddocs.json'),
RegistrationUtils: require('../../build/cht-core-4-6/shared-libs/registration-utils'),
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ module.exports = env => [
{
entry: `./cht-bundles/${env.cht}/bundle.js`,
output: {
path: path.join(__dirname, 'dist', env.cht),
path: path.join(__dirname,'../', 'dist', env.cht),
filename: `cht-core-bundle.dev.js`,
library: {
type: 'commonjs',
Expand All @@ -13,7 +13,7 @@ module.exports = env => [
resolve: {
alias: {
// inside cht-core/api/src/services/generate-xform.js
'../xsl/xsl-paths': path.join(__dirname, 'cht-bundles', env.cht, 'xsl-paths.js'),
'../xsl/xsl-paths': path.join(__dirname, env.cht, 'xsl-paths.js'),
},
},
target: 'node',
Expand All @@ -33,7 +33,7 @@ module.exports = env => [
],
output: {
filename: 'cht-form.js',
path: path.join(__dirname, 'dist', env.cht),
path: path.join(__dirname, '../', 'dist', env.cht),
assetModuleFilename: '[name][ext]'
},
resolve: {
Expand Down
41 changes: 20 additions & 21 deletions dist/all-chts-bundle.dev.js

Large diffs are not rendered by default.

2 changes: 1 addition & 1 deletion dist/all-chts-bundle.dev.js.map

Large diffs are not rendered by default.

3 changes: 1 addition & 2 deletions dist/cht-core-4-6/cht-core-bundle.dev.js

Large diffs are not rendered by default.

2 changes: 1 addition & 1 deletion dist/cht-core-4-6/cht-core-bundle.dev.js.map

Large diffs are not rendered by default.

2 changes: 1 addition & 1 deletion webpack.config.js
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@ module.exports = [
mode: 'development'
},
{
entry: './all-chts-bundle.js',
entry: './cht-bundles/all-chts-bundle.js',
output: {
path: path.join(__dirname, 'dist'),
filename: 'all-chts-bundle.dev.js',
Expand Down

0 comments on commit c858286

Please sign in to comment.