Skip to content

Commit 89c832e

Browse files
committed
Refactor(Dev tools): Create mirror in the Uh-little-less-dum github account.
1 parent fb3e862 commit 89c832e

File tree

14 files changed

+607
-77
lines changed

14 files changed

+607
-77
lines changed

.husky/pre-commit

100644100755
File mode changed.

.husky/prepare-commit-msg

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1 +1 @@
1-
/Users/bigsexy/Desktop/Go/projects/ulld/dumcommit/dum-commit hook $1
1+
/Users/bigsexy/Desktop/Go/projects/dumcommit/dum-commit hook $1

apps/template/__scripts__/syncWithEcosystemPackages/scripts/copyDatabaseSchemaFile.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -25,4 +25,4 @@ fs.writeFileSync(path.join(rootDir, "apps/template/src/database/schema.prisma"),
2525
})
2626

2727
// eslint-disable-next-line no-console -- Just a build script #MoveToLoggerPackage
28-
console.info("Copied database schema to the template app sucessfully.")
28+
console.info("Copied database schema to the template app successfully.")
Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
// Tunnel file will be generated here.
Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,5 @@
11
@tailwind base;
22
@tailwind components;
33
@tailwind utilities;
4+
5+
@use "./generated/index.scss";

buildUtils/buildNotes/main.md

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -9,6 +9,7 @@
99
| `ULLD_TEST_ROOT` | Path to root of template app |
1010
| `ULLD_ADDITIONAL_SOURCES` | Path to additional sources directory as described in the docs. |
1111
| `ULLD_CLI_DEVROOT` | Path to root of Go cli |
12+
| `ULLD_TEST_ROOT` | Path to use for testing against a build output |
1213

1314

1415
### Development Requirements

buildUtils/buildNotes/todo.md

Lines changed: 11 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,9 +1,19 @@
11
# ULLD To-Do
22

33

4+
## When Online
5+
6+
- [ ] Write tests for all package managers and make sure all are passing as that will be pretty much impossible when offline.
7+
48
## Priority
59

