Read-only mirror — the public repositories of the Forgejo instance, refreshed every 10 minutes. The live instance (fg.dieschoenewolke.de) is reachable only over the VPN; clone here with https://git.dieschoenewolke.de/git/<owner>/<repo>.git.
summaryrefslogtreecommitdiff
path: root/src/git-command-manager.ts
diff options
context:
space:
mode:
authorVallie Joseph <vmjoseph@github.com>2022-12-01 15:56:41 +0000
committerVallie Joseph <vmjoseph@github.com>2022-12-01 15:56:41 +0000
commit01e4b8775f24445822af997b3dccf0174ae9ace0 (patch)
treec08a78a8d921f416850c2fa48e02850861afaa61 /src/git-command-manager.ts
parentdbde1f7446e488daa71546f30dae978dd71a506c (diff)
.
Diffstat (limited to 'src/git-command-manager.ts')
-rw-r--r--src/git-command-manager.ts29
1 files changed, 18 insertions, 11 deletions
diff --git a/src/git-command-manager.ts b/src/git-command-manager.ts
index 4c86e65..0fc0aed 100644
--- a/src/git-command-manager.ts
+++ b/src/git-command-manager.ts
@@ -94,7 +94,6 @@ class GitCommandManager {
const result: string[] = []
const stderr: string[] = []
- core.info(this.gitEnv['GIT_HTTP_USER_AGENT'])
// Note, this implementation uses "rev-parse --symbolic-full-name" because the output from
// "branch --list" is more difficult when in a detached HEAD state.
// Note, this implementation uses "rev-parse --symbolic-full-name" because there is a bug
@@ -430,25 +429,33 @@ class GitCommandManager {
// }}
const listenersD = {...customListeners, ...defaultListener}
const stdout: string[] = []
- // let temp = ''
+ let temp = ''
+ let temp2 = ''
const options = {
cwd: this.workingDirectory,
env,
silent,
ignoreReturnCode: allowAllExitCodes,
- listeners: listenersD
- // ,
- // errStream: new stream.Writable({
- // write(chunk, _, next) {
- // temp += chunk.toString()
- // next()
- // }
- // })
+ listeners: listenersD,
+ errStream: new stream.Writable({
+ write(chunk, _, next) {
+ temp += chunk.toString()
+ next()
+ }
+ }),
+
+ outStream: new stream.Writable({
+ write(chunk, _, next) {
+ temp2 += chunk.toString()
+ next()
+ }
+ })
}
result.exitCode = await exec.exec(`"${this.gitPath}"`, args, options)
result.stdout = stdout.join('')
- core.info(result.stdout)
+ core.info(temp.length.toString())
+ core.info(temp2.length.toString())
return result
}