|
|
@ -148,22 +148,29 @@ try { |
|
|
|
let httpFileName = path.join(fileDir, `auto_generated_http_crud_${underscore_naming}_${struct}_${fileBaseName}`) |
|
|
|
|
|
|
|
fs.writeFile(crudFileName, `${package_src}\n\n${tmp[2]}`, function () { |
|
|
|
cp.exec(`gopls fix -a -w ${crudFileName}`, function (a, b, c) { |
|
|
|
console.log("exec:", a, b, c) |
|
|
|
}) |
|
|
|
setTimeout(function () { |
|
|
|
|
|
|
|
cp.exec(`gopls fix -a -w ${crudFileName}`, function (a, b, c) { |
|
|
|
console.log("exec:", a, b, c) |
|
|
|
}) |
|
|
|
}, 1000) |
|
|
|
}) |
|
|
|
|
|
|
|
fs.writeFile(httpFileName, `${package_src}\n\n${tmp[3]}`, function () { |
|
|
|
cp.exec(`gopls fix -a -w ${httpFileName}`, function (a, b, c) { |
|
|
|
console.log("exec:", a, b, c) |
|
|
|
}) |
|
|
|
setTimeout(function () { |
|
|
|
cp.exec(`gopls fix -a -w ${httpFileName}`, function (a, b, c) { |
|
|
|
console.log("exec:", a, b, c) |
|
|
|
}) |
|
|
|
}, 1000) |
|
|
|
}) |
|
|
|
|
|
|
|
|
|
|
|
cp.exec(`gopls fix -a -w ${fileName}`, function (a, b, c) { |
|
|
|
console.log("exec:", a, b, c) |
|
|
|
}) |
|
|
|
setTimeout(function () { |
|
|
|
cp.exec(`gopls fix -a -w ${fileName}`, function (a, b, c) { |
|
|
|
console.log("exec:", a, b, c) |
|
|
|
}) |
|
|
|
|
|
|
|
}, 1000) |
|
|
|
|
|
|
|
// vscode.window.showErrorMessage(res)
|
|
|
|
}).catch(error => { |
|
|
|