replace console.log with nicelog (#1496)
This PR replaces our `console.log` with `nicelog` so that I can more easily grep for errant console.logs. ### Change Type - [x] `internal` — Any other changes that don't affect the published package (will not publish a new version)
This commit is contained in:
parent
0c4174c0b8
commit
a3c39cde4b
22 changed files with 80 additions and 78 deletions
|
@ -9,6 +9,7 @@ import {
|
|||
writeJsonFile,
|
||||
writeStringFile,
|
||||
} from './lib/file'
|
||||
import { nicelog } from './lib/nicelog'
|
||||
|
||||
// We'll need to copy the assets into these folders
|
||||
const PUBLIC_FOLDER_PATHS = [join(BUBLIC_ROOT, 'packages', 'assets')]
|
||||
|
@ -166,7 +167,7 @@ async function copyFonts() {
|
|||
const itemWithoutExtension = item.replace(extension, '')
|
||||
const name = FONT_MAPPING[itemWithoutExtension]
|
||||
if (!name) {
|
||||
console.log('Font mapping not found for', itemWithoutExtension)
|
||||
nicelog('Font mapping not found for', itemWithoutExtension)
|
||||
process.exit(1)
|
||||
}
|
||||
collectedAssetUrls.fonts[name] = `${folderName}/${item}`
|
||||
|
@ -394,18 +395,18 @@ async function writeAssetDeclarationDTSFile(fileName: string, functionName: stri
|
|||
|
||||
// --- RUN
|
||||
async function main() {
|
||||
console.log('Copying icons...')
|
||||
nicelog('Copying icons...')
|
||||
await copyIcons()
|
||||
console.log('Copying embed icons...')
|
||||
nicelog('Copying embed icons...')
|
||||
await copyEmbedIcons()
|
||||
console.log('Copying fonts...')
|
||||
nicelog('Copying fonts...')
|
||||
await copyFonts()
|
||||
console.log('Copying translations...')
|
||||
nicelog('Copying translations...')
|
||||
await copyTranslations()
|
||||
console.log('Writing asset declaration file...')
|
||||
nicelog('Writing asset declaration file...')
|
||||
await writeUrlBasedAssetDeclarationFile()
|
||||
await writeImportBasedAssetDeclarationFile()
|
||||
console.log('Done!')
|
||||
nicelog('Done!')
|
||||
}
|
||||
|
||||
main()
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue