From 916c4c130570f3305b28400483b0895ea4ba9fd6 Mon Sep 17 00:00:00 2001 From: Bauke Date: Fri, 11 Mar 2022 18:47:38 +0100 Subject: [PATCH] Create a proper directory structure. --- source/{ => 2022/03}/2022-03-06.ts | 4 ++-- source/{ => 2022/03}/2022-03-07.ts | 4 ++-- source/{ => 2022/03}/2022-03-08.ts | 4 ++-- source/{ => 2022/03}/2022-03-09.ts | 4 ++-- source/{ => 2022/03}/2022-03-10.ts | 10 ++++++++-- source/{ => 2022/03}/2022-03-11.ts | 4 ++-- source/2022/03/projects.ts | 19 +++++++++++++++++++ source/2022/projects.ts | 6 ++++++ source/driftingnebula.ts | 18 ++++-------------- 9 files changed, 47 insertions(+), 26 deletions(-) rename source/{ => 2022/03}/2022-03-06.ts (94%) rename source/{ => 2022/03}/2022-03-07.ts (93%) rename source/{ => 2022/03}/2022-03-08.ts (91%) rename source/{ => 2022/03}/2022-03-09.ts (93%) rename source/{ => 2022/03}/2022-03-10.ts (86%) rename source/{ => 2022/03}/2022-03-11.ts (93%) create mode 100644 source/2022/03/projects.ts create mode 100644 source/2022/projects.ts diff --git a/source/2022-03-06.ts b/source/2022/03/2022-03-06.ts similarity index 94% rename from source/2022-03-06.ts rename to source/2022/03/2022-03-06.ts index c3c3057..932046c 100644 --- a/source/2022-03-06.ts +++ b/source/2022/03/2022-03-06.ts @@ -5,8 +5,8 @@ import { SimplexNoise, Softglow, StereographicProjection, -} from './gegl/exports.js'; -import Project from './project.js'; +} from '../../gegl/exports.js'; +import Project from '../../project.js'; const [width, height] = [1920, 1080]; diff --git a/source/2022-03-07.ts b/source/2022/03/2022-03-07.ts similarity index 93% rename from source/2022-03-07.ts rename to source/2022/03/2022-03-07.ts index 88bd293..2cba919 100644 --- a/source/2022-03-07.ts +++ b/source/2022/03/2022-03-07.ts @@ -7,8 +7,8 @@ import { Plasma, Waterpixels, Waves, -} from './gegl/exports.js'; -import Project from './project.js'; +} from '../../gegl/exports.js'; +import Project from '../../project.js'; const [width, height] = [1920, 1080]; diff --git a/source/2022-03-08.ts b/source/2022/03/2022-03-08.ts similarity index 91% rename from source/2022-03-08.ts rename to source/2022/03/2022-03-08.ts index a67e610..fa6242c 100644 --- a/source/2022-03-08.ts +++ b/source/2022/03/2022-03-08.ts @@ -5,8 +5,8 @@ import { Newsprint, StereographicProjection, TileSeamless, -} from './gegl/exports.js'; -import Project from './project.js'; +} from '../../gegl/exports.js'; +import Project from '../../project.js'; const [width, height] = [1920, 1080]; diff --git a/source/2022-03-09.ts b/source/2022/03/2022-03-09.ts similarity index 93% rename from source/2022-03-09.ts rename to source/2022/03/2022-03-09.ts index b145162..d9bef3c 100644 --- a/source/2022-03-09.ts +++ b/source/2022/03/2022-03-09.ts @@ -8,8 +8,8 @@ import { TileSeamless, Waterpixels, Waves, -} from './gegl/exports.js'; -import Project from './project.js'; +} from '../../gegl/exports.js'; +import Project from '../../project.js'; const [width, height] = [1920, 1080]; diff --git a/source/2022-03-10.ts b/source/2022/03/2022-03-10.ts similarity index 86% rename from source/2022-03-10.ts rename to source/2022/03/2022-03-10.ts index 9c1fe3b..dbdbf3e 100644 --- a/source/2022-03-10.ts +++ b/source/2022/03/2022-03-10.ts @@ -1,5 +1,11 @@ -import {CellNoise, Crop, Generic, Newsprint, Waves} from './gegl/exports.js'; -import Project from './project.js'; +import { + CellNoise, + Crop, + Generic, + Newsprint, + Waves, +} from '../../gegl/exports.js'; +import Project from '../../project.js'; const [width, height] = [3840, 2160]; diff --git a/source/2022-03-11.ts b/source/2022/03/2022-03-11.ts similarity index 93% rename from source/2022-03-11.ts rename to source/2022/03/2022-03-11.ts index d8eb250..2db0c70 100644 --- a/source/2022-03-11.ts +++ b/source/2022/03/2022-03-11.ts @@ -5,8 +5,8 @@ import { Newsprint, Plasma, Waterpixels, -} from './gegl/exports.js'; -import Project from './project.js'; +} from '../../gegl/exports.js'; +import Project from '../../project.js'; const [width, height] = [3840, 2160]; diff --git a/source/2022/03/projects.ts b/source/2022/03/projects.ts new file mode 100644 index 0000000..ec3b8f0 --- /dev/null +++ b/source/2022/03/projects.ts @@ -0,0 +1,19 @@ +import Project from '../../project.js'; + +import p2022_03_06 from './2022-03-06.js'; +import p2022_03_07 from './2022-03-07.js'; +import p2022_03_08 from './2022-03-08.js'; +import p2022_03_09 from './2022-03-09.js'; +import p2022_03_10 from './2022-03-10.js'; +import p2022_03_11 from './2022-03-11.js'; + +const projects: Project[] = [ + p2022_03_06, + p2022_03_07, + p2022_03_08, + p2022_03_09, + p2022_03_10, + p2022_03_11, +]; + +export default projects; diff --git a/source/2022/projects.ts b/source/2022/projects.ts new file mode 100644 index 0000000..9683a6d --- /dev/null +++ b/source/2022/projects.ts @@ -0,0 +1,6 @@ +import Project from '../project.js'; +import p2022_03 from './03/projects.js'; + +const projects: Project[] = [...p2022_03]; + +export default projects; diff --git a/source/driftingnebula.ts b/source/driftingnebula.ts index 7269708..3d59975 100644 --- a/source/driftingnebula.ts +++ b/source/driftingnebula.ts @@ -8,12 +8,7 @@ import meow from 'meow'; import {Crop} from './gegl/exports.js'; import Project from './project.js'; -import d2022_03_06 from './2022-03-06.js'; -import d2022_03_07 from './2022-03-07.js'; -import d2022_03_08 from './2022-03-08.js'; -import d2022_03_09 from './2022-03-09.js'; -import d2022_03_10 from './2022-03-10.js'; -import d2022_03_11 from './2022-03-11.js'; +import p2022 from './2022/projects.js'; async function main(): Promise { const cli = meow( @@ -45,14 +40,9 @@ async function main(): Promise { const includeDefaults = cli.flags.includeDefaults; const noRender = !cli.flags.render; - const projects: Project[] = [ - d2022_03_06, - d2022_03_07, - d2022_03_08, - d2022_03_09, - d2022_03_10, - d2022_03_11, - ].filter((project) => project.name.startsWith(cli.flags.filter)); + const projects: Project[] = [...p2022].filter((project) => + project.name.startsWith(cli.flags.filter), + ); for (const { createInputImage,