Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
63 changes: 63 additions & 0 deletions .github/workflows/semantic-pull-request.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,63 @@
name: Semantic Pull Request

on:
pull_request:
types:
- opened
- reopened
- edited

concurrency:
group: ${{ github.workflow }}-${{ github.ref }}-${{ github.event.number }}
cancel-in-progress: true

jobs:
main:
name: Check Pull Request Title
runs-on: ubuntu-latest
steps:
- uses: amannn/[email protected]
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
with:
# see https://github.com/angular/angular/blob/22b96b9/CONTRIBUTING.md#type
types: |
build
ci
docs
feat
fix
perf
refactor
style
test
chore
# idl: idl
# infra:
# - go version update, lint, database, etc
# - rush update, {eslint,ts,vitest}-config, prettier etc
# frontend
# backend
# workflow: gh workflow
# prompt, evaluation, trace, model, dataset, foundation
scopes: |
idl
frontend
backend
infra
workflow
prompt
evaluation
trace
model
dataset
foundation
# The pull request's title should be fulfilled the following pattern:
#
# [<type>][<optional scope>] <description>
#
# ... where valid types and scopes can be found above; for example:
#
# [fix][test] flaky test V1_ProxyAuthenticationTest.anonymousSocketTest
headerPattern: '^\[(\w*?)\](?:\[(.*?)\])?(?:\s*)(.*)$'
headerPatternCorrespondence: type, scope, subject
7 changes: 3 additions & 4 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -25,9 +25,6 @@ output/
.idea/
*.iml

# Vscode files
.vscode/

# MacOS files
**/.DS_Store

Expand All @@ -41,5 +38,7 @@ log/
**/tmp/
**/temp/

# node modules
node_modules/
.eslintcache

