Skip to content

Commit 18e8665

Browse files
committed
refactor(ui-scripts): bugfix
1 parent 4b2297b commit 18e8665

File tree

2 files changed

+5
-4
lines changed

2 files changed

+5
-4
lines changed

packages/ui-scripts/lib/build/generate-all-tokens.js

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -91,6 +91,7 @@ export default {
9191
? path.join(themePath, outputDir, themeKey)
9292
: path.join(themePath, outputDir)
9393
const sourcePath = path.join(outputPath, 'source.json')
94+
// this is just a debug code to find the JSON error here that occurs only in CI
9495
// eslint-disable-next-line no-console
9596
console.log(
9697
'!!!!! starting',
@@ -102,8 +103,8 @@ export default {
102103
)
103104
// eslint-disable-next-line no-console
104105
console.log(
105-
'!!!!styleDictionarySource',
106-
JSON.stringify(styleDictionarySource).substring(0, 400)
106+
'!!!! styleDictionarySource',
107+
JSON.stringify(styleDictionarySource)?.substring(0, 400)
107108
)
108109
generators.push(
109110
handleGenerateTokens({

packages/ui-scripts/lib/utils/handle-generate-tokens.js

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -37,10 +37,10 @@ export async function handleGenerateTokens({
3737
fs.mkdirSync(dir, { recursive: true })
3838
}
3939
fs.writeFileSync(sourcePath, JSON.stringify(styleDictionarySource))
40-
//fse.outputFileSync(sourcePath, JSON.stringify(styleDictionarySource))
40+
// this is just a debug code to find the JSON error here that occurs only in CI
4141
// eslint-disable-next-line no-console
4242
console.log(
43-
'!!!!handleGenerateTokens',
43+
'!!!! handleGenerateTokens',
4444
sourcePath,
4545
fs.existsSync(sourcePath),
4646
JSON.stringify(styleDictionarySource)?.substring(0, 400)

0 commit comments

Comments
 (0)