feat(bases): migrate from vault to upstream

Signed-off-by: Aaron Pham <contact@aarnphm.xyz>
This commit is contained in:
Aaron Pham
2026-01-30 02:25:53 -05:00
parent ec00a40aef
commit dba5a9c920
46 changed files with 7288 additions and 15 deletions

View File

@@ -7,8 +7,12 @@ import { Argv } from "../../util/ctx"
import { QuartzConfig } from "../../cfg"
const filesToCopy = async (argv: Argv, cfg: QuartzConfig) => {
// glob all non MD files in content folder and copy it over
return await glob("**", argv.directory, ["**/*.md", ...cfg.configuration.ignorePatterns])
// glob all non MD/base files in content folder and copy it over
return await glob("**", argv.directory, [
"**/*.md",
"**/*.base",
...cfg.configuration.ignorePatterns,
])
}
const copyFile = async (argv: Argv, fp: FilePath) => {
@@ -37,7 +41,7 @@ export const Assets: QuartzEmitterPlugin = () => {
async *partialEmit(ctx, _content, _resources, changeEvents) {
for (const changeEvent of changeEvents) {
const ext = path.extname(changeEvent.path)
if (ext === ".md") continue
if (ext === ".md" || ext === ".base") continue
if (changeEvent.type === "add" || changeEvent.type === "change") {
yield copyFile(ctx.argv, changeEvent.path)