fix: ignore hidden files in scss/themes (#1696)

When editing a theme file in vim, a .file.swp file is created and would
crash the sass compiler. This ignores any hidden files in the directory,
since they are probably not theme files.

Co-authored-by: Milan <me@petabyteboy.de>
This commit is contained in:
Nolan Lawson 2020-01-12 10:19:29 -08:00 committed by GitHub
parent a4b743caf7
commit abaa9b4e05
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
1 changed files with 1 additions and 1 deletions

View File

@ -28,7 +28,7 @@ async function compileGlobalSass () {
}
async function compileThemesSass () {
const files = (await readdir(themesScssDir)).filter(file => !path.basename(file).startsWith('_'))
const files = (await readdir(themesScssDir)).filter(file => !path.basename(file).startsWith('_') && !path.basename(file).startsWith('.'))
await Promise.all(files.map(async file => {
let css = await renderCss(path.join(themesScssDir, file))
css = cssDedoupe(new TextDecoder('utf-8').decode(css)) // remove duplicate custom properties