Skip to content

Commit

Permalink
No commit message
Browse files Browse the repository at this point in the history
  • Loading branch information
NikolaRHristov committed Sep 9, 2024
1 parent e6b969e commit 7855a87
Show file tree
Hide file tree
Showing 4 changed files with 13 additions and 5 deletions.
14 changes: 10 additions & 4 deletions Source/Function/Build.ts
Original file line number Diff line number Diff line change
Expand Up @@ -10,13 +10,17 @@ export default (async (...[File, Option]: Parameters<Interface>) => {
for (const _File of File) {
for (const __File of await (
await import("fast-glob")
).default(_File.replaceAll("'", "").replaceAll('"', ""))) {
).default(_File.replaceAll("'", "").replaceAll('"', ""), {
ignore: Option?.Exclude ?? [],
})) {
Pipe.push(__File);
}
}

Pipe.reverse();

console.log(Pipe);

let Configuration: BuildOptions = Merge(
(await import("../Variable/ESBuild.js")).default,
{
Expand All @@ -30,18 +34,20 @@ export default (async (...[File, Option]: Parameters<Interface>) => {
File,
]),
),
tsconfig: Option?.TypeScript ?? "tsconfig.json",
},
);

Configuration = Option?.ESBuild

Configuration = Merge(Option?.ESBuild
? Merge(
Configuration,
await (
await import("@Function/File.js")
).default(Option.ESBuild),
)
: Configuration;
: Configuration, {
tsconfig: Option?.TypeScript ?? "tsconfig.json",
});

Configuration.plugins?.push({
name: "TypeScript",
Expand Down
1 change: 1 addition & 0 deletions Source/Interface/Build.ts
Original file line number Diff line number Diff line change
Expand Up @@ -21,6 +21,7 @@ export default interface Interface {
ESBuild?: string;
TypeScript?: string;
Watch?: boolean;
Exclude?: Pattern[];
},
): Promise<void>;
}
Expand Down
2 changes: 1 addition & 1 deletion Target/Function/Build.js

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

1 change: 1 addition & 0 deletions Target/Interface/Build.d.ts
Original file line number Diff line number Diff line change
Expand Up @@ -19,6 +19,7 @@ export default interface Interface {
ESBuild?: string;
TypeScript?: string;
Watch?: boolean;
Exclude?: Pattern[];
}): Promise<void>;
}
import type { Pattern } from "fast-glob";

0 comments on commit 7855a87

Please sign in to comment.