3x-ui/.vscode/tasks.json
Sanaei 216d18b3c4
Some checks failed
CI / go-test (push) Has been cancelled
CI / postgres-durable-first (push) Has been cancelled
CI / codegen (push) Has been cancelled
CI / govulncheck (push) Has been cancelled
CI / race (push) Has been cancelled
CI / fuzz-smoke (push) Has been cancelled
CI / golangci (push) Has been cancelled
CI / frontend (push) Has been cancelled
CodeQL Advanced / Analyze (go) (push) Has been cancelled
CodeQL Advanced / Analyze (actions) (push) Has been cancelled
CodeQL Advanced / Analyze (javascript-typescript) (push) Has been cancelled
Docs CI / build (push) Has been cancelled
Docs Deploy (GitHub Pages) / build (push) Has been cancelled
Release 3X-UI / build (386) (push) Has been cancelled
Release 3X-UI / build (amd64) (push) Has been cancelled
Release 3X-UI / build (arm64) (push) Has been cancelled
Release 3X-UI / build (armv5) (push) Has been cancelled
Release 3X-UI / build (armv6) (push) Has been cancelled
Release 3X-UI / build (armv7) (push) Has been cancelled
Release 3X-UI / build (s390x) (push) Has been cancelled
Release 3X-UI / Build for Windows (push) Has been cancelled
Docs Deploy (GitHub Pages) / deploy (push) Has been cancelled
Release 3X-UI / Publish rolling dev release (push) Has been cancelled
chore(vscode): fix Linux paths in the task and launch configs
The "go: build" task hardcoded bin/3x-ui.exe, so building on Linux
produced a binary carrying a Windows extension. It now emits bin/3x-ui
and keeps the .exe name behind a windows override.

The Postgres launch config prepended C:\Program Files\PostgreSQL\18\bin
to PATH on every platform. Linux separates entries with ':', not ';', so
that string fused into the first real PATH entry and clobbered it. Moved
it into a windows block, which is where the pg_dump/pg_restore lookups
in ServerService need it anyway.
2026-08-02 12:40:11 +02:00

472 lines
No EOL
9.3 KiB
JSON

{
"version": "2.0.0",
"tasks": [
{
"label": "go: build",
"type": "shell",
"command": "go",
"args": [
"build",
"-o",
"bin/3x-ui",
"./main.go"
],
"windows": {
"args": [
"build",
"-o",
"bin/3x-ui.exe",
"./main.go"
]
},
"options": {
"cwd": "${workspaceFolder}"
},
"problemMatcher": [
"$go"
],
"group": {
"kind": "build",
"isDefault": true
}
},
{
"label": "go: run",
"type": "shell",
"command": "go",
"args": [
"run",
"./main.go"
],
"options": {
"cwd": "${workspaceFolder}",
"env": {
"XUI_DEBUG": "true"
}
},
"problemMatcher": [
"$go"
]
},
{
"label": "go: test",
"type": "shell",
"command": "go",
"args": [
"test",
"./..."
],
"options": {
"cwd": "${workspaceFolder}"
},
"problemMatcher": [
"$go"
],
"group": "test"
},
{
"label": "go: vet",
"type": "shell",
"command": "go",
"args": [
"vet",
"./..."
],
"options": {
"cwd": "${workspaceFolder}"
},
"problemMatcher": [
"$go"
]
},
{
"label": "go: fmt",
"type": "shell",
"command": "go",
"args": [
"fmt",
"./..."
],
"options": {
"cwd": "${workspaceFolder}"
},
"problemMatcher": [
"$go"
]
},
{
"label": "go: modernize",
"type": "shell",
"command": "modernize",
"args": [
"./..."
],
"options": {
"cwd": "${workspaceFolder}"
},
"linux": {
"options": {
"cwd": "${workspaceFolder}",
"env": {
"PATH": "${userHome}/go/bin:/usr/local/go/bin:${env:PATH}"
}
}
},
"osx": {
"options": {
"cwd": "${workspaceFolder}",
"env": {
"PATH": "${userHome}/go/bin:/usr/local/go/bin:${env:PATH}"
}
}
},
"problemMatcher": [
"$go"
]
},
{
"label": "go: modernize -fix",
"type": "shell",
"command": "modernize",
"args": [
"-fix",
"./..."
],
"options": {
"cwd": "${workspaceFolder}"
},
"linux": {
"options": {
"cwd": "${workspaceFolder}",
"env": {
"PATH": "${userHome}/go/bin:/usr/local/go/bin:${env:PATH}"
}
}
},
"osx": {
"options": {
"cwd": "${workspaceFolder}",
"env": {
"PATH": "${userHome}/go/bin:/usr/local/go/bin:${env:PATH}"
}
}
},
"problemMatcher": [
"$go"
]
},
{
"label": "go: golangci-lint run",
"type": "shell",
"command": "golangci-lint",
"args": [
"run"
],
"options": {
"cwd": "${workspaceFolder}"
},
"linux": {
"options": {
"cwd": "${workspaceFolder}",
"env": {
"PATH": "${userHome}/go/bin:/usr/local/go/bin:${env:PATH}"
}
}
},
"osx": {
"options": {
"cwd": "${workspaceFolder}",
"env": {
"PATH": "${userHome}/go/bin:/usr/local/go/bin:${env:PATH}"
}
}
},
"problemMatcher": [
"$go"
]
},
{
"label": "go: golangci-lint run --fix",
"type": "shell",
"command": "golangci-lint",
"args": [
"run",
"--fix"
],
"options": {
"cwd": "${workspaceFolder}"
},
"linux": {
"options": {
"cwd": "${workspaceFolder}",
"env": {
"PATH": "${userHome}/go/bin:/usr/local/go/bin:${env:PATH}"
}
}
},
"osx": {
"options": {
"cwd": "${workspaceFolder}",
"env": {
"PATH": "${userHome}/go/bin:/usr/local/go/bin:${env:PATH}"
}
}
},
"problemMatcher": [
"$go"
]
},
{
"label": "go: install golangci-lint",
"type": "shell",
"command": "go",
"args": [
"install",
"github.com/golangci/golangci-lint/v2/cmd/golangci-lint@latest"
],
"options": {
"cwd": "${workspaceFolder}"
},
"linux": {
"options": {
"cwd": "${workspaceFolder}",
"env": {
"PATH": "${userHome}/go/bin:/usr/local/go/bin:${env:PATH}"
}
}
},
"osx": {
"options": {
"cwd": "${workspaceFolder}",
"env": {
"PATH": "${userHome}/go/bin:/usr/local/go/bin:${env:PATH}"
}
}
},
"problemMatcher": []
},
{
"label": "go: install modernize",
"type": "shell",
"command": "go",
"args": [
"install",
"golang.org/x/tools/gopls/internal/analysis/modernize/cmd/modernize@latest"
],
"options": {
"cwd": "${workspaceFolder}"
},
"linux": {
"options": {
"cwd": "${workspaceFolder}",
"env": {
"PATH": "${userHome}/go/bin:/usr/local/go/bin:${env:PATH}"
}
}
},
"osx": {
"options": {
"cwd": "${workspaceFolder}",
"env": {
"PATH": "${userHome}/go/bin:/usr/local/go/bin:${env:PATH}"
}
}
},
"problemMatcher": []
},
{
"label": "go: install tools",
"dependsOrder": "sequence",
"dependsOn": [
"go: install golangci-lint",
"go: install modernize"
],
"problemMatcher": []
},
{
"label": "frontend: ncu -u",
"type": "shell",
"command": "npx",
"args": [
"npm-check-updates",
"-u"
],
"options": {
"cwd": "${workspaceFolder}/frontend"
},
"problemMatcher": []
},
{
"label": "frontend: install",
"type": "shell",
"command": "npm",
"args": [
"install"
],
"options": {
"cwd": "${workspaceFolder}/frontend"
},
"problemMatcher": []
},
{
"label": "frontend: dev",
"type": "shell",
"command": "npm",
"args": [
"run",
"dev"
],
"options": {
"cwd": "${workspaceFolder}/frontend"
},
"isBackground": true,
"problemMatcher": [],
"presentation": {
"panel": "dedicated",
"group": "dev"
}
},
{
"label": "frontend: build",
"type": "shell",
"command": "npm",
"args": [
"run",
"build"
],
"options": {
"cwd": "${workspaceFolder}/frontend"
},
"problemMatcher": [
"$tsc"
],
"group": "build"
},
{
"label": "frontend: gen",
"type": "shell",
"command": "npm",
"args": [
"run",
"gen"
],
"options": {
"cwd": "${workspaceFolder}/frontend"
},
"problemMatcher": []
},
{
"label": "frontend: lint",
"type": "shell",
"command": "npm",
"args": [
"run",
"lint"
],
"options": {
"cwd": "${workspaceFolder}/frontend"
},
"problemMatcher": [
"$eslint-stylish"
]
},
{
"label": "frontend: test",
"type": "shell",
"command": "npm",
"args": [
"run",
"test"
],
"options": {
"cwd": "${workspaceFolder}/frontend"
},
"problemMatcher": [],
"group": "test"
},
{
"label": "frontend: test:watch",
"type": "shell",
"command": "npm",
"args": [
"run",
"test:watch"
],
"options": {
"cwd": "${workspaceFolder}/frontend"
},
"isBackground": true,
"problemMatcher": [],
"group": "test",
"presentation": {
"panel": "dedicated",
"group": "test"
}
},
{
"label": "frontend: typecheck",
"type": "shell",
"command": "npm",
"args": [
"run",
"typecheck"
],
"options": {
"cwd": "${workspaceFolder}/frontend"
},
"problemMatcher": [
"$tsc"
]
},
{
"label": "frontend: gen:zod",
"type": "shell",
"command": "npm",
"args": [
"run",
"gen:zod"
],
"options": {
"cwd": "${workspaceFolder}/frontend"
},
"problemMatcher": []
},
{
"label": "frontend: gen:api",
"type": "shell",
"command": "npm",
"args": [
"run",
"gen:api"
],
"options": {
"cwd": "${workspaceFolder}/frontend"
},
"problemMatcher": []
},
{
"label": "build: full (frontend + go)",
"dependsOrder": "sequence",
"dependsOn": [
"frontend: build",
"go: build"
],
"problemMatcher": [],
"group": {
"kind": "build",
"isDefault": false
}
},
{
"label": "check: all",
"dependsOn": [
"go: vet",
"go: test",
"frontend: lint",
"frontend: typecheck",
"frontend: test"
],
"problemMatcher": []
}
]
}