Skip to content

Commit

Permalink
monorepo化
Browse files Browse the repository at this point in the history
  • Loading branch information
takejohn committed Jan 22, 2025
1 parent 03f83e6 commit e86cfcb
Show file tree
Hide file tree
Showing 27 changed files with 119 additions and 88 deletions.
2 changes: 1 addition & 1 deletion .github/workflows/publish.yml
Original file line number Diff line number Diff line change
Expand Up @@ -34,7 +34,7 @@ jobs:
run: pnpm run build

- name: Publish
run: pnpm publish --no-git-checks --access public
run: pnpm --filter=aisenv publish --no-git-checks --access=public
env:
NPM_CONFIG_PROVENANCE: true
NODE_AUTH_TOKEN: ${{ secrets.NPM_TOKEN }}
2 changes: 0 additions & 2 deletions .gitignore
Original file line number Diff line number Diff line change
@@ -1,3 +1 @@
/node_modules
/built
/coverage
1 change: 0 additions & 1 deletion .npmrc

This file was deleted.

1 change: 0 additions & 1 deletion eslint.config.js
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,6 @@ import tseslint from 'typescript-eslint';
import eslintConfigPrettier from 'eslint-config-prettier';

export default tseslint.config({
files: ['src/**/*.ts'],
extends: [
eslint.configs.recommended,
tseslint.configs.recommended,
Expand Down
57 changes: 13 additions & 44 deletions package.json
Original file line number Diff line number Diff line change
@@ -1,57 +1,26 @@
{
"name": "aisenv",
"version": "0.3.2",
"description": "Build your AiScript development environment.",
"name": "aisenv-monorepo",
"description": "The monorepo of aisenv.",
"type": "module",
"repository": {
"type": "git",
"url": "git+https://github.com/aisenv-dev/aisenv.git"
},
"bugs": "https://github.com/aisenv-dev/aisenv/issues",
"exports": {
".": {
"import": "./built/esm/index.js",
"types": "./built/dts/index.d.ts"
}
},
"private": true,
"scripts": {
"dev": "tsx src/cli/index.ts",
"format": "prettier --write src/**/*.ts tests/**/*.ts *.json *.js",
"format-check": "prettier --check src/**/*.ts tests/**/*.ts *.json *.js",
"lint": "eslint --fix .",
"lint-check": "eslint .",
"typecheck": "tsc --noEmit",
"test": "vitest run",
"build": "tsc"
"format": "pnpm run root:format && pnpm --filter=aisenv format",
"format-check": "pnpm run root:format-check && pnpm --filter=aisenv format-check",
"lint": "pnpm --filter=aisenv run lint",
"lint-check": "pnpm --filter=aisenv run lint-check",
"typecheck": "pnpm --filter=aisenv run typecheck",
"test": "pnpm --filter=aisenv run test",
"build": "pnpm --filter=aisenv run build",
"root:format": "prettier --write *.{js,json}",
"root:format-check": "prettier --write *.{js,json}"
},
"bin": {
"aisenv": "built/esm/cli/index.js"
},
"files": [
"package.json",
"README.md",
"LICENSE",
"built"
],
"keywords": [],
"author": "Take-John",
"license": "MIT",
"devDependencies": {
"@eslint/js": "^9.17.0",
"@types/mock-fs": "^4.13.4",
"@types/node": "^22.10.2",
"@vitest/coverage-v8": "2.1.8",
"eslint": "^9.17.0",
"eslint-config-prettier": "^9.1.0",
"mock-fs": "^5.4.1",
"prettier": "^3.4.2",
"tsx": "^4.19.2",
"typescript": "^5.7.2",
"typescript-eslint": "^8.18.1",
"vitest": "^2.1.8"
},
"dependencies": {
"@syuilo/aiscript": "^0.19.0",
"glob": "^11.0.0"
"typescript-eslint": "^8.18.1"
}
}
3 changes: 3 additions & 0 deletions packages/aisenv/.gitignore
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
/node_modules
/built
/coverage
7 changes: 7 additions & 0 deletions packages/aisenv/eslint.config.js
Original file line number Diff line number Diff line change
@@ -0,0 +1,7 @@
import { config } from 'typescript-eslint';
import rootConfig from '../../eslint.config.js';

export default config({
files: ['src/**/*.ts'],
extends: rootConfig,
});
52 changes: 52 additions & 0 deletions packages/aisenv/package.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,52 @@
{
"name": "aisenv",
"version": "0.3.2",
"description": "Build your AiScript development environment.",
"type": "module",
"repository": {
"type": "git",
"url": "git+https://github.com/aisenv-dev/aisenv.git"
},
"bugs": "https://github.com/aisenv-dev/aisenv/issues",
"exports": {
".": {
"import": "./built/esm/index.js",
"types": "./built/dts/index.d.ts"
}
},
"scripts": {
"dev": "tsx src/cli/index.ts",
"format": "prettier --write src/**/*.ts tests/**/*.ts *.json *.js",
"format-check": "prettier --check src/**/*.ts tests/**/*.ts *.json *.js",
"lint": "eslint --fix .",
"lint-check": "eslint .",
"typecheck": "tsc --noEmit",
"test": "vitest run",
"build": "tsc"
},
"bin": {
"aisenv": "built/esm/cli/index.js"
},
"files": [
"package.json",
"README.md",
"LICENSE",
"built"
],
"keywords": [],
"author": "Take-John",
"license": "MIT",
"devDependencies": {
"@types/mock-fs": "^4.13.4",
"@types/node": "^22.10.2",
"@vitest/coverage-v8": "2.1.8",
"mock-fs": "^5.4.1",
"tsx": "^4.19.2",
"typescript": "^5.7.2",
"vitest": "^2.1.8"
},
"dependencies": {
"@syuilo/aiscript": "^0.19.0",
"glob": "^11.0.0"
}
}
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.
81 changes: 42 additions & 39 deletions pnpm-lock.yaml

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

1 change: 1 addition & 0 deletions pnpm-workspace.yaml
Original file line number Diff line number Diff line change
@@ -1,2 +1,3 @@
packages:
- 'packages/*'
- 'examples/*'

0 comments on commit e86cfcb

Please sign in to comment.