6-
- [ ] Create utility scripts to read and right each file in `/Users/bigsexy/Desktop/current/ulld/buildUtils/buildNotes/` similar to the `whenOnline` scripts.
10+
- [ ] Setup `BasePathFs` described [here](https://github.com/spf13/afero#using-afero-for-testing). This is pretty much exactly what we want to accomodate the `targetdir`.
11+
12+
```go
13+
bp := afero.NewBasePathFs(afero.NewOsFs(), "/base/path")
14+
```
15+
16+
- [ ] Create utility scripts to read and write each file in `/Users/bigsexy/Desktop/current/ulld/buildUtils/buildNotes/` similar to the `whenOnline` scripts.
717
- [ ] Cli script to render markdown using the UlldServer throught he cli and display as an independent page, similar to grip.
818

919
---

package.json

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -44,7 +44,8 @@
4444
"prepare": "husky",
4545
"publish-packages": "changeset version && changeset publish",
4646
"publish-packages-full": "turbo run build lint test && changeset version && changeset publish",
47-
"push:subtree": "git subtree push --prefix=apps/template git@github.com:Uh-little-less-dum/template.git --rejoin --squash",
47+
"pull:template": "git subtree pull --prefix=apps/template --squash",
48+
"push:template": "git subtree push --prefix=apps/template template template",
4849
"release": "release-it",
4950
"release:beta": "release-it --preRelease=beta",
5051
"release:beta:no-npm": "release-it --preRelease=beta --no-npm",

packages/build/src/classes/build.ts

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -31,7 +31,6 @@ import { BuildOptionsType } from "../utils/options.js";
3131
import { getInternalTailwindSources } from "../utils/getInternalTailwindSources.js";
3232
import { SlotMap } from "@ulld/configschema/slotMapRootType";
3333
import type { SlotMapOfType } from "@ulld/configschema/slotMapInternalType";
34-
import { todo } from "node:test";
3534

3635
const { prompt } = enq;
3736

packages/configschema/src/developer/componentSchema.ts

Lines changed: 52 additions & 52 deletions
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@ import { z } from "zod";
22
import { transformExportString } from "@ulld/utilities/transformExportString";
33
import { randomUUID } from "node:crypto";
44

5-
const defaultUUID = randomUUID()
5+
const defaultUUID = randomUUID();
66

77
export const embeddableConfigSchema = z
88
.object({
@@ -26,57 +26,57 @@ export const embeddableConfigSchema = z
2626
});
2727

2828
// TODO: Dynamically generate more strict types after the baseline build process is handled. The component slots should be more strict based on the parents type.
29-
export const componentConfigSchema = z
30-
.object({
31-
componentName: z
32-
.string()
33-
.describe("Must start with a capital letter.")
34-
.transform((f) => `${f[0].toUpperCase()}${f.slice(1)}`),
35-
tags: z
36-
.string()
37-
.array()
38-
.describe(
39-
"Help user's find your component both before they install it, and while searching for documentation.",
40-
)
41-
.default([]),
42-
slot: z
43-
.string()
44-
.optional()
45-
.describe(
46-
"This only applys if the component is meant to override an existing slot. All 'slots' in the appConfigSchema exported from @ulld/configschema/main/zod at the slots key will have an accompanying 'subslot' schema exported from @ulld/configschema/subslots/<name of that slot>. This schema will be a record of a specific set of keys unique to that slot, and a path to a component. All of these paths are initially populated by internally developed components, but can be overridden if your plugin defines the initial slot at the developerConfigSchema.slot path, and then overrides one or more subslots unique to that slot. This componentConfigSchema.slot path will be that subslot if it applies. Most components that are embedded in a user's notes, and don't modify the app as a whole do not occupy slots.",
47-
),
48-
export: z
49-
.string()
50-
.describe(
51-
"The path that this component is exported as in your package.json.",
52-
)
53-
.transform(transformExportString),
54-
embeddable: z
55-
.union([embeddableConfigSchema.array(), embeddableConfigSchema])
56-
.optional()
57-
.transform(
58-
(val): undefined | z.output<typeof embeddableConfigSchema>[] =>
59-
!val ? undefined : Array.isArray(val) ? val : [val],
60-
)
61-
.describe(
62-
"This can be an array to apply aliases to the same component. The component won't be imported twice.",
63-
),
64-
exportedPropsName: z.string().optional(),
65-
docsExport: z
66-
.string()
67-
.optional()
68-
.describe(
69-
"The package.json export that points to a .md or .mdx file that provides a quick reference for the component. This should be simple enough to be opened in the command palette in split view. If only docsExport or fullDocsExport is provided, this shorter docsExport is heavily preferred.",
70-
),
71-
fullDocsExport: z
72-
.string()
73-
.optional()
74-
.describe(
75-
"Similar to docsExport, but will be shown when users redirect to an entire page. This markdown can be more complex and include examples, but the components used must only consist of core ULLD components and your plugin, since we don't know what plugins other user's will be using.",
76-
),
77-
componentId: z.string().uuid("Your component id must be a UUID string.").default(defaultUUID)
78-
})
79-
29+
export const componentConfigSchema = z.object({
30+
componentName: z
31+
.string()
32+
.describe("Must start with a capital letter.")
33+
.transform((f) => `${f[0].toUpperCase()}${f.slice(1)}`),
34+
tags: z
35+
.string()
36+
.array()
37+
.describe(
38+
"Help user's find your component both before they install it, and while searching for documentation.",
39+
)
40+
.default([]),
41+
slot: z
42+
.string()
43+
.optional()
44+
.describe(
45+
"This only applys if the component is meant to override an existing slot. All 'slots' in the appConfigSchema exported from @ulld/configschema/main/zod at the slots key will have an accompanying 'subslot' schema exported from @ulld/configschema/subslots/<name of that slot>. This schema will be a record of a specific set of keys unique to that slot, and a path to a component. All of these paths are initially populated by internally developed components, but can be overridden if your plugin defines the initial slot at the developerConfigSchema.slot path, and then overrides one or more subslots unique to that slot. This componentConfigSchema.slot path will be that subslot if it applies. Most components that are embedded in a user's notes, and don't modify the app as a whole do not occupy slots.",
46+
),
47+
export: z
48+
.string()
49+
.describe(
50+
"The path that this component is exported as in your package.json.",
51+
)
52+
.transform(transformExportString),
53+
embeddable: z
54+
.union([embeddableConfigSchema.array(), embeddableConfigSchema])
55+
.optional()
56+
.transform((val): undefined | z.output<typeof embeddableConfigSchema>[] =>
57+
!val ? undefined : Array.isArray(val) ? val : [val],
58+
)
59+
.describe(
60+
"This can be an array to apply aliases to the same component. The component won't be imported twice.",
61+
),
62+
exportedPropsName: z.string().optional(),
63+
docsExport: z
64+
.string()
65+
.optional()
66+
.describe(
67+
"The package.json export that points to a .md or .mdx file that provides a quick reference for the component. This should be simple enough to be opened in the command palette in split view. If only docsExport or fullDocsExport is provided, this shorter docsExport is heavily preferred.",
68+
),
69+
fullDocsExport: z
70+
.string()
71+
.optional()
72+
.describe(
73+
"Similar to docsExport, but will be shown when users redirect to an entire page. This markdown can be more complex and include examples, but the components used must only consist of core ULLD components and your plugin, since we don't know what plugins other user's will be using.",
74+
),
75+
componentId: z
76+
.string()
77+
.uuid("Your component id must be a UUID string.")
78+
.default(defaultUUID),
79+
});
8080

8181
export type EmbeddableConfigSchema = z.infer<typeof embeddableConfigSchema>;
8282
export type BaseAppEmbeddableConfig = {

0 commit comments

Comments
 (0)