Skip to content

Commit

Permalink
refactor(apps): move all apps into apps directory
Browse files Browse the repository at this point in the history
  • Loading branch information
nekomeowww committed Feb 20, 2025
1 parent 2a3e290 commit 03d74df
Show file tree
Hide file tree
Showing 147 changed files with 319 additions and 703 deletions.
4 changes: 3 additions & 1 deletion .github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -48,7 +48,9 @@ jobs:
run: pnpm run packages:stub

- name: Build
run: pnpm run packages:build
run: |
pnpm run packages:build
pnpm run apps:build
typecheck:
name: Type Check
Expand Down
18 changes: 9 additions & 9 deletions .github/workflows/deploy-huggingface-spaces.yml
Original file line number Diff line number Diff line change
Expand Up @@ -16,19 +16,19 @@ jobs:
lfs: true

- run: |-
git clone https://$HF_USERNAME:$HF_TOKEN@huggingface.co/spaces/moeru-ai/moonshine-web-vue --depth 1 packages/moonshine-web/dist
git clone https://$HF_USERNAME:$HF_TOKEN@huggingface.co/spaces/moeru-ai/moonshine-web-vue --depth 1 apps/moonshine-web/dist
env:
HF_TOKEN: ${{ secrets.HF_TOKEN }}
HF_USERNAME: ${{ secrets.HF_USERNAME }}
- run: |-
git clone https://$HF_USERNAME:$HF_TOKEN@huggingface.co/spaces/moeru-ai/whisper-webgpu-vue --depth 1 packages/whisper-webgpu/dist
git clone https://$HF_USERNAME:$HF_TOKEN@huggingface.co/spaces/moeru-ai/whisper-webgpu-vue --depth 1 apps/whisper-webgpu/dist
env:
HF_TOKEN: ${{ secrets.HF_TOKEN }}
HF_USERNAME: ${{ secrets.HF_USERNAME }}
- run: |-
git clone https://$HF_USERNAME:$HF_TOKEN@huggingface.co/spaces/moeru-ai/airi --depth 1 packages/stage-web/dist
git clone https://$HF_USERNAME:$HF_TOKEN@huggingface.co/spaces/moeru-ai/airi --depth 1 apps/stage-web/dist
env:
HF_TOKEN: ${{ secrets.HF_TOKEN }}
HF_USERNAME: ${{ secrets.HF_USERNAME }}
Expand All @@ -46,7 +46,7 @@ jobs:
VITE_APP_TARGET_HUGGINGFACE_SPACE: 'true'

- id: moonshine_web_diff
working-directory: ./packages/moonshine-web/dist
working-directory: ./apps/moonshine-web/dist
run: |-
git lfs ls-files --all
git add .
Expand All @@ -55,7 +55,7 @@ jobs:
fi
- if: steps.moonshine_web_diff.outputs.changes == 'true'
working-directory: ./packages/moonshine-web/dist
working-directory: ./apps/moonshine-web/dist
env:
HF_TOKEN: ${{ secrets.HF_TOKEN }}
HF_USERNAME: ${{ secrets.HF_USERNAME }}
Expand All @@ -67,7 +67,7 @@ jobs:
git push -f
- id: whisper_webgpu_diff
working-directory: ./packages/whisper-webgpu/dist
working-directory: ./apps/whisper-webgpu/dist
run: |-
git lfs ls-files --all
git add .
Expand All @@ -76,7 +76,7 @@ jobs:
fi
- if: steps.whisper_webgpu_diff.outputs.changes == 'true'
working-directory: ./packages/whisper-webgpu/dist
working-directory: ./apps/whisper-webgpu/dist
env:
HF_TOKEN: ${{ secrets.HF_TOKEN }}
HF_USERNAME: ${{ secrets.HF_USERNAME }}
Expand All @@ -88,7 +88,7 @@ jobs:
git push -f
- id: airi_diff
working-directory: ./packages/stage-web/dist
working-directory: ./apps/stage-web/dist
run: |-
git lfs ls-files --all
git add .
Expand All @@ -97,7 +97,7 @@ jobs:
fi
- if: steps.airi_diff.outputs.changes == 'true'
working-directory: ./packages/stage-web/dist
working-directory: ./apps/stage-web/dist
env:
HF_TOKEN: ${{ secrets.HF_TOKEN }}
HF_USERNAME: ${{ secrets.HF_USERNAME }}
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/release-tamagotchi.yml
Original file line number Diff line number Diff line change
Expand Up @@ -69,7 +69,7 @@ jobs:
run: pnpm install --frozen-lockfile

- name: Build Dependencies
run: pnpm run build
run: pnpm run packages:build

- name: Build Application
run: pnpm run -F @proj-airi/stage-tamagotchi build:${{ matrix.platform }}
Expand Down
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
@@ -1,6 +1,6 @@
[build]
publish = "packages/moonshine-web/dist"
command = "pnpm run packages:stub && pnpm run build"
publish = "apps/moonshine-web/dist"
command = "pnpm run packages:stub && pnpm -F @proj-airi/moonshine-web run build"

