1
0
Fork 0

feat: Generated pkg.mjs files to avoid JSON imports

This commit is contained in:
Joost De Cock 2022-08-29 17:40:04 +02:00
parent 1c5262222f
commit 2bdd5f376e
82 changed files with 330 additions and 1 deletions

View file

@ -0,0 +1,4 @@
// This file is auto-generated | All changes you make will be overwritten.
export const name = "{{{ name }}}"
export const version = "{{ version }}"

4
designs/aaron/pkg.mjs Normal file
View file

@ -0,0 +1,4 @@
// This file is auto-generated | All changes you make will be overwritten.
export const name = "@freesewing/aaron"
export const version = "3.0.0-alpha.0"

4
designs/albert/pkg.mjs Normal file
View file

@ -0,0 +1,4 @@
// This file is auto-generated | All changes you make will be overwritten.
export const name = "@freesewing/albert"
export const version = "3.0.0-alpha.0"

4
designs/bee/pkg.mjs Normal file
View file

@ -0,0 +1,4 @@
// This file is auto-generated | All changes you make will be overwritten.
export const name = "@freesewing/bee"
export const version = "3.0.0-alpha.0"

4
designs/bella/pkg.mjs Normal file
View file

@ -0,0 +1,4 @@
// This file is auto-generated | All changes you make will be overwritten.
export const name = "@freesewing/bella"
export const version = "3.0.0-alpha.0"

4
designs/benjamin/pkg.mjs Normal file
View file

@ -0,0 +1,4 @@
// This file is auto-generated | All changes you make will be overwritten.
export const name = "@freesewing/benjamin"
export const version = "3.0.0-alpha.0"

4
designs/bent/pkg.mjs Normal file
View file

@ -0,0 +1,4 @@
// This file is auto-generated | All changes you make will be overwritten.
export const name = "@freesewing/bent"
export const version = "3.0.0-alpha.0"

4
designs/bob/pkg.mjs Normal file
View file

@ -0,0 +1,4 @@
// This file is auto-generated | All changes you make will be overwritten.
export const name = "@freesewing/bob"
export const version = "3.0.0-alpha.0"

4
designs/breanna/pkg.mjs Normal file
View file

@ -0,0 +1,4 @@
// This file is auto-generated | All changes you make will be overwritten.
export const name = "@freesewing/breanna"
export const version = "3.0.0-alpha.0"

4
designs/brian/pkg.mjs Normal file
View file

@ -0,0 +1,4 @@
// This file is auto-generated | All changes you make will be overwritten.
export const name = "@freesewing/brian"
export const version = "3.0.0-alpha.0"

4
designs/bruce/pkg.mjs Normal file
View file

@ -0,0 +1,4 @@
// This file is auto-generated | All changes you make will be overwritten.
export const name = "@freesewing/bruce"
export const version = "3.0.0-alpha.0"

4
designs/carlita/pkg.mjs Normal file
View file

@ -0,0 +1,4 @@
// This file is auto-generated | All changes you make will be overwritten.
export const name = "@freesewing/carlita"
export const version = "3.0.0-alpha.0"

4
designs/carlton/pkg.mjs Normal file
View file

@ -0,0 +1,4 @@
// This file is auto-generated | All changes you make will be overwritten.
export const name = "@freesewing/carlton"
export const version = "3.0.0-alpha.0"

4
designs/cathrin/pkg.mjs Normal file
View file

@ -0,0 +1,4 @@
// This file is auto-generated | All changes you make will be overwritten.
export const name = "@freesewing/cathrin"
export const version = "3.0.0-alpha.0"

4
designs/charlie/pkg.mjs Normal file
View file

@ -0,0 +1,4 @@
// This file is auto-generated | All changes you make will be overwritten.
export const name = "@freesewing/charlie"
export const version = "3.0.0-alpha.0"

View file

@ -0,0 +1,4 @@
// This file is auto-generated | All changes you make will be overwritten.
export const name = "@freesewing/cornelius"
export const version = "3.0.0-alpha.0"

