You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@skywalking.apache.org by ke...@apache.org on 2022/05/10 07:21:31 UTC
[skywalking-eyes] branch gha-summary updated (acb75d8 -> 400bc6d)
This is an automated email from the ASF dual-hosted git repository.
kezhenxu94 pushed a change to branch gha-summary
in repository https://gitbox.apache.org/repos/asf/skywalking-eyes.git
discard acb75d8 Test
new 400bc6d Test
This update added new revisions after undoing existing revisions.
That is to say, some revisions that were in the old version of the
branch are not in the new version. This situation occurs
when a user --force pushes a change and generates a repository
containing something like this:
* -- * -- B -- O -- O -- O (acb75d8)
\
N -- N -- N refs/heads/gha-summary (400bc6d)
You should already have received notification emails for all of the O
revisions, and so the following emails describe only the N revisions
from the common base, B.
Any revisions marked "omit" are not gone; other references still
refer to them. Any revisions marked "discard" are gone forever.
The 1 revisions listed above as "new" are entirely new to this
repository and will be described in separate emails. The revisions
listed as "add" were already present in the repository and have only
been added to this reference.
Summary of changes:
commands/header_check.go | 21 ++++++++++++++-------
1 file changed, 14 insertions(+), 7 deletions(-)
[skywalking-eyes] 01/01: Test
Posted by ke...@apache.org.
This is an automated email from the ASF dual-hosted git repository.
kezhenxu94 pushed a commit to branch gha-summary
in repository https://gitbox.apache.org/repos/asf/skywalking-eyes.git
commit 400bc6ddf67d2a19ef780c34d77d245ed08a78f7
Author: kezhenxu94 <ke...@apache.org>
AuthorDate: Tue May 10 15:16:22 2022 +0800
Test
---
.github/workflows/license-eye-check.yaml | 1 +
commands/header_check.go | 21 ++++++++++++++-------
test.go | 1 +
3 files changed, 16 insertions(+), 7 deletions(-)
diff --git a/.github/workflows/license-eye-check.yaml b/.github/workflows/license-eye-check.yaml
index d650d5b..fbb26c9 100644
--- a/.github/workflows/license-eye-check.yaml
+++ b/.github/workflows/license-eye-check.yaml
@@ -22,6 +22,7 @@ on:
push:
branches:
- main
+ - gha-summary
jobs:
build-license-eye:
diff --git a/commands/header_check.go b/commands/header_check.go
index 802fde7..1a42a8d 100644
--- a/commands/header_check.go
+++ b/commands/header_check.go
@@ -46,13 +46,7 @@ var CheckCommand = &cobra.Command{
logger.Log.Infoln(result.String())
- if summaryFileName := os.Getenv("GITHUB_STEP_SUMMARY"); summaryFileName != "" {
- if summaryFile, err := os.OpenFile(summaryFileName, os.O_WRONLY|os.O_APPEND, 0o644); err == nil {
- defer summaryFile.Close()
- _, _ = summaryFile.WriteString(result.String())
- _, _ = summaryFile.WriteString(fmt.Sprintln(result.Error()))
- }
- }
+ writeSummaryQuietly(result)
if result.HasFailure() {
if err := review.Header(&result, &Config); err != nil {
@@ -64,3 +58,16 @@ var CheckCommand = &cobra.Command{
return nil
},
}
+
+func writeSummaryQuietly(result header.Result) {
+ if summaryFileName := os.Getenv("GITHUB_STEP_SUMMARY"); summaryFileName != "" {
+ if summaryFile, err := os.OpenFile(summaryFileName, os.O_WRONLY|os.O_APPEND, 0o644); err == nil {
+ defer summaryFile.Close()
+ _, _ = summaryFile.WriteString(result.String())
+ if result.HasFailure() {
+ _, _ = summaryFile.WriteString("\n")
+ _, _ = summaryFile.WriteString(fmt.Sprintln(result.Error()))
+ }
+ }
+ }
+}
diff --git a/test.go b/test.go
new file mode 100644
index 0000000..06ab7d0
--- /dev/null
+++ b/test.go
@@ -0,0 +1 @@
+package main