Skip to content

Commit

Permalink
fix(TMC-28977): Allow Talend script to build .css files (#5361)
Browse files Browse the repository at this point in the history
Co-authored-by: Geoffroy Baccarini <[email protected]>
  • Loading branch information
Gbacc and Geoffroy Baccarini authored Jun 27, 2024
1 parent 6ae3477 commit 4f8ac2d
Show file tree
Hide file tree
Showing 2 changed files with 7 additions and 2 deletions.
5 changes: 5 additions & 0 deletions .changeset/honest-clouds-think.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
---
"@talend/scripts-core": patch
---

TMC-28977 - Allow Talend scripts to copy .css files on build
4 changes: 2 additions & 2 deletions tools/scripts-core/src/scripts/build-lib.js
Original file line number Diff line number Diff line change
Expand Up @@ -152,7 +152,7 @@ export default async function build(env, presetApi, unsafeOptions) {
const copyPromise = () =>
new Promise((resolve, reject) => {
if (options.includes('--watch')) {
const evtEmitter = cpx.watch(`${srcFolder}/**/*.{scss,json}`, targetFolder);
const evtEmitter = cpx.watch(`${srcFolder}/**/*.{css,scss,json}`, targetFolder);
evtEmitter.on('watch-error', err => {
reject(err);
});
Expand All @@ -161,7 +161,7 @@ export default async function build(env, presetApi, unsafeOptions) {
});
} else {
console.log('Copying assets...');
cpx.copy(`${srcFolder}/**/*.{scss,json}`, targetFolder, err => {
cpx.copy(`${srcFolder}/**/*.{css,scss,json}`, targetFolder, err => {
if (err) {
console.error(err);
reject(err);
Expand Down

0 comments on commit 4f8ac2d

Please sign in to comment.