4
designs/diana/pkg.mjs Normal file
View file

@ -0,0 +1,4 @@
// This file is auto-generated | All changes you make will be overwritten.
export const name = "@freesewing/diana"
export const version = "3.0.0-alpha.0"

4
designs/examples/pkg.mjs Normal file
View file

@ -0,0 +1,4 @@
// This file is auto-generated | All changes you make will be overwritten.
export const name = "@freesewing/examples"
export const version = "3.0.0-alpha.0"

4
designs/florence/pkg.mjs Normal file
View file

@ -0,0 +1,4 @@
// This file is auto-generated | All changes you make will be overwritten.
export const name = "@freesewing/florence"
export const version = "3.0.0-alpha.0"

4
designs/florent/pkg.mjs Normal file
View file

@ -0,0 +1,4 @@
// This file is auto-generated | All changes you make will be overwritten.
export const name = "@freesewing/florent"
export const version = "3.0.0-alpha.0"

4
designs/hi/pkg.mjs Normal file
View file

@ -0,0 +1,4 @@
// This file is auto-generated | All changes you make will be overwritten.
export const name = "@freesewing/hi"
export const version = "3.0.0-alpha.0"

4
designs/holmes/pkg.mjs Normal file
View file

@ -0,0 +1,4 @@
// This file is auto-generated | All changes you make will be overwritten.
export const name = "@freesewing/holmes"
export const version = "3.0.0-alpha.0"

View file

@ -0,0 +1,4 @@
// This file is auto-generated | All changes you make will be overwritten.
export const name = "@freesewing/hortensia"
export const version = "3.0.0-alpha.0"

4
designs/huey/pkg.mjs Normal file
View file

@ -0,0 +1,4 @@
// This file is auto-generated | All changes you make will be overwritten.
export const name = "@freesewing/huey"
export const version = "3.0.0-alpha.0"

4
designs/hugo/pkg.mjs Normal file
View file

@ -0,0 +1,4 @@
// This file is auto-generated | All changes you make will be overwritten.
export const name = "@freesewing/hugo"
export const version = "3.0.0-alpha.0"

4
designs/jaeger/pkg.mjs Normal file
View file

@ -0,0 +1,4 @@
// This file is auto-generated | All changes you make will be overwritten.
export const name = "@freesewing/jaeger"
export const version = "3.0.0-alpha.0"

4
designs/legend/pkg.mjs Normal file
View file

@ -0,0 +1,4 @@
// This file is auto-generated | All changes you make will be overwritten.
export const name = "@freesewing/legend"
export const version = "3.0.0-alpha.0"

4
designs/lucy/pkg.mjs Normal file
View file

@ -0,0 +1,4 @@
// This file is auto-generated | All changes you make will be overwritten.
export const name = "@freesewing/lucy"
export const version = "3.0.0-alpha.0"

4
designs/lunetius/pkg.mjs Normal file
View file

@ -0,0 +1,4 @@
// This file is auto-generated | All changes you make will be overwritten.
export const name = "@freesewing/lunetius"
export const version = "3.0.0-alpha.0"

4
designs/noble/pkg.mjs Normal file
View file

@ -0,0 +1,4 @@
// This file is auto-generated | All changes you make will be overwritten.
export const name = "@freesewing/noble"
export const version = "3.0.0-alpha.0"

View file

@ -0,0 +1,4 @@
// This file is auto-generated | All changes you make will be overwritten.
export const name = "@freesewing/octoplushy"
export const version = "3.0.0-alpha.0"

4
designs/paco/pkg.mjs Normal file
View file

@ -0,0 +1,4 @@
// This file is auto-generated | All changes you make will be overwritten.
export const name = "@freesewing/paco"
export const version = "3.0.0-alpha.0"

4
designs/penelope/pkg.mjs Normal file
View file