[build.environment]
NODE_VERSION = "23"
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.
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
File renamed without changes.
File renamed without changes.
Original file line number Diff line number Diff line change
Expand Up @@ -16,8 +16,8 @@ export default defineConfig({
resolve: {
alias: {
'@renderer': resolve(join('src', 'renderer', 'src')),
'@proj-airi/stage-ui': resolve(join(import.meta.dirname, '..', 'stage-ui', 'dist')),
'@proj-airi/stage-ui/stores': resolve(join(import.meta.dirname, '..', 'stage-ui', 'dist', 'stores')),
'@proj-airi/stage-ui': resolve(join(import.meta.dirname, '..', '..', 'packages', 'stage-ui', 'dist')),
'@proj-airi/stage-ui/stores': resolve(join(import.meta.dirname, '..', '..', 'packages', 'stage-ui', 'dist', 'stores')),
},
},
plugins: [
Expand Down
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 @@ -12,7 +12,7 @@
"./src/renderer/src/*"
],
"@proj-airi/stage-ui/*": [
"../stage-ui/src/*"
"../../packages/stage-ui/src/*"
]
}
},
Expand All @@ -21,6 +21,6 @@
"src/renderer/src/**/*",
"src/renderer/src/**/*.vue",
"src/preload/*.d.ts",
"../stage-ui/src/**/*.ts" // REVIEW: why?
"../../packages/stage-ui/src/**/*.ts" // REVIEW: why?
]
}
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
@@ -1,6 +1,6 @@
[build]
publish = "packages/stage-web/dist"
command = "pnpm run packages:stub && pnpm run build"
publish = "apps/stage-web/dist"
command = "pnpm run packages:stub && pnpm -F @proj-airi/stage-web run build"

[build.environment]
NODE_VERSION = "23"
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.
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.
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 @@ -8,7 +8,7 @@
],
"paths": {
"@proj-airi/stage-ui/*": [
"../stage-ui/src/*"
"../../packages/stage-ui/src/*"
]
},
"resolveJsonModule": true,
Expand Down
File renamed without changes.
File renamed without changes.
Original file line number Diff line number Diff line change
Expand Up @@ -53,8 +53,8 @@ export default defineConfig({

resolve: {
alias: {
'@proj-airi/stage-ui': resolve(join(import.meta.dirname, '..', 'stage-ui', 'dist')),
'@proj-airi/stage-ui/stores': resolve(join(import.meta.dirname, '..', 'stage-ui', 'dist', 'stores')),
'@proj-airi/stage-ui': resolve(join(import.meta.dirname, '..', '..', 'packages', 'stage-ui', 'dist')),
'@proj-airi/stage-ui/stores': resolve(join(import.meta.dirname, '..', '..', 'packages', 'stage-ui', 'dist', 'stores')),
},
},

Expand Down
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
@@ -1,6 +1,6 @@
[build]
publish = "packages/whisper-webgpu/dist"
command = "pnpm run packages:stub && pnpm run build"
publish = "apps/whisper-webgpu/dist"
command = "pnpm run packages:stub && pnpm -F @proj-airi/whisper-webgpu run build"

[build.environment]
NODE_VERSION = "23"
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.
File renamed without changes.
File renamed without changes.
File renamed without changes.
30 changes: 17 additions & 13 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -11,20 +11,23 @@
},
"license": "MIT",
"scripts": {
"lint": "eslint --cache .",
"lint:fix": "eslint --cache --fix .",
"typecheck": "pnpm -r --filter=./packages/* run typecheck",
"dev": "pnpm packages:dev",
"build": "pnpm packages:build",
"packages:dev": "pnpm packages:stub && pnpm -r --filter=./packages/* --parallel run dev",
"packages:dev:tamagotchi": "pnpm packages:stub && pnpm -r --filter=@proj-airi/stage-tamagotchi --parallel run dev",
"packages:stub": "pnpm -r --filter=./packages/* run stub",
"packages:build": "pnpm -r --filter=./packages/* run build",
"postinstall": "npx simple-git-hooks",
"dev": "pnpm -r --filter './packages/*' --filter './apps/*' run --parallel dev",
"build": "pnpm -r --filter './packages/*' --filter './apps/*' run build",
"apps:dev": "pnpm packages:stub && pnpm -r --filter './apps/*' run --parallel dev",
"apps:tamagotchi:dev": "pnpm packages:stub && pnpm -r --filter=@proj-airi/stage-tamagotchi run dev",
"apps:tamagotchi:build": "pnpm packages:build && pnpm -r --filter=@proj-airi/stage-tamagotchi run build",
"apps:build": "pnpm packages:build && pnpm -r --filter './apps/*' run build",
"packages:dev": "pnpm packages:stub && pnpm -r --filter './packages/*' --parallel run dev",
"packages:stub": "pnpm -r --filter './packages/*' run --parallel stub",
"packages:build": "pnpm -r --filter './packages/*' run build",
"test": "vitest --coverage",
"test:run": "vitest run",
"up": "taze major -I",
"postinstall": "npx simple-git-hooks",
"sizecheck": "npx vite-bundle-visualizer"
"lint": "eslint --cache .",
"lint:fix": "eslint --cache --fix .",
"typecheck": "pnpm -r --filter './packages/*' --filter './apps/*' --filter run --parallel typecheck",
"sizecheck": "npx vite-bundle-visualizer",
"up": "taze major -I"
},
"devDependencies": {
"@antfu/eslint-config": "^4.2.1",
Expand Down Expand Up @@ -54,7 +57,8 @@
"packages/**",
"services/**",
"examples/**",
"docs/**"
"docs/**",
"apps/**"
],
"pnpm": {
"neverBuiltDependencies": []
Expand Down
24 changes: 0 additions & 24 deletions packages/stage-tamagotchi/src/typed-router.d.ts

This file was deleted.

Loading

0 comments on commit 03d74df

Please sign in to comment.