Skip to content

Commit

Permalink
feat(aeria-build): skip codegein if inputs length is 0
Browse files Browse the repository at this point in the history
  • Loading branch information
minenwerfer committed Jun 11, 2024
1 parent af817a4 commit 7f44828
Show file tree
Hide file tree
Showing 2 changed files with 12 additions and 0 deletions.
5 changes: 5 additions & 0 deletions .changeset/happy-singers-impress.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
---
"@aeria-lang/build": patch
---

Skip codegen if inputs length is 0
7 changes: 7 additions & 0 deletions aeria-build/src/filesystem.ts
Original file line number Diff line number Diff line change
Expand Up @@ -70,6 +70,13 @@ export const build = async (patterns: string[], options: BuildOptions) => {

const inputs = await glob(patterns)

if( inputs.length === 0 ) {
return {
success: true,
emittedFiles: [],
}
}

for( const input of inputs ) {
const source = await fs.promises.readFile(input, {
encoding: 'utf-8',
Expand Down

0 comments on commit 7f44828

Please sign in to comment.