@ -0,0 +1,4 @@
// This file is auto-generated | All changes you make will be overwritten.
export const name = "@freesewing/penelope"
export const version = "3.0.0-alpha.0"

View file

@ -0,0 +1,4 @@
// This file is auto-generated | All changes you make will be overwritten.
export const name = "@freesewing/plugintest"
export const version = "3.0.0-alpha.0"

View file

@ -0,0 +1,4 @@
// This file is auto-generated | All changes you make will be overwritten.
export const name = "@freesewing/rendertest"
export const version = "3.0.0-alpha.0"

4
designs/sandy/pkg.mjs Normal file
View file

@ -0,0 +1,4 @@
// This file is auto-generated | All changes you make will be overwritten.
export const name = "@freesewing/sandy"
export const version = "3.0.0-alpha.0"

4
designs/shin/pkg.mjs Normal file
View file

@ -0,0 +1,4 @@
// This file is auto-generated | All changes you make will be overwritten.
export const name = "@freesewing/shin"
export const version = "3.0.0-alpha.0"

4
designs/simon/pkg.mjs Normal file
View file

@ -0,0 +1,4 @@
// This file is auto-generated | All changes you make will be overwritten.
export const name = "@freesewing/simon"
export const version = "3.0.0-alpha.0"

4
designs/simone/pkg.mjs Normal file
View file

@ -0,0 +1,4 @@
// This file is auto-generated | All changes you make will be overwritten.
export const name = "@freesewing/simone"
export const version = "3.0.0-alpha.0"

4
designs/sven/pkg.mjs Normal file
View file

@ -0,0 +1,4 @@
// This file is auto-generated | All changes you make will be overwritten.
export const name = "@freesewing/sven"
export const version = "3.0.0-alpha.0"

4
designs/tamiko/pkg.mjs Normal file
View file

@ -0,0 +1,4 @@
// This file is auto-generated | All changes you make will be overwritten.
export const name = "@freesewing/tamiko"
export const version = "3.0.0-alpha.0"

4
designs/teagan/pkg.mjs Normal file
View file

@ -0,0 +1,4 @@
// This file is auto-generated | All changes you make will be overwritten.
export const name = "@freesewing/teagan"
export const version = "3.0.0-alpha.0"

4
designs/theo/pkg.mjs Normal file
View file

@ -0,0 +1,4 @@
// This file is auto-generated | All changes you make will be overwritten.
export const name = "@freesewing/theo"
export const version = "3.0.0-alpha.0"

4
designs/tiberius/pkg.mjs Normal file
View file

@ -0,0 +1,4 @@
// This file is auto-generated | All changes you make will be overwritten.
export const name = "@freesewing/tiberius"
export const version = "3.0.0-alpha.0"

4
designs/titan/pkg.mjs Normal file
View file

@ -0,0 +1,4 @@
// This file is auto-generated | All changes you make will be overwritten.
export const name = "@freesewing/titan"
export const version = "3.0.0-alpha.0"

4
designs/trayvon/pkg.mjs Normal file
View file

@ -0,0 +1,4 @@
// This file is auto-generated | All changes you make will be overwritten.
export const name = "@freesewing/trayvon"
export const version = "3.0.0-alpha.0"

4
designs/tutorial/pkg.mjs Normal file
View file

@ -0,0 +1,4 @@
// This file is auto-generated | All changes you make will be overwritten.
export const name = "@freesewing/tutorial"
export const version = "3.0.0-alpha.0"

4
designs/unice/pkg.mjs Normal file
View file

@ -0,0 +1,4 @@
// This file is auto-generated | All changes you make will be overwritten.
export const name = "@freesewing/unice"
export const version = "3.0.0-alpha.0"

4
designs/ursula/pkg.mjs Normal file
View file

@ -0,0 +1,4 @@
// This file is auto-generated | All changes you make will be overwritten.
export const name = "@freesewing/ursula"
export const version = "3.0.0-alpha.0"

4
designs/wahid/pkg.mjs Normal file
View file

