This is an automated email from the ASF dual-hosted git repository.

tison pushed a commit to branch main
in repository https://gitbox.apache.org/repos/asf/pulsar-site.git


The following commit(s) were added to refs/heads/main by this push:
     new 1ee4815cca0 git config on CI env
1ee4815cca0 is described below

commit 1ee4815cca0c5ad2d1cfff8338a1dc81a7fd015f
Author: tison <[email protected]>
AuthorDate: Sat Dec 3 11:11:13 2022 +0800

    git config on CI env
    
    Signed-off-by: tison <[email protected]>
---
 tools/pytools/bin/site-updater.py | 4 ++++
 1 file changed, 4 insertions(+)

diff --git a/tools/pytools/bin/site-updater.py 
b/tools/pytools/bin/site-updater.py
index b39ea89db46..a4492e4731b 100755
--- a/tools/pytools/bin/site-updater.py
+++ b/tools/pytools/bin/site-updater.py
@@ -56,6 +56,10 @@ def _do_push(main: Path, site: Path):
     run(_git, 'add', '-A', '.', cwd=site)
     run(_git, 'status', cwd=site)
     run(_git, 'remote', '-v', cwd=site)
+    if os.getenv('GITHUB_ACTIONS') is not None:
+        name = os.getenv('GITHUB_ACTOR') or 'Pulsar Site Updater'
+        run(_git, 'config', 'user.name', name, cwd=site)
+        run(_git, 'config', 'user.email', f"{name}@users.noreply.github.com", 
cwd=site)
     run(_git, 'commit', '--allow-empty', '-m', f'Docs sync done from 
apache/pulsar (#{commit})', cwd=site)
     run(_git, 'push', 'origin', 'main', cwd=site)
 

Reply via email to