.eslintcache
20 changes: 20 additions & 0 deletions .vscode/extensions.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,20 @@
{
"recommendations": [
"cpylua.language-postcss",
"editorconfig.editorconfig",
"esbenp.prettier-vscode",
"mkaufman.htmlhint",
"streetsidesoftware.code-spell-checker",
"codezombiech.gitignore",
"aaron-bond.better-comments",
"jasonnutter.search-node-modules",
"jock.svg",
"mikestead.dotenv",
"foxundermoon.shell-format",
"stylelint.vscode-stylelint"
],
"unwantedRecommendations": [
"nucllear.vscode-extension-auto-import",
"steoates.autoimport"
]
}
181 changes: 181 additions & 0 deletions .vscode/settings.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,181 @@
{
"eslint.nodePath": "frontend/config/eslint-config/node_modules/eslint",
"prettier.prettierPath": "frontend/config/eslint-config/node_modules/prettier",
"editor.tabSize": 2,
"editor.insertSpaces": true,
"editor.formatOnSave": true,
"editor.formatOnType": false,
"editor.formatOnPaste": false,
"editor.defaultFormatter": "esbenp.prettier-vscode",
"editor.codeActionsOnSave": {
"source.fixAll": "never",
"source.fixAll.eslint": "never",
"source.removeUnused": "never",
"source.organizeImports": "never"
},
"editor.formatOnSaveMode": "modificationsIfAvailable",
"search.followSymlinks": false,
"search.exclude": {
"**/node_modules": true,
"**/.nyc_output": true,
"**/.rush": true,
"**/pnpm-lock.yaml": true,
"**/CHANGELOG.json": true,
"**/CHANGELOG.md": true,
"common/changes": true,
"**/output": true,
"**/lib": true,
"**/rush-logs": true,
"**/dist": true,
"**/coverage": true,
"common/temp": true
},
"eslint.workingDirectories": [
{
"mode": "auto"
}
],
"files.defaultLanguage": "plaintext",
"files.associations": {
".code-workspace": "jsonc",
".babelrc": "json",
".eslintrc": "jsonc",
".eslintrc*.json": "jsonc",
".stylelintrc": "javascript",
"stylelintrc": "jsonc",
"*.json": "jsonc",
"package.json": "json",
".htmlhintrc": "jsonc",
"htmlhintrc": "jsonc",
"Procfile*": "shellscript",
"README": "markdown",
"**/coverage/**/*.*": "plaintext",
"OWNERS": "yaml",
"**/pnpm-lock.yaml": "plaintext",
"**/dist/**": "plaintext",
"**/dist_*/**": "plaintext",
"*.map": "plaintext",
"*.log": "plaintext"
},
"files.exclude": {
"**/.git": true,
"**/rush-logs": true,
"**/.svn": true,
"**/.hg": true,
"**/CVS": true,
"**/.DS_Store": true,
"**/Thumbs.db": true,
"**/.rush": true,
"**/.swc": true
},
"files.watcherExclude": {
"**/.git/objects/**": true,
"**/.git/subtree-cache/**": true,
"**/node_modules/*/**": true
},
"search.useIgnoreFiles": true,
//
"editor.rulers": [80, 120],
"files.eol": "\n",
"files.trimTrailingWhitespace": true,
"files.insertFinalNewline": true,
"cSpell.diagnosticLevel": "Warning",
"eslint.probe": [
"javascript",
"javascriptreact",
"typescript",
"typescriptreact"
],
"editor.semanticHighlighting.enabled": false,
"eslint.format.enable": false,
"eslint.enable": true,
"eslint.useFlatConfig": true,
"eslint.codeActionsOnSave.mode": "problems",
"eslint.lintTask.enable": false,
"javascript.validate.enable": false,
"typescript.tsdk": "config/ts-config/node_modules/typescript/lib",
"typescript.enablePromptUseWorkspaceTsdk": true,
"typescript.disableAutomaticTypeAcquisition": true,
"typescript.format.enable": false,
"typescript.referencesCodeLens.enabled": false,
"typescript.preferGoToSourceDefinition": true,
"typescript.updateImportsOnFileMove.enabled": "never",
"typescript.tsserver.log": "off",
"typescript.tsserver.experimental.enableProjectDiagnostics": false,
"typescript.workspaceSymbols.excludeLibrarySymbols": true,
"editor.minimap.enabled": true,
"typescript.preferences.includePackageJsonAutoImports": "off",
"typescript.suggest.autoImports": true,
"typescript.tsserver.maxTsServerMemory": 10240,
"typescript.tsserver.enableRegionDiagnostics": false,
"typescript.tsserver.watchOptions": {
"fallbackPolling": "dynamicPriorityPolling",
"synchronousWatchDirectory": true,
"watchDirectory": "useFsEvents",
"watchFile": "useFsEventsOnParentDirectory",
"excludeDirectories": ["/**/node_modules"],
"excludeLibrarySymbols": true,
"excludeFiles": ["/**/node_modules/**"]
},
"css.validate": false,
"scss.validate": false,
"less.validate": false,
"stylelint.enable": true,
"stylelint.validate": ["css", "scss", "less"],
"stylelint.stylelintPath": "frontend/config/stylelint-config/node_modules/stylelint",
"emmet.triggerExpansionOnTab": true,
"[typescript]": {
"editor.defaultFormatter": "esbenp.prettier-vscode"
},
"[yaml]": {
"editor.defaultFormatter": "esbenp.prettier-vscode"
},
"[css]": {
"editor.defaultFormatter": "esbenp.prettier-vscode"
},
"[html]": {
"editor.defaultFormatter": "esbenp.prettier-vscode"
},
"[javascript]": {
"editor.defaultFormatter": "esbenp.prettier-vscode"
},
"[javascriptreact]": {
"editor.defaultFormatter": "esbenp.prettier-vscode"
},
"[json]": {
"editor.defaultFormatter": "esbenp.prettier-vscode"
},
"[jsonc]": {
"editor.defaultFormatter": "esbenp.prettier-vscode"
},
"[less]": {
"editor.defaultFormatter": "stylelint.vscode-stylelint"
},
"[scss]": {
"editor.defaultFormatter": "esbenp.prettier-vscode"
},
"[typescriptreact]": {
"editor.defaultFormatter": "esbenp.prettier-vscode"
},
"[ignore]": {
"editor.defaultFormatter": "foxundermoon.shell-format"
},
"[shellscript]": {
"editor.defaultFormatter": "foxundermoon.shell-format"
},
"[dotenv]": {
"editor.defaultFormatter": "foxundermoon.shell-format"
},
"[svg]": {
"editor.defaultFormatter": "jock.svg"
},
"svg.preview.background": "white",
"[xml]": {
"editor.defaultFormatter": "mblode.pretty-formatter"
},
"[sql]": {
"editor.defaultFormatter": "adpyke.vscode-sql-formatter"
},
"git.openRepositoryInParentFolders": "always",
"references.preferredLocation": "view"
}
Original file line number Diff line number Diff line change
Expand Up @@ -57,7 +57,8 @@ export interface VerifyTokenRequest {
token: string
}
export interface VerifyTokenResponse {
valid?: boolean
valid?: boolean,
user_id?: string,
}
/** OpenAPI PAT管理,开源版本暂不支持OAuth */
export const CreatePersonalAccessToken = /*#__PURE__*/createAPI<CreatePersonalAccessTokenRequest, CreatePersonalAccessTokenResponse>({
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -10,10 +10,7 @@ export enum SpaceType {
}
/** 空间 */
export interface Space {
/**
* TODO: 空间定义跟CozeStudio对齐
* 空间ID
*/
/** 空间ID */
id: string,
/** 空间名称 */
name: string,
Expand Down
Original file line number Diff line number Diff line change
@@ -1,9 +1,6 @@
/** UserInfoDetail 用户详细信息,包含姓名、头像等 */
export interface UserInfoDetail {
/**
* TODO: User定义跟CozeStudio对齐
* 唯一名称
*/
/** 唯一名称 */
name?: string,
/** 用户昵称 */
nick_name?: string,
Expand Down
Loading