@ -0,0 +1,4 @@
// This file is auto-generated | All changes you make will be overwritten.
export const name = "@freesewing/wahid"
export const version = "3.0.0-alpha.0"

4
designs/walburga/pkg.mjs Normal file
View file

@ -0,0 +1,4 @@
// This file is auto-generated | All changes you make will be overwritten.
export const name = "@freesewing/walburga"
export const version = "3.0.0-alpha.0"

4
designs/waralee/pkg.mjs Normal file
View file

@ -0,0 +1,4 @@
// This file is auto-generated | All changes you make will be overwritten.
export const name = "@freesewing/waralee"
export const version = "3.0.0-alpha.0"

4
designs/yuri/pkg.mjs Normal file
View file

@ -0,0 +1,4 @@
// This file is auto-generated | All changes you make will be overwritten.
export const name = "@freesewing/yuri"
export const version = "3.0.0-alpha.0"

4
packages/core/pkg.mjs Normal file
View file

@ -0,0 +1,4 @@
// This file is auto-generated | All changes you make will be overwritten.
export const name = "@freesewing/core"
export const version = "3.0.0-alpha.0"

4
packages/i18n/pkg.mjs Normal file
View file

@ -0,0 +1,4 @@
// This file is auto-generated | All changes you make will be overwritten.
export const name = "@freesewing/i18n"
export const version = "3.0.0-alpha.0"

View file

@ -0,0 +1,4 @@
// This file is auto-generated | All changes you make will be overwritten.
export const name = "@freesewing/new-design"
export const version = "3.0.0-alpha.0"

View file

@ -0,0 +1,4 @@
// This file is auto-generated | All changes you make will be overwritten.
export const name = "@freesewing/prettier-config"
export const version = "3.0.0-alpha.0"

View file

@ -0,0 +1,4 @@
// This file is auto-generated | All changes you make will be overwritten.
export const name = "rehype-jargon"
export const version = "3.0.0-alpha.0"

View file

@ -0,0 +1,4 @@
// This file is auto-generated | All changes you make will be overwritten.
export const name = "@freesewing/snapseries"
export const version = "3.0.0-alpha.0"

View file

@ -0,0 +1,4 @@
// This file is auto-generated | All changes you make will be overwritten.
export const name = "@freesewing/plugin-banner"
export const version = "3.0.0-alpha.0"

View file

@ -0,0 +1,4 @@
// This file is auto-generated | All changes you make will be overwritten.
export const name = "@freesewing/plugin-bartack"
export const version = "3.0.0-alpha.0"

View file

@ -0,0 +1,4 @@
// This file is auto-generated | All changes you make will be overwritten.
export const name = "@freesewing/plugin-bundle"
export const version = "3.0.0-alpha.0"

View file

@ -0,0 +1,4 @@
// This file is auto-generated | All changes you make will be overwritten.
export const name = "@freesewing/plugin-bust"
export const version = "3.0.0-alpha.0"

View file

@ -0,0 +1,4 @@
// This file is auto-generated | All changes you make will be overwritten.
export const name = "@freesewing/plugin-buttons"
export const version = "3.0.0-alpha.0"

View file

@ -0,0 +1,4 @@
// This file is auto-generated | All changes you make will be overwritten.
export const name = "@freesewing/plugin-cutonfold"
export const version = "3.0.0-alpha.0"

View file

@ -0,0 +1,4 @@
// This file is auto-generated | All changes you make will be overwritten.
export const name = "@freesewing/plugin-dimension"
export const version = "3.0.0-alpha.0"

View file

@ -0,0 +1,4 @@
// This file is auto-generated | All changes you make will be overwritten.
export const name = "@freesewing/plugin-flip"
export const version = "3.0.0-alpha.0"

View file

@ -0,0 +1,4 @@
// This file is auto-generated | All changes you make will be overwritten.
export const name = "@freesewing/plugin-gore"
export const version = "3.0.0-alpha.0"

