Skip to content

Commit cdb0e2c

Browse files
hobbescodescoopbri
andauthored
Turborepo (#18)
* refactor: set up initial turbo repo structure WIP * refactor: add typescript-config and ui workspace packages * chore: update configurations * refactor: update css variables and fix rendering issues * refactor: update biome config, fix errors * refactor: update some global styles * refactor: adjust configs * feature(apps): set up base for library * feature(apps): update library to ship valid Garden comp WIP * chore: fix file extensions * refactor: add option for expanding subgardens through props * refactor: add initial garden prop back in * refactor: update default styles * refactor: update calculateNodeHeight to properly handle auto layout * feature: add toggle expand to controls * refactor: adjust logic for expand, add theme to minimap for recursive nodes * fix: properly bundle css with postcss plugin for lib, axe components in web app * refactor(web): simplify demo garden * refactor(web): extract css to globals * refactor(web): update garden styles to use custom layer * fix: revert css changes * refactor(web): update rotating text dynamic style usage * refactor(web): fix layout styles * fix(library): update node heights * chore(bun): update lock file * feature: add logo * refactor(lib): extract individual node React components * chore: reorder exports * feature(lib): add JSON schema support * refactor(lib): update globals css, use type import syntax * refactor(lib): inject css * refactor(lib): adjust name of css file * refactor(web): update visualizer and apply schema edits * refactor(web): only show editor actions in editor tab * refactor(web): persist active garden state to local storage * refactor(web): only load Garden in visualizer on client to pick up proper local storage on render * refactor: isolate shadcn configs, add prefix to lib styles * fix(web): fix build issue * chore: lint and format files * refactor(web): update border color for demo * refactor(lib): ship styles separately for custom override functionality downstream * refactor: update types for GardenProps, update activeGarden --> activeSchema * refactor: remove packages workspace * refactor: isolate dependencies in apps * refactor(lib): add knip config * refactor(knip): enable biome plugins * feature(lib): add changesets support * refactor(cli): update to recursively reference Garden * fix(lib): update handleNodeClick to properly use expandSubgardens default * refactor(Web): adjust tab styles * refactor: add github workflows back in * feature: add husky * fix(changesets): move to root directory * refactor: adjust changesets, add pkg-pr-new dep * refactor: move changesets and pkg-pr-new deps, update knip config * refactor(workflows): update publish workflow * refactor(workflows): update publish workflow * refactor(workflows): update publish workflow * refactor(workflows): update publish workflow * refactor(workflows): update publish workflow * refactor: update changesets configuration * style(features): change arrow directions * refactor(schema): use real Omni offerings * docs(readme): add logo * docs(readme): use semantic HTML * chore(changesets): remove README * chore(library,docs): remove empty README * chore(library): update gitignore * feature(footer): add docs link * refactor(library): adjust item node image sizing * refactor(library): update item dialog images * refactor(nodes): item node -> sprout node * refactor(cli): items -> sprouts * refactor(schema): items -> sprouts * refactor: items -> sprouts in generated types * refactor: items -> sprouts (WIP) * refactor: items -> sprouts (WIP) * refactor: items -> sprouts (WIP) * refactor(schema): make version optional * feature: add Tilt manifest * chore(tilt): format * refactor(lib): update expand subgardens handler * refactor(lib): add dev script for quick iteration testing * feature(hero): add repo CTA * refactor(lib): update node styles * refactor(web): add generated llms.txt route * refactor(lib): remove transition from sprout nodes, update edge spacing * refacotr(lib): updating scaling for subgarden node * chore: update gitignore * refactor: `GardenTypes` -> `GardenSchema` * docs(readme): update docs * refactor: extract common garden graph props * feature: add 'Powered by Garden' badge * docs(readme): center key links --------- Co-authored-by: Brian Cooper <brian@brian-cooper.com> Co-authored-by: Brian Cooper <20056195+coopbri@users.noreply.github.com>
1 parent 5b9e5dc commit cdb0e2c

File tree

149 files changed

+4345
-7802
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

149 files changed

+4345
-7802
lines changed
File renamed without changes.

.changeset/config.json

Lines changed: 8 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -1,10 +1,12 @@
11
{
2-
"$schema": "https://unpkg.com/@changesets/config@2.3.1/schema.json",
2+
"$schema": "https://unpkg.com/@changesets/config@3.1.1/schema.json",
3+
"changelog": [
4+
"@changesets/changelog-github",
5+
{ "repo": "omnidotdev/garden" }
6+
],
7+
"commit": false,
38
"access": "public",
49
"baseBranch": "master",
5-
"changelog": [
6-
"@changesets/changelog-github",
7-
{ "repo": "omnidotdev/garden" }
8-
],
9-
"commit": false
10+
"updateInternalDependencies": "patch",
11+
"ignore": ["@omnidotdev/garden-app"]
1012
}

.github/workflows/publish.yml

Lines changed: 2 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -30,8 +30,7 @@ jobs:
3030
- uses: oven-sh/setup-bun@v2
3131
- name: Install dependencies
3232
run: bun i
33-
working-directory: app
3433
- name: Build package
35-
run: bun --cwd app run build
34+
run: bun run --cwd apps/library build
3635
- name: Publish package
37-
run: bunx --cwd app pkg-pr-new publish
36+
run: bunx pkg-pr-new publish "./apps/library"

.github/workflows/release.yml

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -15,12 +15,11 @@ jobs:
1515
- uses: oven-sh/setup-bun@v2
1616
- name: Install dependencies
1717
run: bun i
18-
working-directory: app
1918
- name: Create release PR or publish package
2019
id: changesets
2120
uses: changesets/action@v1
2221
with:
23-
publish: bun --cwd app release
22+
publish: bun --cwd apps/library release
2423
title: "feature(release): version packages"
2524
commit: "ci(changesets): version packages"
2625
env:

.gitignore

Lines changed: 6 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1 +1,6 @@
1-
/node_modules
1+
node_modules
2+
3+
.turbo
4+
5+
# IDE
6+
.zed

.husky/pre-commit

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
turbo check -- --staged --no-errors-on-unmatched

README.md

Lines changed: 14 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -1,12 +1,14 @@
11
# 🌱 Garden
22

3-
[TODO LOGO + DEMO IMAGE]
3+
<div align="center">
4+
<img src="/apps/web/public/img/logo.png" width="150" />
45

5-
Garden is a specification for modeling an ecosystem (e.g. of products, services) as a directed acyclic graph with unlimited recursion and composability. This repository holds a CLI for generating the JSON schema in `cli`, and visualizer web app in `app`, powered by Next.js.
6+
[Website](https://garden.omni.dev) | [Docs](https://docs.omni.dev/garden/overview)
7+
</div>
68

7-
For a reference implementation, check out the [Omniverse](https://verse.omni.dev) (coming soon).
9+
Garden is a specification for modeling an ecosystem (e.g. of products, services) as a directed graph with unlimited recursion and composability. This repository holds a CLI for generating the JSON schema in `apps/cli`, a library published to `@omnidotdev/garden` in `apps/library`, and a visualizer web app in `apps/web`, powered by Next.js.
810

9-
In the future, a `<Garden />` React component will be created as well as the ability to compose and nest gardens as "subgardens" within a "supergarden".
11+
For a reference implementation, check out the [Omniverse](https://verse.omni.dev).
1012

1113
Garden layouting is currently powered by [ELK](https://rtsys.informatik.uni-kiel.de/elklive), more layouting engines will be supported in the future.
1214

@@ -21,15 +23,15 @@ Garden layouting is currently powered by [ELK](https://rtsys.informatik.uni-kiel
2123

2224
## Generate the Schema
2325

24-
`cd cli`, then `cargo run -- $OUTPUT_FILE`. For example, `cargo run -- ../garden.schema.json`.
26+
`cd apps/cli`, then `cargo run -- $OUTPUT_FILE`. For example, `cargo run -- ../garden.schema.json`.
2527

26-
## Local Development (Web App)
28+
## Local Development (Library and Web App)
2729

2830
The app is a landing page and visualizer for Garden schemas. `cd app`, then continue below.
2931

3032
### Generate Types from Schema
3133

32-
`bun generate`
34+
`cd apps/library && bun generate`
3335

3436
### Building and Running
3537

@@ -38,7 +40,11 @@ bun install
3840
```
3941

4042
```sh
41-
bun run dev
43+
bun turbo build
44+
```
45+
46+
```sh
47+
bun turbo dev
4248
```
4349

4450
## Inspiration

Tiltfile

Lines changed: 16 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,16 @@
1+
local_resource(
2+
'install',
3+
cmd='bun i',
4+
)
5+
6+
7+
local_resource(
8+
'build',
9+
cmd='bun turbo build',
10+
)
11+
12+
13+
local_resource(
14+
'dev',
15+
cmd='bun turbo dev',
16+
)

app/.vscode/settings.json

Lines changed: 0 additions & 4 deletions
This file was deleted.

app/biome.jsonc

Lines changed: 0 additions & 53 deletions
This file was deleted.

0 commit comments

Comments
 (0)