Skip to content

Commit

Permalink
Switch to Rush monorepo
Browse files Browse the repository at this point in the history
  • Loading branch information
dustinlacewell committed Apr 5, 2023
1 parent 77e39f9 commit bebe536
Show file tree
Hide file tree
Showing 155 changed files with 17,040 additions and 28 deletions.
14 changes: 14 additions & 0 deletions .gitattributes
Original file line number Diff line number Diff line change
@@ -0,0 +1,14 @@
# Don't allow people to merge changes to these generated files, because the result
# may be invalid. You need to run "rush update" again.
pnpm-lock.yaml merge=text
shrinkwrap.yaml merge=binary
npm-shrinkwrap.json merge=binary
yarn.lock merge=binary

# Rush's JSON config files use JavaScript-style code comments. The rule below prevents pedantic
# syntax highlighters such as GitHub's from highlighting these comments as errors. Your text editor
# may also require a special configuration to allow comments in JSON.
#
# For more information, see this issue: https://github.com/microsoft/rushstack/issues/1088
#
*.json linguist-language=JSON-with-Comments
27 changes: 27 additions & 0 deletions .github/workflows/ci.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,27 @@
name: CI
on:
push:
branches: [ "main" ]
pull_request:
branches: [ "main" ]
jobs:
build:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v3
with:
fetch-depth: 2
- name: Git config user
uses: snow-actions/[email protected]
with:
name: # Service Account's Name
email: # Service Account's Email Address
- uses: actions/setup-node@v3
with:
node-version: 16
- name: Verify Change Logs
run: node common/scripts/install-run-rush.js change --verify
- name: Rush Install
run: node common/scripts/install-run-rush.js install
- name: Rush rebuild
run: node common/scripts/install-run-rush.js rebuild --verbose --production
76 changes: 71 additions & 5 deletions .gitignore
Original file line number Diff line number Diff line change
@@ -1,7 +1,73 @@
out
dist
node_modules
.vscode-test/
*.vsix
# Logs
*.log
npm-debug.log*
yarn-debug.log*
yarn-error.log*

# Runtime data
*.pid
*.seed
*.pid.lock

# Directory for instrumented libs generated by jscoverage/JSCover
lib-cov

# Coverage directory used by tools like istanbul
coverage

# nyc test coverage
.nyc_output

# Grunt intermediate storage (http://gruntjs.com/creating-plugins#storing-task-files)
.grunt

# Bower dependency directory (https://bower.io/)
bower_components

# node-waf configuration
.lock-wscript

# Compiled binary addons (https://nodejs.org/api/addons.html)
build/Release

# Dependency directories
node_modules/
jspm_packages/

# Optional npm cache directory
.npm

# Optional eslint cache
.eslintcache

# Optional REPL history
.node_repl_history

# Output of 'npm pack'
*.tgz

# Yarn Integrity file
.yarn-integrity

# dotenv environment variables file
.env

# next.js build output
.next

# OS X temporary files
.DS_Store

# IntelliJ IDEA project files; if you want to commit IntelliJ settings, this recipe may be helpful:
# https://github.com/github/gitignore/blob/main/Global/JetBrains.gitignore
.idea/
*.iml

# Rush temporary files
common/deploy/
common/temp/
common/autoinstallers/*/.npmrc
**/.rush/temp/

# Heft temporary files
.heft
14 changes: 14 additions & 0 deletions .vscode/launch.json
Original file line number Diff line number Diff line change
Expand Up @@ -22,6 +22,20 @@
"port": 9222,
"sourceMaps": true,
"webRoot": "${workspaceFolder}"
},
{
"name": "Launch Extension",
"type": "extensionHost",
"request": "launch",
"cwd": "${workspaceFolder}/apps/spellbound/",
"args": [
"--extensionDevelopmentPath=${workspaceFolder}/apps/spellbound/"
],
"outFiles": [
"${workspaceFolder}/apps/spellbound/dist/**/*.js"
],
// run rushx build in apps/examples/flow-editor first
// "preLaunchTask": "rush build"
}
]
}
8 changes: 7 additions & 1 deletion .vscode/tasks.json
Original file line number Diff line number Diff line change
Expand Up @@ -35,6 +35,12 @@
"npm: watch-tests"
],
"problemMatcher": []
}
},
{
"type": "shell",
"command": "rush build && rush generate-commands",
"label": "rush build",
"problemMatcher": [],
}
]
}
1 change: 1 addition & 0 deletions apps/dist/tsconfig.tsbuildinfo
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
{"program":{"fileNames":["../../common/temp/node_modules/.pnpm/[email protected]/node_modules/typescript/lib/lib.es2021.weakref.d.ts","../spellbound-shared/src/types/message.ts","../spellbound-shared/src/types/index.ts","../spellbound-shared/src/index.ts"],"fileInfos":[{"version":"61ed9b6d07af959e745fb11f9593ecd743b279418cc8a99448ea3cd5f3b3eb22","signature":false,"affectsGlobalScope":true},{"version":"7c97c62e3e88b1e0f2f1d14b2ecc069cebd7157389d9b3accc319e86e288bbf5","signature":false},{"version":"ada6d815711dd01eede464576811d9b8a695d9172965ba51cfd3862f0782a806","signature":false},{"version":"d5c19655468e29f60c871b21e73af8ebc653f736e7123ade916f22c4a5f80ce5","signature":false}],"root":[[2,4]],"options":{"declaration":true,"declarationMap":true,"emitDecoratorMetadata":true,"esModuleInterop":true,"experimentalDecorators":true,"module":1,"noFallthroughCasesInSwitch":true,"noImplicitReturns":true,"outDir":"./","removeComments":true,"skipLibCheck":true,"sourceMap":true,"sourceRoot":"../../../../../src","strict":true,"stripInternal":true,"target":6},"fileIdsList":[[3],[2]],"referencedMap":[[4,1],[3,2]],"exportedModulesMap":[],"changeFileSet":[4,3,2,1]},"version":"5.0.3"}
2 changes: 2 additions & 0 deletions apps/spellbound-shared/dist/index.d.ts
Original file line number Diff line number Diff line change
@@ -0,0 +1,2 @@
export * from './types';
//# sourceMappingURL=index.d.ts.map
1 change: 1 addition & 0 deletions apps/spellbound-shared/dist/index.d.ts.map

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