View file

@ -0,0 +1,4 @@
// This file is auto-generated | All changes you make will be overwritten.
export const name = "@freesewing/plugin-grainline"
export const version = "3.0.0-alpha.0"

View file

@ -0,0 +1,4 @@
// This file is auto-generated | All changes you make will be overwritten.
export const name = "@freesewing/plugin-i18n"
export const version = "3.0.0-alpha.0"

View file

@ -0,0 +1,4 @@
// This file is auto-generated | All changes you make will be overwritten.
export const name = "@freesewing/plugin-logo"
export const version = "3.0.0-alpha.0"

View file

@ -0,0 +1,4 @@
// This file is auto-generated | All changes you make will be overwritten.
export const name = "@freesewing/plugin-measurements"
export const version = "3.0.0-alpha.0"

View file

@ -0,0 +1,4 @@
// This file is auto-generated | All changes you make will be overwritten.
export const name = "@freesewing/plugin-mirror"
export const version = "3.0.0-alpha.0"

View file

@ -0,0 +1,4 @@
// This file is auto-generated | All changes you make will be overwritten.
export const name = "@freesewing/plugin-notches"
export const version = "3.0.0-alpha.0"

View file

@ -0,0 +1,4 @@
// This file is auto-generated | All changes you make will be overwritten.
export const name = "@freesewing/plugin-round"
export const version = "3.0.0-alpha.0"

View file

@ -0,0 +1,4 @@
// This file is auto-generated | All changes you make will be overwritten.
export const name = "@freesewing/plugin-scalebox"
export const version = "3.0.0-alpha.0"

View file

@ -0,0 +1,4 @@
// This file is auto-generated | All changes you make will be overwritten.
export const name = "@freesewing/plugin-sprinkle"
export const version = "3.0.0-alpha.0"

View file

@ -0,0 +1,4 @@
// This file is auto-generated | All changes you make will be overwritten.
export const name = "@freesewing/plugin-svgattr"
export const version = "3.0.0-alpha.0"

View file

@ -0,0 +1,4 @@
// This file is auto-generated | All changes you make will be overwritten.
export const name = "@freesewing/plugin-theme"
export const version = "3.0.0-alpha.0"

View file

@ -0,0 +1,4 @@
// This file is auto-generated | All changes you make will be overwritten.
export const name = "@freesewing/plugin-title"
export const version = "3.0.0-alpha.0"

View file

@ -0,0 +1,4 @@
// This file is auto-generated | All changes you make will be overwritten.
export const name = "@freesewing/plugin-versionfree-svg"
export const version = "3.0.0-alpha.0"

View file

@ -34,6 +34,7 @@ const repo = {
exceptions: readConfigFile('exceptions.yaml'),
templates: {
pkg: readTemplateFile('package.dflt.json'),
pkgmjs: readTemplateFile('pkg.dflt.mjs'),
changelog: readTemplateFile('changelog.dflt.md'),
readme: readTemplateFile('readme.dflt.md'),
build: readTemplateFile('build.dflt.mjs'),
@ -66,13 +67,17 @@ log.write(chalk.blueBright('Validating configuration...'))
if (validate()) log.write(chalk.green(" Done\n"))
// Step 3: Generate package.json, README, and CHANGELOG
// Step 3: Generate package.json, pkg.mjs, README, and CHANGELOG
log.write(chalk.blueBright('Generating package-specific files...'))
for (const pkg of Object.values(software)) {
fs.writeFileSync(
path.join(cwd, pkg.folder, pkg.name, 'package.json'),
JSON.stringify(packageJson(pkg), null, 2) + '\n'
)
fs.writeFileSync(
path.join(cwd, pkg.folder, pkg.name, 'pkg.mjs'),
mustache.render(repo.templates.pkgmjs, { name: fullName(pkg.name), version })
)
fs.writeFileSync(
path.join(cwd, pkg.folder, pkg.name, 'README.md'),
readme(pkg)