feat: initial implementation #5

Merged
jank merged 21 commits from main into release 2025-04-09 16:25:18 +00:00
2 changed files with 7 additions and 32 deletions
Showing only changes of commit 80ab70da04 - Show all commits

View file

@ -1,30 +0,0 @@
const childProcess = require('child_process')
const path = require('path')
function runGo() {
const goProcess = childProcess.spawnSync(
'go',
['run', '.'],
{
cwd: __dirname,
stdio: 'inherit',
shell: true,
},
)
if (goProcess.error) {
console.error('Failed to execute `go run .`:', goProcess.error)
process.exit(1)
}
if (goProcess.status !== 0) {
console.error(
'`go run .` exited with code',
goProcess.status,
goProcess.stderr ? goProcess.stderr.toString() : '',
)
process.exit(goProcess.status)
}
}
runGo()

View file

@ -6,6 +6,11 @@ import (
)
func main() {
prTitle := os.Getenv("GITEA_PULL_REQUEST_TITLE")
fmt.Println(prTitle)
// Get all environment variables
environ := os.Environ()
// Print each environment variable
for _, env := range environ {
fmt.Println(env)
}
}