18 changes: 18 additions & 0 deletions apps/spellbound-shared/dist/index.js

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

1 change: 1 addition & 0 deletions apps/spellbound-shared/dist/index.js.map

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

1 change: 1 addition & 0 deletions apps/spellbound-shared/dist/tsconfig.tsbuildinfo

Large diffs are not rendered by default.

5 changes: 5 additions & 0 deletions apps/spellbound-shared/dist/types/Message.d.ts
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
export type Message = {
role: string;
content: string;
};
//# sourceMappingURL=Message.d.ts.map
1 change: 1 addition & 0 deletions apps/spellbound-shared/dist/types/Message.d.ts.map

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

3 changes: 3 additions & 0 deletions apps/spellbound-shared/dist/types/Message.js

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

1 change: 1 addition & 0 deletions apps/spellbound-shared/dist/types/Message.js.map

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 2 additions & 0 deletions apps/spellbound-shared/dist/types/index.d.ts
Original file line number Diff line number Diff line change
@@ -0,0 +1,2 @@
export * from './Message';
//# sourceMappingURL=index.d.ts.map
1 change: 1 addition & 0 deletions apps/spellbound-shared/dist/types/index.d.ts.map

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

18 changes: 18 additions & 0 deletions apps/spellbound-shared/dist/types/index.js

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

1 change: 1 addition & 0 deletions apps/spellbound-shared/dist/types/index.js.map

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

18 changes: 18 additions & 0 deletions apps/spellbound-shared/package.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,18 @@
{
"name": "spellbound-shared",
"version": "0.0.3",
"description": "",
"main": "dist/index.js",
"scripts": {
"test": "echo \"Error: no test specified\" && exit 1",
"build": "tsc -b"
},
"keywords": [],
"author": "",
"license": "ISC",
"devDependencies": {
"node-rig": "workspace:^0.0.1",
"typescript": "~5.0.3",
"@types/node": "~18.15.11"
}
}
1 change: 1 addition & 0 deletions apps/spellbound-shared/src/index.ts
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
export * from './types';
4 changes: 4 additions & 0 deletions apps/spellbound-shared/src/types/Message.ts
Original file line number Diff line number Diff line change
@@ -0,0 +1,4 @@
export type Message = {
role: string
content: string
}
1 change: 1 addition & 0 deletions apps/spellbound-shared/src/types/index.ts
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
export * from './Message';
3 changes: 3 additions & 0 deletions apps/spellbound-shared/tsconfig.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
{
"extends": "./node_modules/node-rig/profiles/default/tsconfig-base.json",
}
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
9 changes: 5 additions & 4 deletions webview/package.json β†’ apps/spellbound-ui/package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "spellbound-ui",
"version": "0.0.1",
"version": "0.0.3",
"private": true,
"scripts": {
"start": "EXTEND_ESLINT=true react-scripts start",
Expand All @@ -21,11 +21,12 @@
"react-pie-menu": "1.0.0-alpha.4",
"reactflow": "^11.2.0",
"styled-components": "~5.3.9",
"zustand": "^4.1.4"
"zustand": "^4.1.4",
"spellbound-shared": "workspace:^0.0.3"
},
"devDependencies": {
"@trpc/server": "^10.18.0",
"@types/node": "^18.11.5",
"@types/node": "~18.15.11",
"@types/react": "^17.0.37",
"@types/react-dom": "^17.0.11",
"@types/react-pie-menu": "~1.0.0",
Expand All @@ -34,7 +35,7 @@
"react-scripts": "^5.0.1",
"rewire": "^5.0.0",
"sass": "~1.60.0",
"typescript": "^4.8.4"
"typescript": "~5.0.3"
},
"eslintConfig": {
"extends": [
Expand Down
File renamed without changes.
File renamed without changes.
File renamed without changes
File renamed without changes
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
Original file line number Diff line number Diff line change
Expand Up @@ -2,9 +2,8 @@ import { FC } from "react"

import ReactMarkdown from 'react-markdown'

import { Message } from "../../store"

import styles from "./styles.module.scss"
import { Message } from "spellbound-shared"


export type MessageItemProps = {
Expand Down
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
4 changes: 1 addition & 3 deletions webview/src/store.ts β†’ apps/spellbound-ui/src/store.ts
Original file line number Diff line number Diff line change
@@ -1,8 +1,6 @@
import { Message } from 'spellbound-shared';
import { create } from 'zustand';

export type Message =
{ role: string, content: string }


export type DocumentState = {
isThinking: boolean,
Expand Down
File renamed without changes.
File renamed without changes.
Loading

0 comments on commit bebe536

Please sign in to comment.