node-library-preset/lib/index.mjs

36 lines
2.4 KiB
JavaScript
Raw Normal View History

chore(release): 0.1.1 [skip ci] ## [0.1.1](https://git.lumeweb.com/LumeWeb/node-library-preset/compare/v0.1.0...v0.1.1) (2023-06-25) ### Bug Fixes * add __dirname compatibility ([60f45cb](https://git.lumeweb.com/LumeWeb/node-library-preset/commit/60f45cb8d544de3c77be90359bdce9ea98422040)) * add .releaserc.json to gitignore ([a892d35](https://git.lumeweb.com/LumeWeb/node-library-preset/commit/a892d3557ee419725cae6ce9f35293d98b6719e4)) * add [@ts-ignore](https://git.lumeweb.com/ts-ignore) to import.meta.url ([bdd2b66](https://git.lumeweb.com/LumeWeb/node-library-preset/commit/bdd2b667250024e4ddfe028726778dba4633312f)) * add dom to ts compiler ([c3c172a](https://git.lumeweb.com/LumeWeb/node-library-preset/commit/c3c172a5bcd878fde5b368f7aa4050cced7971af)) * add ES2021 to ts compiler ([c15b279](https://git.lumeweb.com/LumeWeb/node-library-preset/commit/c15b279d637ac5d76b8d42f1ec83403a9dcf721c)) * add missing files property ([7a1e88e](https://git.lumeweb.com/LumeWeb/node-library-preset/commit/7a1e88e8dc483e50a26eb5a85daf7e42413a0ba3)) * add missing type and main ([9f0cdc2](https://git.lumeweb.com/LumeWeb/node-library-preset/commit/9f0cdc22b635475aa025cdac656e0c31db370af3)) * don't let presetter try to parse the file ([7bb0961](https://git.lumeweb.com/LumeWeb/node-library-preset/commit/7bb09618851891d64b320c4651c545e097d8479d)) * dont symlink ci file ([87afb2c](https://git.lumeweb.com/LumeWeb/node-library-preset/commit/87afb2cc64344dba11c06c4c73ab245547a383a6)) * releaserc missing from templates ([0ba3e5e](https://git.lumeweb.com/LumeWeb/node-library-preset/commit/0ba3e5e5f5ef3fc790a75ff9f8fffb431042bcd1)) * remove peer deps ([23ada98](https://git.lumeweb.com/LumeWeb/node-library-preset/commit/23ada9833711bb1beeed435a0d7960b13da8ba92)) * switch to hybrid building ([7a58630](https://git.lumeweb.com/LumeWeb/node-library-preset/commit/7a58630cdaf69e9830a03ca7c2bc6fecd188a2f0)) * syntax error ([7bba835](https://git.lumeweb.com/LumeWeb/node-library-preset/commit/7bba8356e0ecaa426bb3afcc984607bf21a5474f))
2023-06-25 21:57:08 +00:00
import { resolve } from "node:path";
export const DEFAULT_VARIABLE = {
source: "src",
};
export default async function () {
chore(release): 0.1.1 [skip ci] ## [0.1.1](https://git.lumeweb.com/LumeWeb/node-library-preset/compare/v0.1.0...v0.1.1) (2023-06-25) ### Bug Fixes * add __dirname compatibility ([60f45cb](https://git.lumeweb.com/LumeWeb/node-library-preset/commit/60f45cb8d544de3c77be90359bdce9ea98422040)) * add .releaserc.json to gitignore ([a892d35](https://git.lumeweb.com/LumeWeb/node-library-preset/commit/a892d3557ee419725cae6ce9f35293d98b6719e4)) * add [@ts-ignore](https://git.lumeweb.com/ts-ignore) to import.meta.url ([bdd2b66](https://git.lumeweb.com/LumeWeb/node-library-preset/commit/bdd2b667250024e4ddfe028726778dba4633312f)) * add dom to ts compiler ([c3c172a](https://git.lumeweb.com/LumeWeb/node-library-preset/commit/c3c172a5bcd878fde5b368f7aa4050cced7971af)) * add ES2021 to ts compiler ([c15b279](https://git.lumeweb.com/LumeWeb/node-library-preset/commit/c15b279d637ac5d76b8d42f1ec83403a9dcf721c)) * add missing files property ([7a1e88e](https://git.lumeweb.com/LumeWeb/node-library-preset/commit/7a1e88e8dc483e50a26eb5a85daf7e42413a0ba3)) * add missing type and main ([9f0cdc2](https://git.lumeweb.com/LumeWeb/node-library-preset/commit/9f0cdc22b635475aa025cdac656e0c31db370af3)) * don't let presetter try to parse the file ([7bb0961](https://git.lumeweb.com/LumeWeb/node-library-preset/commit/7bb09618851891d64b320c4651c545e097d8479d)) * dont symlink ci file ([87afb2c](https://git.lumeweb.com/LumeWeb/node-library-preset/commit/87afb2cc64344dba11c06c4c73ab245547a383a6)) * releaserc missing from templates ([0ba3e5e](https://git.lumeweb.com/LumeWeb/node-library-preset/commit/0ba3e5e5f5ef3fc790a75ff9f8fffb431042bcd1)) * remove peer deps ([23ada98](https://git.lumeweb.com/LumeWeb/node-library-preset/commit/23ada9833711bb1beeed435a0d7960b13da8ba92)) * switch to hybrid building ([7a58630](https://git.lumeweb.com/LumeWeb/node-library-preset/commit/7a58630cdaf69e9830a03ca7c2bc6fecd188a2f0)) * syntax error ([7bba835](https://git.lumeweb.com/LumeWeb/node-library-preset/commit/7bba8356e0ecaa426bb3afcc984607bf21a5474f))
2023-06-25 21:57:08 +00:00
let DIR;
if (typeof `${process.platform === 'win32' ? '' : '/'}${/file:\/{2,3}(.+)\/[^/]/.exec(import.meta.url)[1]}` === "undefined") {
DIR = (await import("./path.mjs")).default();
}
else {
DIR = `${process.platform === 'win32' ? '' : '/'}${/file:\/{2,3}(.+)\/[^/]/.exec(import.meta.url)[1]}`;
}
const TEMPLATES = resolve(DIR, "..", "templates");
return {
extends: ["presetter-preset-strict"],
template: {
".github/workflows/ci.yml": resolve(TEMPLATES, "ci.yml.raw"),
".releaserc.json": resolve(TEMPLATES, ".releaserc.json"),
},
noSymlinks: [".github/workflows/ci.yml"],
variable: DEFAULT_VARIABLE,
supplementaryConfig: {
prettier: {
singleQuote: false,
},
gitignore: [".releaserc.json"],
tsconfig: {
compilerOptions: {
lib: ["ES2021", "dom"],
moduleResolution: "nodenext",
},
},
},
};
}
//# sourceMappingURL=data:application/json;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoiaW5kZXguanMiLCJzb3VyY2VSb290IjoiIiwic291cmNlcyI6WyIuLi9zcmMvaW5kZXgudHMiXSwibmFtZXMiOltdLCJtYXBwaW5ncyI6IkFBQUEsT0FBTyxFQUFFLE9BQU8sRUFBRSxNQUFNLFdBQVcsQ0FBQztBQUtwQyxNQUFNLENBQUMsTUFBTSxnQkFBZ0IsR0FBRztJQUM5QixNQUFNLEVBQUUsS0FBSztDQUNkLENBQUM7QUFNRixNQUFNLENBQUMsT0FBTyxDQUFDLEtBQUs7SUFDbEIsSUFBSSxHQUFXLENBQU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