Quest: remove unnecessary ls-stages (#195)

* quest: remove ls-stages in create

* feat: prevent throwing errors when failed to copy files

* feat: log new command in dev mode

* quest: copy

* quest: mv

* quest: rm

* quest: execute. Add many exceptions

* feat: pwd discovers parent folders
This commit is contained in:
Justin Lin authored and GitHub committed 2025-04-30 15:01:25 +08:00
1 parent f0a09ac4d9
commit 3b77d91796
9 files changed
+147 -217

No files matched your search

@@ -6,8 +6,12 @@ import { finishSession } from '../../models/sessionManager'
import { asyncHandler } from '../../middleware/error'
import { questManager } from '../../models/quest'
import { CLIFileExistenceChecker } from '../../containers/cli'
import config from '../../config'
export const newCommand = asyncHandler(async (req: Request, res: Response) => {
if (!config.isProduction) {
console.log('newCommand', JSON.stringify(req.body, null, 2))
}
const body = commandSchema.safeParse(req.body)
if (!body.success) {
res.status(400).json({ message: 'Invalid command', errors: body.error })