* [PR PATCH] common/travis/xlint: make xlint only fatal for new templates
@ 2023-07-08 22:28 classabbyamp
2023-07-08 22:29 ` [PR PATCH] [Updated] " classabbyamp
` (11 more replies)
0 siblings, 12 replies; 13+ messages in thread
From: classabbyamp @ 2023-07-08 22:28 UTC (permalink / raw)
To: ml
[-- Attachment #1: Type: text/plain, Size: 660 bytes --]
There is a new pull request by classabbyamp against master on the void-packages repository
https://github.com/classabbyamp/void-packages ci/xlint-nonfatal
https://github.com/void-linux/void-packages/pull/44930
common/travis/xlint: make xlint only fatal for new templates
per discussion on irc, to help updates and other changes go more smoothly, xlint should only cause a CI failure if the linted template is new.
<!-- Uncomment relevant sections and delete options which are not applicable -->
#### Testing the changes
- I tested the changes in this PR: **YES**
A patch file from https://github.com/void-linux/void-packages/pull/44930.patch is attached
[-- Warning: decoded text below may be mangled, UTF-8 assumed --]
[-- Attachment #2: github-pr-ci/xlint-nonfatal-44930.patch --]
[-- Type: text/x-diff, Size: 2108 bytes --]
From adbca83b26d56e5a41ab23079312328af76b0a65 Mon Sep 17 00:00:00 2001
From: classabbyamp <void@placeviolette.net>
Date: Sat, 8 Jul 2023 18:19:43 -0400
Subject: [PATCH] common/travis/xlint: make xlint only fatal for new templates
to help updates and other changes go more smoothly, xlint should only
cause a CI failure if the linted template is new.
---
common/travis/changed_templates.sh | 10 +++++++++-
common/travis/xlint.sh | 7 ++++++-
2 files changed, 15 insertions(+), 2 deletions(-)
diff --git a/common/travis/changed_templates.sh b/common/travis/changed_templates.sh
index 91af1f1a3c1a..c54b76e92e85 100755
--- a/common/travis/changed_templates.sh
+++ b/common/travis/changed_templates.sh
@@ -20,9 +20,17 @@ base="$(git merge-base origin/HEAD "$tip")"
echo "$base $tip" >/tmp/revisions
/bin/echo -e '\x1b[32mChanged packages:\x1b[0m'
-git diff-tree -r --no-renames --name-only --diff-filter=AM \
+git diff-tree -r --no-renames --name-only --diff-filter=M \
"$base" "$tip" \
-- 'srcpkgs/*/template' |
cut -d/ -f 2 |
tee /tmp/templates |
sed "s/^/ /" >&2
+/bin/echo -e '\x1b[32mNew packages:\x1b[0m'
+git diff-tree -r --no-renames --name-only --diff-filter=A \
+ "$base" "$tip" \
+ -- 'srcpkgs/*/template' |
+ cut -d/ -f 2 |
+ tee -a /tmp/templates |
+ tee /tmp/new-templates |
+ sed "s/^/ /" >&2
diff --git a/common/travis/xlint.sh b/common/travis/xlint.sh
index 790791ef1733..2f0ab673a10a 100755
--- a/common/travis/xlint.sh
+++ b/common/travis/xlint.sh
@@ -11,7 +11,12 @@ common/scripts/lint-commits $base $tip || EXITCODE=$?
for t in $(awk '{ print "srcpkgs/" $0 "/template" }' /tmp/templates); do
/bin/echo -e "\x1b[32mLinting $t...\x1b[0m"
- xlint "$t" > /tmp/xlint_out || EXITCODE=$?
+ if grep -q "srcpkgs/$t/template" /tmp/new-templates; then
+ # only fatal if xlint fails for new templates
+ xlint "$t" > /tmp/xlint_out || EXITCODE=$?
+ else
+ xlint "$t" > /tmp/xlint_out || true
+ fi
common/scripts/lint-version-change "$t" $base $tip > /tmp/vlint_out || EXITCODE=$?
awk -f common/scripts/lint2annotations.awk /tmp/xlint_out /tmp/vlint_out
done
^ permalink raw reply [flat|nested] 13+ messages in thread
* Re: [PR PATCH] [Updated] common/travis/xlint: make xlint only fatal for new templates
2023-07-08 22:28 [PR PATCH] common/travis/xlint: make xlint only fatal for new templates classabbyamp
@ 2023-07-08 22:29 ` classabbyamp
2023-07-08 22:41 ` classabbyamp
` (10 subsequent siblings)
11 siblings, 0 replies; 13+ messages in thread
From: classabbyamp @ 2023-07-08 22:29 UTC (permalink / raw)
To: ml
[-- Attachment #1: Type: text/plain, Size: 665 bytes --]
There is an updated pull request by classabbyamp against master on the void-packages repository
https://github.com/classabbyamp/void-packages ci/xlint-nonfatal
https://github.com/void-linux/void-packages/pull/44930
common/travis/xlint: make xlint only fatal for new templates
per discussion on irc, to help updates and other changes go more smoothly, xlint should only cause a CI failure if the linted template is new.
<!-- Uncomment relevant sections and delete options which are not applicable -->
#### Testing the changes
- I tested the changes in this PR: **YES**
A patch file from https://github.com/void-linux/void-packages/pull/44930.patch is attached
[-- Warning: decoded text below may be mangled, UTF-8 assumed --]
[-- Attachment #2: github-pr-ci/xlint-nonfatal-44930.patch --]
[-- Type: text/x-diff, Size: 3802 bytes --]
From adbca83b26d56e5a41ab23079312328af76b0a65 Mon Sep 17 00:00:00 2001
From: classabbyamp <void@placeviolette.net>
Date: Sat, 8 Jul 2023 18:19:43 -0400
Subject: [PATCH 1/3] common/travis/xlint: make xlint only fatal for new
templates
to help updates and other changes go more smoothly, xlint should only
cause a CI failure if the linted template is new.
---
common/travis/changed_templates.sh | 10 +++++++++-
common/travis/xlint.sh | 7 ++++++-
2 files changed, 15 insertions(+), 2 deletions(-)
diff --git a/common/travis/changed_templates.sh b/common/travis/changed_templates.sh
index 91af1f1a3c1a..c54b76e92e85 100755
--- a/common/travis/changed_templates.sh
+++ b/common/travis/changed_templates.sh
@@ -20,9 +20,17 @@ base="$(git merge-base origin/HEAD "$tip")"
echo "$base $tip" >/tmp/revisions
/bin/echo -e '\x1b[32mChanged packages:\x1b[0m'
-git diff-tree -r --no-renames --name-only --diff-filter=AM \
+git diff-tree -r --no-renames --name-only --diff-filter=M \
"$base" "$tip" \
-- 'srcpkgs/*/template' |
cut -d/ -f 2 |
tee /tmp/templates |
sed "s/^/ /" >&2
+/bin/echo -e '\x1b[32mNew packages:\x1b[0m'
+git diff-tree -r --no-renames --name-only --diff-filter=A \
+ "$base" "$tip" \
+ -- 'srcpkgs/*/template' |
+ cut -d/ -f 2 |
+ tee -a /tmp/templates |
+ tee /tmp/new-templates |
+ sed "s/^/ /" >&2
diff --git a/common/travis/xlint.sh b/common/travis/xlint.sh
index 790791ef1733..2f0ab673a10a 100755
--- a/common/travis/xlint.sh
+++ b/common/travis/xlint.sh
@@ -11,7 +11,12 @@ common/scripts/lint-commits $base $tip || EXITCODE=$?
for t in $(awk '{ print "srcpkgs/" $0 "/template" }' /tmp/templates); do
/bin/echo -e "\x1b[32mLinting $t...\x1b[0m"
- xlint "$t" > /tmp/xlint_out || EXITCODE=$?
+ if grep -q "srcpkgs/$t/template" /tmp/new-templates; then
+ # only fatal if xlint fails for new templates
+ xlint "$t" > /tmp/xlint_out || EXITCODE=$?
+ else
+ xlint "$t" > /tmp/xlint_out || true
+ fi
common/scripts/lint-version-change "$t" $base $tip > /tmp/vlint_out || EXITCODE=$?
awk -f common/scripts/lint2annotations.awk /tmp/xlint_out /tmp/vlint_out
done
From 0705c018c1781b53c6b5a064850393eb5db294d6 Mon Sep 17 00:00:00 2001
From: classabbyamp <void@placeviolette.net>
Date: Sat, 8 Jul 2023 18:28:42 -0400
Subject: [PATCH 2/3] chezmoi: temp
---
srcpkgs/chezmoi/template | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/srcpkgs/chezmoi/template b/srcpkgs/chezmoi/template
index 074ef8b8c602..dac1e038fed8 100644
--- a/srcpkgs/chezmoi/template
+++ b/srcpkgs/chezmoi/template
@@ -1,7 +1,7 @@
# Template file for 'chezmoi'
pkgname=chezmoi
version=2.34.3
-revision=1
+revision=2
build_style=go
go_import_path="github.com/twpayne/chezmoi/v2"
go_build_tags="noembeddocs noupgrade"
From ec026071e1a25958b057234992de4fcdca52a55e Mon Sep 17 00:00:00 2001
From: classabbyamp <void@placeviolette.net>
Date: Sat, 8 Jul 2023 18:29:12 -0400
Subject: [PATCH 3/3] New package: foobar-. this is a test
---
srcpkgs/foobar/template | 22 ++++++++++++++++++++++
1 file changed, 22 insertions(+)
create mode 100644 srcpkgs/foobar/template
diff --git a/srcpkgs/foobar/template b/srcpkgs/foobar/template
new file mode 100644
index 000000000000..d56b401d9784
--- /dev/null
+++ b/srcpkgs/foobar/template
@@ -0,0 +1,22 @@
+# Template file for 'foobar'
+pkgname=foobar
+version=
+revision=1
+#archs="i686 x86_64"
+#build_wrksrc=
+build_style=gnu-configure
+#configure_args=""
+#make_build_args=""
+#make_install_args=""
+#conf_files=""
+#make_dirs="/var/log/dir 0755 root root"
+hostmakedepends=""
+makedepends=""
+depends=""
+short_desc=""
+maintainer="classabbyamp <void@placeviolette.net>"
+license="GPL-3.0-or-later"
+homepage=""
+#changelog=""
+distfiles=""
+checksum=badbadbadbadbadbadbadbadbadbadbadbadbadbadbadbadbadbadbadbadbadb
^ permalink raw reply [flat|nested] 13+ messages in thread
* Re: [PR PATCH] [Updated] common/travis/xlint: make xlint only fatal for new templates
2023-07-08 22:28 [PR PATCH] common/travis/xlint: make xlint only fatal for new templates classabbyamp
2023-07-08 22:29 ` [PR PATCH] [Updated] " classabbyamp
@ 2023-07-08 22:41 ` classabbyamp
2023-07-08 22:42 ` classabbyamp
` (9 subsequent siblings)
11 siblings, 0 replies; 13+ messages in thread
From: classabbyamp @ 2023-07-08 22:41 UTC (permalink / raw)
To: ml
[-- Attachment #1: Type: text/plain, Size: 665 bytes --]
There is an updated pull request by classabbyamp against master on the void-packages repository
https://github.com/classabbyamp/void-packages ci/xlint-nonfatal
https://github.com/void-linux/void-packages/pull/44930
common/travis/xlint: make xlint only fatal for new templates
per discussion on irc, to help updates and other changes go more smoothly, xlint should only cause a CI failure if the linted template is new.
<!-- Uncomment relevant sections and delete options which are not applicable -->
#### Testing the changes
- I tested the changes in this PR: **YES**
A patch file from https://github.com/void-linux/void-packages/pull/44930.patch is attached
[-- Warning: decoded text below may be mangled, UTF-8 assumed --]
[-- Attachment #2: github-pr-ci/xlint-nonfatal-44930.patch --]
[-- Type: text/x-diff, Size: 3903 bytes --]
From e53feff4d3d0a864925558da3d422beb74f09463 Mon Sep 17 00:00:00 2001
From: classabbyamp <void@placeviolette.net>
Date: Sat, 8 Jul 2023 18:19:43 -0400
Subject: [PATCH 1/3] common/travis/xlint: make xlint only fatal for new
templates
to help updates and other changes go more smoothly, xlint should only
cause a CI failure if the linted template is new.
---
common/travis/changed_templates.sh | 15 ++++++++++++++-
common/travis/xlint.sh | 7 ++++++-
2 files changed, 20 insertions(+), 2 deletions(-)
diff --git a/common/travis/changed_templates.sh b/common/travis/changed_templates.sh
index 91af1f1a3c1a..124ede1b1746 100755
--- a/common/travis/changed_templates.sh
+++ b/common/travis/changed_templates.sh
@@ -20,9 +20,22 @@ base="$(git merge-base origin/HEAD "$tip")"
echo "$base $tip" >/tmp/revisions
/bin/echo -e '\x1b[32mChanged packages:\x1b[0m'
-git diff-tree -r --no-renames --name-only --diff-filter=AM \
+git diff-tree -r --no-renames --name-only --diff-filter=M \
"$base" "$tip" \
-- 'srcpkgs/*/template' |
cut -d/ -f 2 |
tee /tmp/templates |
sed "s/^/ /" >&2
+/bin/echo -e '\x1b[32mNew packages:\x1b[0m'
+git diff-tree -r --no-renames --name-only --diff-filter=A \
+ "$base" "$tip" \
+ -- 'srcpkgs/*/template' |
+ cut -d/ -f 2 |
+ tee -a /tmp/templates |
+ tee /tmp/new-templates |
+ sed "s/^/ /" >&2
+
+set -x
+cat /tmp/templates
+cat /tmp/new-templates
+set +x
diff --git a/common/travis/xlint.sh b/common/travis/xlint.sh
index 790791ef1733..2f0ab673a10a 100755
--- a/common/travis/xlint.sh
+++ b/common/travis/xlint.sh
@@ -11,7 +11,12 @@ common/scripts/lint-commits $base $tip || EXITCODE=$?
for t in $(awk '{ print "srcpkgs/" $0 "/template" }' /tmp/templates); do
/bin/echo -e "\x1b[32mLinting $t...\x1b[0m"
- xlint "$t" > /tmp/xlint_out || EXITCODE=$?
+ if grep -q "srcpkgs/$t/template" /tmp/new-templates; then
+ # only fatal if xlint fails for new templates
+ xlint "$t" > /tmp/xlint_out || EXITCODE=$?
+ else
+ xlint "$t" > /tmp/xlint_out || true
+ fi
common/scripts/lint-version-change "$t" $base $tip > /tmp/vlint_out || EXITCODE=$?
awk -f common/scripts/lint2annotations.awk /tmp/xlint_out /tmp/vlint_out
done
From 6b2490cdc5cff5c6aac854548212afabbd989f8d Mon Sep 17 00:00:00 2001
From: classabbyamp <void@placeviolette.net>
Date: Sat, 8 Jul 2023 18:28:42 -0400
Subject: [PATCH 2/3] chezmoi: temp
---
srcpkgs/chezmoi/template | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
diff --git a/srcpkgs/chezmoi/template b/srcpkgs/chezmoi/template
index 074ef8b8c602..8d2d18be6757 100644
--- a/srcpkgs/chezmoi/template
+++ b/srcpkgs/chezmoi/template
@@ -1,7 +1,7 @@
-# Template file for 'chezmoi'
+# Template file for 'chezmoiasdfsdf'
pkgname=chezmoi
version=2.34.3
-revision=1
+revision=2
build_style=go
go_import_path="github.com/twpayne/chezmoi/v2"
go_build_tags="noembeddocs noupgrade"
From 2fe908fee3e0bfafb95e857086420f5230b09793 Mon Sep 17 00:00:00 2001
From: classabbyamp <void@placeviolette.net>
Date: Sat, 8 Jul 2023 18:29:12 -0400
Subject: [PATCH 3/3] New package: foobar-. this is a test
---
srcpkgs/foobar/template | 22 ++++++++++++++++++++++
1 file changed, 22 insertions(+)
create mode 100644 srcpkgs/foobar/template
diff --git a/srcpkgs/foobar/template b/srcpkgs/foobar/template
new file mode 100644
index 000000000000..9550ea3e72de
--- /dev/null
+++ b/srcpkgs/foobar/template
@@ -0,0 +1,22 @@
+# Template file for 'foobar'
+pkgname=foobar
+version=1
+revision=1
+#archs="i686 x86_64"
+#build_wrksrc=
+build_style=meta
+#configure_args=""
+#make_build_args=""
+#make_install_args=""
+#conf_files=""
+#make_dirs="/var/log/dir 0755 root root"
+hostmakedepends=""
+makedepends=""
+depends=""
+short_desc=""
+maintainer="classabbyamp <void@placeviolette.net>"
+license="GPL-3.0-or-later"
+homepage=""
+#changelog=""
+distfiles=""
+checksum=badbadbadbadbadbadbadbadbadbadbadbadbadbadbadbadbadbadbadbadbadb
^ permalink raw reply [flat|nested] 13+ messages in thread
* Re: [PR PATCH] [Updated] common/travis/xlint: make xlint only fatal for new templates
2023-07-08 22:28 [PR PATCH] common/travis/xlint: make xlint only fatal for new templates classabbyamp
2023-07-08 22:29 ` [PR PATCH] [Updated] " classabbyamp
2023-07-08 22:41 ` classabbyamp
@ 2023-07-08 22:42 ` classabbyamp
2023-07-08 22:44 ` classabbyamp
` (8 subsequent siblings)
11 siblings, 0 replies; 13+ messages in thread
From: classabbyamp @ 2023-07-08 22:42 UTC (permalink / raw)
To: ml
[-- Attachment #1: Type: text/plain, Size: 665 bytes --]
There is an updated pull request by classabbyamp against master on the void-packages repository
https://github.com/classabbyamp/void-packages ci/xlint-nonfatal
https://github.com/void-linux/void-packages/pull/44930
common/travis/xlint: make xlint only fatal for new templates
per discussion on irc, to help updates and other changes go more smoothly, xlint should only cause a CI failure if the linted template is new.
<!-- Uncomment relevant sections and delete options which are not applicable -->
#### Testing the changes
- I tested the changes in this PR: **YES**
A patch file from https://github.com/void-linux/void-packages/pull/44930.patch is attached
[-- Warning: decoded text below may be mangled, UTF-8 assumed --]
[-- Attachment #2: github-pr-ci/xlint-nonfatal-44930.patch --]
[-- Type: text/x-diff, Size: 4406 bytes --]
From e53feff4d3d0a864925558da3d422beb74f09463 Mon Sep 17 00:00:00 2001
From: classabbyamp <void@placeviolette.net>
Date: Sat, 8 Jul 2023 18:19:43 -0400
Subject: [PATCH 1/4] common/travis/xlint: make xlint only fatal for new
templates
to help updates and other changes go more smoothly, xlint should only
cause a CI failure if the linted template is new.
---
common/travis/changed_templates.sh | 15 ++++++++++++++-
common/travis/xlint.sh | 7 ++++++-
2 files changed, 20 insertions(+), 2 deletions(-)
diff --git a/common/travis/changed_templates.sh b/common/travis/changed_templates.sh
index 91af1f1a3c1a..124ede1b1746 100755
--- a/common/travis/changed_templates.sh
+++ b/common/travis/changed_templates.sh
@@ -20,9 +20,22 @@ base="$(git merge-base origin/HEAD "$tip")"
echo "$base $tip" >/tmp/revisions
/bin/echo -e '\x1b[32mChanged packages:\x1b[0m'
-git diff-tree -r --no-renames --name-only --diff-filter=AM \
+git diff-tree -r --no-renames --name-only --diff-filter=M \
"$base" "$tip" \
-- 'srcpkgs/*/template' |
cut -d/ -f 2 |
tee /tmp/templates |
sed "s/^/ /" >&2
+/bin/echo -e '\x1b[32mNew packages:\x1b[0m'
+git diff-tree -r --no-renames --name-only --diff-filter=A \
+ "$base" "$tip" \
+ -- 'srcpkgs/*/template' |
+ cut -d/ -f 2 |
+ tee -a /tmp/templates |
+ tee /tmp/new-templates |
+ sed "s/^/ /" >&2
+
+set -x
+cat /tmp/templates
+cat /tmp/new-templates
+set +x
diff --git a/common/travis/xlint.sh b/common/travis/xlint.sh
index 790791ef1733..2f0ab673a10a 100755
--- a/common/travis/xlint.sh
+++ b/common/travis/xlint.sh
@@ -11,7 +11,12 @@ common/scripts/lint-commits $base $tip || EXITCODE=$?
for t in $(awk '{ print "srcpkgs/" $0 "/template" }' /tmp/templates); do
/bin/echo -e "\x1b[32mLinting $t...\x1b[0m"
- xlint "$t" > /tmp/xlint_out || EXITCODE=$?
+ if grep -q "srcpkgs/$t/template" /tmp/new-templates; then
+ # only fatal if xlint fails for new templates
+ xlint "$t" > /tmp/xlint_out || EXITCODE=$?
+ else
+ xlint "$t" > /tmp/xlint_out || true
+ fi
common/scripts/lint-version-change "$t" $base $tip > /tmp/vlint_out || EXITCODE=$?
awk -f common/scripts/lint2annotations.awk /tmp/xlint_out /tmp/vlint_out
done
From 6b2490cdc5cff5c6aac854548212afabbd989f8d Mon Sep 17 00:00:00 2001
From: classabbyamp <void@placeviolette.net>
Date: Sat, 8 Jul 2023 18:28:42 -0400
Subject: [PATCH 2/4] chezmoi: temp
---
srcpkgs/chezmoi/template | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
diff --git a/srcpkgs/chezmoi/template b/srcpkgs/chezmoi/template
index 074ef8b8c602..8d2d18be6757 100644
--- a/srcpkgs/chezmoi/template
+++ b/srcpkgs/chezmoi/template
@@ -1,7 +1,7 @@
-# Template file for 'chezmoi'
+# Template file for 'chezmoiasdfsdf'
pkgname=chezmoi
version=2.34.3
-revision=1
+revision=2
build_style=go
go_import_path="github.com/twpayne/chezmoi/v2"
go_build_tags="noembeddocs noupgrade"
From 2fe908fee3e0bfafb95e857086420f5230b09793 Mon Sep 17 00:00:00 2001
From: classabbyamp <void@placeviolette.net>
Date: Sat, 8 Jul 2023 18:29:12 -0400
Subject: [PATCH 3/4] New package: foobar-. this is a test
---
srcpkgs/foobar/template | 22 ++++++++++++++++++++++
1 file changed, 22 insertions(+)
create mode 100644 srcpkgs/foobar/template
diff --git a/srcpkgs/foobar/template b/srcpkgs/foobar/template
new file mode 100644
index 000000000000..9550ea3e72de
--- /dev/null
+++ b/srcpkgs/foobar/template
@@ -0,0 +1,22 @@
+# Template file for 'foobar'
+pkgname=foobar
+version=1
+revision=1
+#archs="i686 x86_64"
+#build_wrksrc=
+build_style=meta
+#configure_args=""
+#make_build_args=""
+#make_install_args=""
+#conf_files=""
+#make_dirs="/var/log/dir 0755 root root"
+hostmakedepends=""
+makedepends=""
+depends=""
+short_desc=""
+maintainer="classabbyamp <void@placeviolette.net>"
+license="GPL-3.0-or-later"
+homepage=""
+#changelog=""
+distfiles=""
+checksum=badbadbadbadbadbadbadbadbadbadbadbadbadbadbadbadbadbadbadbadbadb
From ed80d74f241b7aac472f0a14a1257c6f1a0696c3 Mon Sep 17 00:00:00 2001
From: classabbyamp <void@placeviolette.net>
Date: Sat, 8 Jul 2023 18:42:40 -0400
Subject: [PATCH 4/4] tmp
---
common/travis/xlint.sh | 1 +
1 file changed, 1 insertion(+)
diff --git a/common/travis/xlint.sh b/common/travis/xlint.sh
index 2f0ab673a10a..397a5c99354f 100755
--- a/common/travis/xlint.sh
+++ b/common/travis/xlint.sh
@@ -4,6 +4,7 @@
[ "$XLINT" ] || exit 0
+set -x
EXITCODE=0
read base tip < /tmp/revisions
^ permalink raw reply [flat|nested] 13+ messages in thread
* Re: [PR PATCH] [Updated] common/travis/xlint: make xlint only fatal for new templates
2023-07-08 22:28 [PR PATCH] common/travis/xlint: make xlint only fatal for new templates classabbyamp
` (2 preceding siblings ...)
2023-07-08 22:42 ` classabbyamp
@ 2023-07-08 22:44 ` classabbyamp
2023-07-08 22:51 ` classabbyamp
` (7 subsequent siblings)
11 siblings, 0 replies; 13+ messages in thread
From: classabbyamp @ 2023-07-08 22:44 UTC (permalink / raw)
To: ml
[-- Attachment #1: Type: text/plain, Size: 665 bytes --]
There is an updated pull request by classabbyamp against master on the void-packages repository
https://github.com/classabbyamp/void-packages ci/xlint-nonfatal
https://github.com/void-linux/void-packages/pull/44930
common/travis/xlint: make xlint only fatal for new templates
per discussion on irc, to help updates and other changes go more smoothly, xlint should only cause a CI failure if the linted template is new.
<!-- Uncomment relevant sections and delete options which are not applicable -->
#### Testing the changes
- I tested the changes in this PR: **YES**
A patch file from https://github.com/void-linux/void-packages/pull/44930.patch is attached
[-- Warning: decoded text below may be mangled, UTF-8 assumed --]
[-- Attachment #2: github-pr-ci/xlint-nonfatal-44930.patch --]
[-- Type: text/x-diff, Size: 5326 bytes --]
From e53feff4d3d0a864925558da3d422beb74f09463 Mon Sep 17 00:00:00 2001
From: classabbyamp <void@placeviolette.net>
Date: Sat, 8 Jul 2023 18:19:43 -0400
Subject: [PATCH 1/5] common/travis/xlint: make xlint only fatal for new
templates
to help updates and other changes go more smoothly, xlint should only
cause a CI failure if the linted template is new.
---
common/travis/changed_templates.sh | 15 ++++++++++++++-
common/travis/xlint.sh | 7 ++++++-
2 files changed, 20 insertions(+), 2 deletions(-)
diff --git a/common/travis/changed_templates.sh b/common/travis/changed_templates.sh
index 91af1f1a3c1a..124ede1b1746 100755
--- a/common/travis/changed_templates.sh
+++ b/common/travis/changed_templates.sh
@@ -20,9 +20,22 @@ base="$(git merge-base origin/HEAD "$tip")"
echo "$base $tip" >/tmp/revisions
/bin/echo -e '\x1b[32mChanged packages:\x1b[0m'
-git diff-tree -r --no-renames --name-only --diff-filter=AM \
+git diff-tree -r --no-renames --name-only --diff-filter=M \
"$base" "$tip" \
-- 'srcpkgs/*/template' |
cut -d/ -f 2 |
tee /tmp/templates |
sed "s/^/ /" >&2
+/bin/echo -e '\x1b[32mNew packages:\x1b[0m'
+git diff-tree -r --no-renames --name-only --diff-filter=A \
+ "$base" "$tip" \
+ -- 'srcpkgs/*/template' |
+ cut -d/ -f 2 |
+ tee -a /tmp/templates |
+ tee /tmp/new-templates |
+ sed "s/^/ /" >&2
+
+set -x
+cat /tmp/templates
+cat /tmp/new-templates
+set +x
diff --git a/common/travis/xlint.sh b/common/travis/xlint.sh
index 790791ef1733..2f0ab673a10a 100755
--- a/common/travis/xlint.sh
+++ b/common/travis/xlint.sh
@@ -11,7 +11,12 @@ common/scripts/lint-commits $base $tip || EXITCODE=$?
for t in $(awk '{ print "srcpkgs/" $0 "/template" }' /tmp/templates); do
/bin/echo -e "\x1b[32mLinting $t...\x1b[0m"
- xlint "$t" > /tmp/xlint_out || EXITCODE=$?
+ if grep -q "srcpkgs/$t/template" /tmp/new-templates; then
+ # only fatal if xlint fails for new templates
+ xlint "$t" > /tmp/xlint_out || EXITCODE=$?
+ else
+ xlint "$t" > /tmp/xlint_out || true
+ fi
common/scripts/lint-version-change "$t" $base $tip > /tmp/vlint_out || EXITCODE=$?
awk -f common/scripts/lint2annotations.awk /tmp/xlint_out /tmp/vlint_out
done
From 6b2490cdc5cff5c6aac854548212afabbd989f8d Mon Sep 17 00:00:00 2001
From: classabbyamp <void@placeviolette.net>
Date: Sat, 8 Jul 2023 18:28:42 -0400
Subject: [PATCH 2/5] chezmoi: temp
---
srcpkgs/chezmoi/template | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
diff --git a/srcpkgs/chezmoi/template b/srcpkgs/chezmoi/template
index 074ef8b8c602..8d2d18be6757 100644
--- a/srcpkgs/chezmoi/template
+++ b/srcpkgs/chezmoi/template
@@ -1,7 +1,7 @@
-# Template file for 'chezmoi'
+# Template file for 'chezmoiasdfsdf'
pkgname=chezmoi
version=2.34.3
-revision=1
+revision=2
build_style=go
go_import_path="github.com/twpayne/chezmoi/v2"
go_build_tags="noembeddocs noupgrade"
From 2fe908fee3e0bfafb95e857086420f5230b09793 Mon Sep 17 00:00:00 2001
From: classabbyamp <void@placeviolette.net>
Date: Sat, 8 Jul 2023 18:29:12 -0400
Subject: [PATCH 3/5] New package: foobar-. this is a test
---
srcpkgs/foobar/template | 22 ++++++++++++++++++++++
1 file changed, 22 insertions(+)
create mode 100644 srcpkgs/foobar/template
diff --git a/srcpkgs/foobar/template b/srcpkgs/foobar/template
new file mode 100644
index 000000000000..9550ea3e72de
--- /dev/null
+++ b/srcpkgs/foobar/template
@@ -0,0 +1,22 @@
+# Template file for 'foobar'
+pkgname=foobar
+version=1
+revision=1
+#archs="i686 x86_64"
+#build_wrksrc=
+build_style=meta
+#configure_args=""
+#make_build_args=""
+#make_install_args=""
+#conf_files=""
+#make_dirs="/var/log/dir 0755 root root"
+hostmakedepends=""
+makedepends=""
+depends=""
+short_desc=""
+maintainer="classabbyamp <void@placeviolette.net>"
+license="GPL-3.0-or-later"
+homepage=""
+#changelog=""
+distfiles=""
+checksum=badbadbadbadbadbadbadbadbadbadbadbadbadbadbadbadbadbadbadbadbadb
From ed80d74f241b7aac472f0a14a1257c6f1a0696c3 Mon Sep 17 00:00:00 2001
From: classabbyamp <void@placeviolette.net>
Date: Sat, 8 Jul 2023 18:42:40 -0400
Subject: [PATCH 4/5] tmp
---
common/travis/xlint.sh | 1 +
1 file changed, 1 insertion(+)
diff --git a/common/travis/xlint.sh b/common/travis/xlint.sh
index 2f0ab673a10a..397a5c99354f 100755
--- a/common/travis/xlint.sh
+++ b/common/travis/xlint.sh
@@ -4,6 +4,7 @@
[ "$XLINT" ] || exit 0
+set -x
EXITCODE=0
read base tip < /tmp/revisions
From f0cde73b21c8666e1c53b0347315bfe7ddbd266f Mon Sep 17 00:00:00 2001
From: classabbyamp <void@placeviolette.net>
Date: Sat, 8 Jul 2023 18:44:46 -0400
Subject: [PATCH 5/5] tmp
---
srcpkgs/foobar/template | 12 ++++++------
1 file changed, 6 insertions(+), 6 deletions(-)
diff --git a/srcpkgs/foobar/template b/srcpkgs/foobar/template
index 9550ea3e72de..bb27fee2a740 100644
--- a/srcpkgs/foobar/template
+++ b/srcpkgs/foobar/template
@@ -10,13 +10,13 @@ build_style=meta
#make_install_args=""
#conf_files=""
#make_dirs="/var/log/dir 0755 root root"
-hostmakedepends=""
-makedepends=""
-depends=""
-short_desc=""
+# hostmakedepends=""
+# makedepends=""
+# depends=""
+short_desc="Blah"
maintainer="classabbyamp <void@placeviolette.net>"
license="GPL-3.0-or-later"
-homepage=""
+homepage="a"
#changelog=""
-distfiles=""
+# distfiles=""
checksum=badbadbadbadbadbadbadbadbadbadbadbadbadbadbadbadbadbadbadbadbadb
^ permalink raw reply [flat|nested] 13+ messages in thread
* Re: [PR PATCH] [Updated] common/travis/xlint: make xlint only fatal for new templates
2023-07-08 22:28 [PR PATCH] common/travis/xlint: make xlint only fatal for new templates classabbyamp
` (3 preceding siblings ...)
2023-07-08 22:44 ` classabbyamp
@ 2023-07-08 22:51 ` classabbyamp
2023-07-08 22:53 ` classabbyamp
` (6 subsequent siblings)
11 siblings, 0 replies; 13+ messages in thread
From: classabbyamp @ 2023-07-08 22:51 UTC (permalink / raw)
To: ml
[-- Attachment #1: Type: text/plain, Size: 665 bytes --]
There is an updated pull request by classabbyamp against master on the void-packages repository
https://github.com/classabbyamp/void-packages ci/xlint-nonfatal
https://github.com/void-linux/void-packages/pull/44930
common/travis/xlint: make xlint only fatal for new templates
per discussion on irc, to help updates and other changes go more smoothly, xlint should only cause a CI failure if the linted template is new.
<!-- Uncomment relevant sections and delete options which are not applicable -->
#### Testing the changes
- I tested the changes in this PR: **YES**
A patch file from https://github.com/void-linux/void-packages/pull/44930.patch is attached
[-- Warning: decoded text below may be mangled, UTF-8 assumed --]
[-- Attachment #2: github-pr-ci/xlint-nonfatal-44930.patch --]
[-- Type: text/x-diff, Size: 4121 bytes --]
From 51c28a4316839e4b639ee649682695e637742d83 Mon Sep 17 00:00:00 2001
From: classabbyamp <void@placeviolette.net>
Date: Sat, 8 Jul 2023 18:19:43 -0400
Subject: [PATCH 1/3] common/travis/xlint: make xlint only fatal for new
templates
to help updates and other changes go more smoothly, xlint should only
cause a CI failure if the linted template is new.
---
common/travis/changed_templates.sh | 15 ++++++++++++++-
common/travis/xlint.sh | 10 ++++++++--
2 files changed, 22 insertions(+), 3 deletions(-)
diff --git a/common/travis/changed_templates.sh b/common/travis/changed_templates.sh
index 91af1f1a3c1a..124ede1b1746 100755
--- a/common/travis/changed_templates.sh
+++ b/common/travis/changed_templates.sh
@@ -20,9 +20,22 @@ base="$(git merge-base origin/HEAD "$tip")"
echo "$base $tip" >/tmp/revisions
/bin/echo -e '\x1b[32mChanged packages:\x1b[0m'
-git diff-tree -r --no-renames --name-only --diff-filter=AM \
+git diff-tree -r --no-renames --name-only --diff-filter=M \
"$base" "$tip" \
-- 'srcpkgs/*/template' |
cut -d/ -f 2 |
tee /tmp/templates |
sed "s/^/ /" >&2
+/bin/echo -e '\x1b[32mNew packages:\x1b[0m'
+git diff-tree -r --no-renames --name-only --diff-filter=A \
+ "$base" "$tip" \
+ -- 'srcpkgs/*/template' |
+ cut -d/ -f 2 |
+ tee -a /tmp/templates |
+ tee /tmp/new-templates |
+ sed "s/^/ /" >&2
+
+set -x
+cat /tmp/templates
+cat /tmp/new-templates
+set +x
diff --git a/common/travis/xlint.sh b/common/travis/xlint.sh
index 790791ef1733..78313c252ef2 100755
--- a/common/travis/xlint.sh
+++ b/common/travis/xlint.sh
@@ -4,6 +4,7 @@
[ "$XLINT" ] || exit 0
+set -x
EXITCODE=0
read base tip < /tmp/revisions
@@ -11,8 +12,13 @@ common/scripts/lint-commits $base $tip || EXITCODE=$?
for t in $(awk '{ print "srcpkgs/" $0 "/template" }' /tmp/templates); do
/bin/echo -e "\x1b[32mLinting $t...\x1b[0m"
- xlint "$t" > /tmp/xlint_out || EXITCODE=$?
- common/scripts/lint-version-change "$t" $base $tip > /tmp/vlint_out || EXITCODE=$?
+ if grep -q "^$t\$" /tmp/new-templates; then
+ # only fatal if xlint fails for new templates
+ xlint "$t" > /tmp/xlint_out || EXITCODE=$?
+ else
+ xlint "$t" > /tmp/xlint_out || true
+ fi
+ common/scripts/lint-version-change "srcpkgs/$t/template" $base $tip > /tmp/vlint_out || EXITCODE=$?
awk -f common/scripts/lint2annotations.awk /tmp/xlint_out /tmp/vlint_out
done
exit $EXITCODE
From 729746d14e0cb823ccb00482901683b8d421ab66 Mon Sep 17 00:00:00 2001
From: classabbyamp <void@placeviolette.net>
Date: Sat, 8 Jul 2023 18:28:42 -0400
Subject: [PATCH 2/3] chezmoi: temp
---
srcpkgs/chezmoi/template | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
diff --git a/srcpkgs/chezmoi/template b/srcpkgs/chezmoi/template
index 074ef8b8c602..8d2d18be6757 100644
--- a/srcpkgs/chezmoi/template
+++ b/srcpkgs/chezmoi/template
@@ -1,7 +1,7 @@
-# Template file for 'chezmoi'
+# Template file for 'chezmoiasdfsdf'
pkgname=chezmoi
version=2.34.3
-revision=1
+revision=2
build_style=go
go_import_path="github.com/twpayne/chezmoi/v2"
go_build_tags="noembeddocs noupgrade"
From dbc2e205f9e8456ed9b87ee1d521e861b597354f Mon Sep 17 00:00:00 2001
From: classabbyamp <void@placeviolette.net>
Date: Sat, 8 Jul 2023 18:29:12 -0400
Subject: [PATCH 3/3] New package: foobar-. this is a test
---
srcpkgs/foobar/template | 22 ++++++++++++++++++++++
1 file changed, 22 insertions(+)
create mode 100644 srcpkgs/foobar/template
diff --git a/srcpkgs/foobar/template b/srcpkgs/foobar/template
new file mode 100644
index 000000000000..bb27fee2a740
--- /dev/null
+++ b/srcpkgs/foobar/template
@@ -0,0 +1,22 @@
+# Template file for 'foobar'
+pkgname=foobar
+version=1
+revision=1
+#archs="i686 x86_64"
+#build_wrksrc=
+build_style=meta
+#configure_args=""
+#make_build_args=""
+#make_install_args=""
+#conf_files=""
+#make_dirs="/var/log/dir 0755 root root"
+# hostmakedepends=""
+# makedepends=""
+# depends=""
+short_desc="Blah"
+maintainer="classabbyamp <void@placeviolette.net>"
+license="GPL-3.0-or-later"
+homepage="a"
+#changelog=""
+# distfiles=""
+checksum=badbadbadbadbadbadbadbadbadbadbadbadbadbadbadbadbadbadbadbadbadb
^ permalink raw reply [flat|nested] 13+ messages in thread
* Re: [PR PATCH] [Updated] common/travis/xlint: make xlint only fatal for new templates
2023-07-08 22:28 [PR PATCH] common/travis/xlint: make xlint only fatal for new templates classabbyamp
` (4 preceding siblings ...)
2023-07-08 22:51 ` classabbyamp
@ 2023-07-08 22:53 ` classabbyamp
2023-07-08 22:55 ` classabbyamp
` (5 subsequent siblings)
11 siblings, 0 replies; 13+ messages in thread
From: classabbyamp @ 2023-07-08 22:53 UTC (permalink / raw)
To: ml
[-- Attachment #1: Type: text/plain, Size: 665 bytes --]
There is an updated pull request by classabbyamp against master on the void-packages repository
https://github.com/classabbyamp/void-packages ci/xlint-nonfatal
https://github.com/void-linux/void-packages/pull/44930
common/travis/xlint: make xlint only fatal for new templates
per discussion on irc, to help updates and other changes go more smoothly, xlint should only cause a CI failure if the linted template is new.
<!-- Uncomment relevant sections and delete options which are not applicable -->
#### Testing the changes
- I tested the changes in this PR: **YES**
A patch file from https://github.com/void-linux/void-packages/pull/44930.patch is attached
[-- Warning: decoded text below may be mangled, UTF-8 assumed --]
[-- Attachment #2: github-pr-ci/xlint-nonfatal-44930.patch --]
[-- Type: text/x-diff, Size: 4992 bytes --]
From 51c28a4316839e4b639ee649682695e637742d83 Mon Sep 17 00:00:00 2001
From: classabbyamp <void@placeviolette.net>
Date: Sat, 8 Jul 2023 18:19:43 -0400
Subject: [PATCH 1/3] common/travis/xlint: make xlint only fatal for new
templates
to help updates and other changes go more smoothly, xlint should only
cause a CI failure if the linted template is new.
---
common/travis/changed_templates.sh | 15 ++++++++++++++-
common/travis/xlint.sh | 10 ++++++++--
2 files changed, 22 insertions(+), 3 deletions(-)
diff --git a/common/travis/changed_templates.sh b/common/travis/changed_templates.sh
index 91af1f1a3c1a..124ede1b1746 100755
--- a/common/travis/changed_templates.sh
+++ b/common/travis/changed_templates.sh
@@ -20,9 +20,22 @@ base="$(git merge-base origin/HEAD "$tip")"
echo "$base $tip" >/tmp/revisions
/bin/echo -e '\x1b[32mChanged packages:\x1b[0m'
-git diff-tree -r --no-renames --name-only --diff-filter=AM \
+git diff-tree -r --no-renames --name-only --diff-filter=M \
"$base" "$tip" \
-- 'srcpkgs/*/template' |
cut -d/ -f 2 |
tee /tmp/templates |
sed "s/^/ /" >&2
+/bin/echo -e '\x1b[32mNew packages:\x1b[0m'
+git diff-tree -r --no-renames --name-only --diff-filter=A \
+ "$base" "$tip" \
+ -- 'srcpkgs/*/template' |
+ cut -d/ -f 2 |
+ tee -a /tmp/templates |
+ tee /tmp/new-templates |
+ sed "s/^/ /" >&2
+
+set -x
+cat /tmp/templates
+cat /tmp/new-templates
+set +x
diff --git a/common/travis/xlint.sh b/common/travis/xlint.sh
index 790791ef1733..78313c252ef2 100755
--- a/common/travis/xlint.sh
+++ b/common/travis/xlint.sh
@@ -4,6 +4,7 @@
[ "$XLINT" ] || exit 0
+set -x
EXITCODE=0
read base tip < /tmp/revisions
@@ -11,8 +12,13 @@ common/scripts/lint-commits $base $tip || EXITCODE=$?
for t in $(awk '{ print "srcpkgs/" $0 "/template" }' /tmp/templates); do
/bin/echo -e "\x1b[32mLinting $t...\x1b[0m"
- xlint "$t" > /tmp/xlint_out || EXITCODE=$?
- common/scripts/lint-version-change "$t" $base $tip > /tmp/vlint_out || EXITCODE=$?
+ if grep -q "^$t\$" /tmp/new-templates; then
+ # only fatal if xlint fails for new templates
+ xlint "$t" > /tmp/xlint_out || EXITCODE=$?
+ else
+ xlint "$t" > /tmp/xlint_out || true
+ fi
+ common/scripts/lint-version-change "srcpkgs/$t/template" $base $tip > /tmp/vlint_out || EXITCODE=$?
awk -f common/scripts/lint2annotations.awk /tmp/xlint_out /tmp/vlint_out
done
exit $EXITCODE
From 729746d14e0cb823ccb00482901683b8d421ab66 Mon Sep 17 00:00:00 2001
From: classabbyamp <void@placeviolette.net>
Date: Sat, 8 Jul 2023 18:28:42 -0400
Subject: [PATCH 2/3] chezmoi: temp
---
srcpkgs/chezmoi/template | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
diff --git a/srcpkgs/chezmoi/template b/srcpkgs/chezmoi/template
index 074ef8b8c602..8d2d18be6757 100644
--- a/srcpkgs/chezmoi/template
+++ b/srcpkgs/chezmoi/template
@@ -1,7 +1,7 @@
-# Template file for 'chezmoi'
+# Template file for 'chezmoiasdfsdf'
pkgname=chezmoi
version=2.34.3
-revision=1
+revision=2
build_style=go
go_import_path="github.com/twpayne/chezmoi/v2"
go_build_tags="noembeddocs noupgrade"
From 33dd87f6f5b5e199096d05c100867365ae4ba9a3 Mon Sep 17 00:00:00 2001
From: classabbyamp <void@placeviolette.net>
Date: Sat, 8 Jul 2023 18:29:12 -0400
Subject: [PATCH 3/3] New package: foobar-. this is a test
---
common/travis/xlint.sh | 4 ++--
srcpkgs/foobar/template | 22 ++++++++++++++++++++++
2 files changed, 24 insertions(+), 2 deletions(-)
create mode 100644 srcpkgs/foobar/template
diff --git a/common/travis/xlint.sh b/common/travis/xlint.sh
index 78313c252ef2..a5303d9129c9 100755
--- a/common/travis/xlint.sh
+++ b/common/travis/xlint.sh
@@ -10,7 +10,7 @@ read base tip < /tmp/revisions
common/scripts/lint-commits $base $tip || EXITCODE=$?
-for t in $(awk '{ print "srcpkgs/" $0 "/template" }' /tmp/templates); do
+while read -r t; do
/bin/echo -e "\x1b[32mLinting $t...\x1b[0m"
if grep -q "^$t\$" /tmp/new-templates; then
# only fatal if xlint fails for new templates
@@ -20,5 +20,5 @@ for t in $(awk '{ print "srcpkgs/" $0 "/template" }' /tmp/templates); do
fi
common/scripts/lint-version-change "srcpkgs/$t/template" $base $tip > /tmp/vlint_out || EXITCODE=$?
awk -f common/scripts/lint2annotations.awk /tmp/xlint_out /tmp/vlint_out
-done
+done < /tmp/templates
exit $EXITCODE
diff --git a/srcpkgs/foobar/template b/srcpkgs/foobar/template
new file mode 100644
index 000000000000..a96d3009df16
--- /dev/null
+++ b/srcpkgs/foobar/template
@@ -0,0 +1,22 @@
+# Template file for 'foobar'
+pkgname=foobar
+version=1
+revision=1
+#archs="i686 x86_64"
+#build_wrksrc=
+build_style=meta
+#configure_args=""
+#make_build_args=""
+#make_install_args=""
+#conf_files=""
+#make_dirs="/var/log/dir 0755 root root"
+# hostmakedepends=""
+# makedepends=""
+depends=""
+short_desc="Blah"
+maintainer="classabbyamp <void@placeviolette.net>"
+license="GPL-3.0-or-later"
+homepage="a"
+#changelog=""
+# distfiles=""
+checksum=badbadbadbadbadbadbadbadbadbadbadbadbadbadbadbadbadbadbadbadbadb
^ permalink raw reply [flat|nested] 13+ messages in thread
* Re: [PR PATCH] [Updated] common/travis/xlint: make xlint only fatal for new templates
2023-07-08 22:28 [PR PATCH] common/travis/xlint: make xlint only fatal for new templates classabbyamp
` (5 preceding siblings ...)
2023-07-08 22:53 ` classabbyamp
@ 2023-07-08 22:55 ` classabbyamp
2023-07-08 22:58 ` classabbyamp
` (4 subsequent siblings)
11 siblings, 0 replies; 13+ messages in thread
From: classabbyamp @ 2023-07-08 22:55 UTC (permalink / raw)
To: ml
[-- Attachment #1: Type: text/plain, Size: 665 bytes --]
There is an updated pull request by classabbyamp against master on the void-packages repository
https://github.com/classabbyamp/void-packages ci/xlint-nonfatal
https://github.com/void-linux/void-packages/pull/44930
common/travis/xlint: make xlint only fatal for new templates
per discussion on irc, to help updates and other changes go more smoothly, xlint should only cause a CI failure if the linted template is new.
<!-- Uncomment relevant sections and delete options which are not applicable -->
#### Testing the changes
- I tested the changes in this PR: **YES**
A patch file from https://github.com/void-linux/void-packages/pull/44930.patch is attached
[-- Warning: decoded text below may be mangled, UTF-8 assumed --]
[-- Attachment #2: github-pr-ci/xlint-nonfatal-44930.patch --]
[-- Type: text/x-diff, Size: 2380 bytes --]
From 51c28a4316839e4b639ee649682695e637742d83 Mon Sep 17 00:00:00 2001
From: classabbyamp <void@placeviolette.net>
Date: Sat, 8 Jul 2023 18:19:43 -0400
Subject: [PATCH] common/travis/xlint: make xlint only fatal for new templates
to help updates and other changes go more smoothly, xlint should only
cause a CI failure if the linted template is new.
---
common/travis/changed_templates.sh | 15 ++++++++++++++-
common/travis/xlint.sh | 10 ++++++++--
2 files changed, 22 insertions(+), 3 deletions(-)
diff --git a/common/travis/changed_templates.sh b/common/travis/changed_templates.sh
index 91af1f1a3c1a..124ede1b1746 100755
--- a/common/travis/changed_templates.sh
+++ b/common/travis/changed_templates.sh
@@ -20,9 +20,22 @@ base="$(git merge-base origin/HEAD "$tip")"
echo "$base $tip" >/tmp/revisions
/bin/echo -e '\x1b[32mChanged packages:\x1b[0m'
-git diff-tree -r --no-renames --name-only --diff-filter=AM \
+git diff-tree -r --no-renames --name-only --diff-filter=M \
"$base" "$tip" \
-- 'srcpkgs/*/template' |
cut -d/ -f 2 |
tee /tmp/templates |
sed "s/^/ /" >&2
+/bin/echo -e '\x1b[32mNew packages:\x1b[0m'
+git diff-tree -r --no-renames --name-only --diff-filter=A \
+ "$base" "$tip" \
+ -- 'srcpkgs/*/template' |
+ cut -d/ -f 2 |
+ tee -a /tmp/templates |
+ tee /tmp/new-templates |
+ sed "s/^/ /" >&2
+
+set -x
+cat /tmp/templates
+cat /tmp/new-templates
+set +x
diff --git a/common/travis/xlint.sh b/common/travis/xlint.sh
index 790791ef1733..78313c252ef2 100755
--- a/common/travis/xlint.sh
+++ b/common/travis/xlint.sh
@@ -4,6 +4,7 @@
[ "$XLINT" ] || exit 0
+set -x
EXITCODE=0
read base tip < /tmp/revisions
@@ -11,8 +12,13 @@ common/scripts/lint-commits $base $tip || EXITCODE=$?
for t in $(awk '{ print "srcpkgs/" $0 "/template" }' /tmp/templates); do
/bin/echo -e "\x1b[32mLinting $t...\x1b[0m"
- xlint "$t" > /tmp/xlint_out || EXITCODE=$?
- common/scripts/lint-version-change "$t" $base $tip > /tmp/vlint_out || EXITCODE=$?
+ if grep -q "^$t\$" /tmp/new-templates; then
+ # only fatal if xlint fails for new templates
+ xlint "$t" > /tmp/xlint_out || EXITCODE=$?
+ else
+ xlint "$t" > /tmp/xlint_out || true
+ fi
+ common/scripts/lint-version-change "srcpkgs/$t/template" $base $tip > /tmp/vlint_out || EXITCODE=$?
awk -f common/scripts/lint2annotations.awk /tmp/xlint_out /tmp/vlint_out
done
exit $EXITCODE
^ permalink raw reply [flat|nested] 13+ messages in thread
* Re: [PR PATCH] [Updated] common/travis/xlint: make xlint only fatal for new templates
2023-07-08 22:28 [PR PATCH] common/travis/xlint: make xlint only fatal for new templates classabbyamp
` (6 preceding siblings ...)
2023-07-08 22:55 ` classabbyamp
@ 2023-07-08 22:58 ` classabbyamp
2023-07-08 23:00 ` classabbyamp
` (3 subsequent siblings)
11 siblings, 0 replies; 13+ messages in thread
From: classabbyamp @ 2023-07-08 22:58 UTC (permalink / raw)
To: ml
[-- Attachment #1: Type: text/plain, Size: 665 bytes --]
There is an updated pull request by classabbyamp against master on the void-packages repository
https://github.com/classabbyamp/void-packages ci/xlint-nonfatal
https://github.com/void-linux/void-packages/pull/44930
common/travis/xlint: make xlint only fatal for new templates
per discussion on irc, to help updates and other changes go more smoothly, xlint should only cause a CI failure if the linted template is new.
<!-- Uncomment relevant sections and delete options which are not applicable -->
#### Testing the changes
- I tested the changes in this PR: **YES**
A patch file from https://github.com/void-linux/void-packages/pull/44930.patch is attached
[-- Warning: decoded text below may be mangled, UTF-8 assumed --]
[-- Attachment #2: github-pr-ci/xlint-nonfatal-44930.patch --]
[-- Type: text/x-diff, Size: 2214 bytes --]
From a1afe16e8cd3cbdd1cc9326ced48fc1db414e7bc Mon Sep 17 00:00:00 2001
From: classabbyamp <void@placeviolette.net>
Date: Sat, 8 Jul 2023 18:19:43 -0400
Subject: [PATCH] common/travis/xlint: make xlint only fatal for new templates
to help updates and other changes go more smoothly, xlint should only
cause a CI failure if the linted template is new.
---
common/travis/changed_templates.sh | 10 +++++++++-
common/travis/xlint.sh | 9 +++++++--
2 files changed, 16 insertions(+), 3 deletions(-)
diff --git a/common/travis/changed_templates.sh b/common/travis/changed_templates.sh
index 91af1f1a3c1a..c54b76e92e85 100755
--- a/common/travis/changed_templates.sh
+++ b/common/travis/changed_templates.sh
@@ -20,9 +20,17 @@ base="$(git merge-base origin/HEAD "$tip")"
echo "$base $tip" >/tmp/revisions
/bin/echo -e '\x1b[32mChanged packages:\x1b[0m'
-git diff-tree -r --no-renames --name-only --diff-filter=AM \
+git diff-tree -r --no-renames --name-only --diff-filter=M \
"$base" "$tip" \
-- 'srcpkgs/*/template' |
cut -d/ -f 2 |
tee /tmp/templates |
sed "s/^/ /" >&2
+/bin/echo -e '\x1b[32mNew packages:\x1b[0m'
+git diff-tree -r --no-renames --name-only --diff-filter=A \
+ "$base" "$tip" \
+ -- 'srcpkgs/*/template' |
+ cut -d/ -f 2 |
+ tee -a /tmp/templates |
+ tee /tmp/new-templates |
+ sed "s/^/ /" >&2
diff --git a/common/travis/xlint.sh b/common/travis/xlint.sh
index 790791ef1733..f201dbd15772 100755
--- a/common/travis/xlint.sh
+++ b/common/travis/xlint.sh
@@ -11,8 +11,13 @@ common/scripts/lint-commits $base $tip || EXITCODE=$?
for t in $(awk '{ print "srcpkgs/" $0 "/template" }' /tmp/templates); do
/bin/echo -e "\x1b[32mLinting $t...\x1b[0m"
- xlint "$t" > /tmp/xlint_out || EXITCODE=$?
- common/scripts/lint-version-change "$t" $base $tip > /tmp/vlint_out || EXITCODE=$?
+ if grep -q "^$t\$" /tmp/new-templates; then
+ # only fatal if xlint fails for new templates
+ xlint "$t" > /tmp/xlint_out || EXITCODE=$?
+ else
+ xlint "$t" > /tmp/xlint_out || true
+ fi
+ common/scripts/lint-version-change "srcpkgs/$t/template" $base $tip > /tmp/vlint_out || EXITCODE=$?
awk -f common/scripts/lint2annotations.awk /tmp/xlint_out /tmp/vlint_out
done
exit $EXITCODE
^ permalink raw reply [flat|nested] 13+ messages in thread
* Re: [PR PATCH] [Updated] common/travis/xlint: make xlint only fatal for new templates
2023-07-08 22:28 [PR PATCH] common/travis/xlint: make xlint only fatal for new templates classabbyamp
` (7 preceding siblings ...)
2023-07-08 22:58 ` classabbyamp
@ 2023-07-08 23:00 ` classabbyamp
2023-07-08 23:02 ` classabbyamp
` (2 subsequent siblings)
11 siblings, 0 replies; 13+ messages in thread
From: classabbyamp @ 2023-07-08 23:00 UTC (permalink / raw)
To: ml
[-- Attachment #1: Type: text/plain, Size: 665 bytes --]
There is an updated pull request by classabbyamp against master on the void-packages repository
https://github.com/classabbyamp/void-packages ci/xlint-nonfatal
https://github.com/void-linux/void-packages/pull/44930
common/travis/xlint: make xlint only fatal for new templates
per discussion on irc, to help updates and other changes go more smoothly, xlint should only cause a CI failure if the linted template is new.
<!-- Uncomment relevant sections and delete options which are not applicable -->
#### Testing the changes
- I tested the changes in this PR: **YES**
A patch file from https://github.com/void-linux/void-packages/pull/44930.patch is attached
[-- Warning: decoded text below may be mangled, UTF-8 assumed --]
[-- Attachment #2: github-pr-ci/xlint-nonfatal-44930.patch --]
[-- Type: text/x-diff, Size: 2909 bytes --]
From a1afe16e8cd3cbdd1cc9326ced48fc1db414e7bc Mon Sep 17 00:00:00 2001
From: classabbyamp <void@placeviolette.net>
Date: Sat, 8 Jul 2023 18:19:43 -0400
Subject: [PATCH 1/2] common/travis/xlint: make xlint only fatal for new
templates
to help updates and other changes go more smoothly, xlint should only
cause a CI failure if the linted template is new.
---
common/travis/changed_templates.sh | 10 +++++++++-
common/travis/xlint.sh | 9 +++++++--
2 files changed, 16 insertions(+), 3 deletions(-)
diff --git a/common/travis/changed_templates.sh b/common/travis/changed_templates.sh
index 91af1f1a3c1a..c54b76e92e85 100755
--- a/common/travis/changed_templates.sh
+++ b/common/travis/changed_templates.sh
@@ -20,9 +20,17 @@ base="$(git merge-base origin/HEAD "$tip")"
echo "$base $tip" >/tmp/revisions
/bin/echo -e '\x1b[32mChanged packages:\x1b[0m'
-git diff-tree -r --no-renames --name-only --diff-filter=AM \
+git diff-tree -r --no-renames --name-only --diff-filter=M \
"$base" "$tip" \
-- 'srcpkgs/*/template' |
cut -d/ -f 2 |
tee /tmp/templates |
sed "s/^/ /" >&2
+/bin/echo -e '\x1b[32mNew packages:\x1b[0m'
+git diff-tree -r --no-renames --name-only --diff-filter=A \
+ "$base" "$tip" \
+ -- 'srcpkgs/*/template' |
+ cut -d/ -f 2 |
+ tee -a /tmp/templates |
+ tee /tmp/new-templates |
+ sed "s/^/ /" >&2
diff --git a/common/travis/xlint.sh b/common/travis/xlint.sh
index 790791ef1733..f201dbd15772 100755
--- a/common/travis/xlint.sh
+++ b/common/travis/xlint.sh
@@ -11,8 +11,13 @@ common/scripts/lint-commits $base $tip || EXITCODE=$?
for t in $(awk '{ print "srcpkgs/" $0 "/template" }' /tmp/templates); do
/bin/echo -e "\x1b[32mLinting $t...\x1b[0m"
- xlint "$t" > /tmp/xlint_out || EXITCODE=$?
- common/scripts/lint-version-change "$t" $base $tip > /tmp/vlint_out || EXITCODE=$?
+ if grep -q "^$t\$" /tmp/new-templates; then
+ # only fatal if xlint fails for new templates
+ xlint "$t" > /tmp/xlint_out || EXITCODE=$?
+ else
+ xlint "$t" > /tmp/xlint_out || true
+ fi
+ common/scripts/lint-version-change "srcpkgs/$t/template" $base $tip > /tmp/vlint_out || EXITCODE=$?
awk -f common/scripts/lint2annotations.awk /tmp/xlint_out /tmp/vlint_out
done
exit $EXITCODE
From 610b85e10fc407f62196ad8e9fd6e165c5532df0 Mon Sep 17 00:00:00 2001
From: classabbyamp <void@placeviolette.net>
Date: Sat, 8 Jul 2023 18:59:53 -0400
Subject: [PATCH 2/2] chezmoi: tmp
---
srcpkgs/chezmoi/template | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
diff --git a/srcpkgs/chezmoi/template b/srcpkgs/chezmoi/template
index 074ef8b8c602..4eeea8eb9695 100644
--- a/srcpkgs/chezmoi/template
+++ b/srcpkgs/chezmoi/template
@@ -1,7 +1,7 @@
-# Template file for 'chezmoi'
+# Template file for 'chezmoiasdfsdfa'
pkgname=chezmoi
version=2.34.3
-revision=1
+revision=2
build_style=go
go_import_path="github.com/twpayne/chezmoi/v2"
go_build_tags="noembeddocs noupgrade"
^ permalink raw reply [flat|nested] 13+ messages in thread
* Re: [PR PATCH] [Updated] common/travis/xlint: make xlint only fatal for new templates
2023-07-08 22:28 [PR PATCH] common/travis/xlint: make xlint only fatal for new templates classabbyamp
` (8 preceding siblings ...)
2023-07-08 23:00 ` classabbyamp
@ 2023-07-08 23:02 ` classabbyamp
2023-10-07 1:45 ` github-actions
2023-10-22 1:46 ` [PR PATCH] [Closed]: " github-actions
11 siblings, 0 replies; 13+ messages in thread
From: classabbyamp @ 2023-07-08 23:02 UTC (permalink / raw)
To: ml
[-- Attachment #1: Type: text/plain, Size: 1078 bytes --]
There is an updated pull request by classabbyamp against master on the void-packages repository
https://github.com/classabbyamp/void-packages ci/xlint-nonfatal
https://github.com/void-linux/void-packages/pull/44930
common/travis/xlint: make xlint only fatal for new templates
per discussion on irc, to help updates and other changes go more smoothly, xlint should only cause a CI failure if the linted template is new.
examples:
- succeeds because only a changed template errors: https://github.com/void-linux/void-packages/actions/runs/5496798220/jobs/10017025380
- fails because of a new package with errors: https://github.com/void-linux/void-packages/actions/runs/5496783595/jobs/10017001341
this does not affect the *reporting* of lint issues, those are still produced as annotations on the 'files changed' tab.
<!-- Uncomment relevant sections and delete options which are not applicable -->
#### Testing the changes
- I tested the changes in this PR: **YES**
A patch file from https://github.com/void-linux/void-packages/pull/44930.patch is attached
[-- Warning: decoded text below may be mangled, UTF-8 assumed --]
[-- Attachment #2: github-pr-ci/xlint-nonfatal-44930.patch --]
[-- Type: text/x-diff, Size: 2214 bytes --]
From a1afe16e8cd3cbdd1cc9326ced48fc1db414e7bc Mon Sep 17 00:00:00 2001
From: classabbyamp <void@placeviolette.net>
Date: Sat, 8 Jul 2023 18:19:43 -0400
Subject: [PATCH] common/travis/xlint: make xlint only fatal for new templates
to help updates and other changes go more smoothly, xlint should only
cause a CI failure if the linted template is new.
---
common/travis/changed_templates.sh | 10 +++++++++-
common/travis/xlint.sh | 9 +++++++--
2 files changed, 16 insertions(+), 3 deletions(-)
diff --git a/common/travis/changed_templates.sh b/common/travis/changed_templates.sh
index 91af1f1a3c1a..c54b76e92e85 100755
--- a/common/travis/changed_templates.sh
+++ b/common/travis/changed_templates.sh
@@ -20,9 +20,17 @@ base="$(git merge-base origin/HEAD "$tip")"
echo "$base $tip" >/tmp/revisions
/bin/echo -e '\x1b[32mChanged packages:\x1b[0m'
-git diff-tree -r --no-renames --name-only --diff-filter=AM \
+git diff-tree -r --no-renames --name-only --diff-filter=M \
"$base" "$tip" \
-- 'srcpkgs/*/template' |
cut -d/ -f 2 |
tee /tmp/templates |
sed "s/^/ /" >&2
+/bin/echo -e '\x1b[32mNew packages:\x1b[0m'
+git diff-tree -r --no-renames --name-only --diff-filter=A \
+ "$base" "$tip" \
+ -- 'srcpkgs/*/template' |
+ cut -d/ -f 2 |
+ tee -a /tmp/templates |
+ tee /tmp/new-templates |
+ sed "s/^/ /" >&2
diff --git a/common/travis/xlint.sh b/common/travis/xlint.sh
index 790791ef1733..f201dbd15772 100755
--- a/common/travis/xlint.sh
+++ b/common/travis/xlint.sh
@@ -11,8 +11,13 @@ common/scripts/lint-commits $base $tip || EXITCODE=$?
for t in $(awk '{ print "srcpkgs/" $0 "/template" }' /tmp/templates); do
/bin/echo -e "\x1b[32mLinting $t...\x1b[0m"
- xlint "$t" > /tmp/xlint_out || EXITCODE=$?
- common/scripts/lint-version-change "$t" $base $tip > /tmp/vlint_out || EXITCODE=$?
+ if grep -q "^$t\$" /tmp/new-templates; then
+ # only fatal if xlint fails for new templates
+ xlint "$t" > /tmp/xlint_out || EXITCODE=$?
+ else
+ xlint "$t" > /tmp/xlint_out || true
+ fi
+ common/scripts/lint-version-change "srcpkgs/$t/template" $base $tip > /tmp/vlint_out || EXITCODE=$?
awk -f common/scripts/lint2annotations.awk /tmp/xlint_out /tmp/vlint_out
done
exit $EXITCODE
^ permalink raw reply [flat|nested] 13+ messages in thread
* Re: common/travis/xlint: make xlint only fatal for new templates
2023-07-08 22:28 [PR PATCH] common/travis/xlint: make xlint only fatal for new templates classabbyamp
` (9 preceding siblings ...)
2023-07-08 23:02 ` classabbyamp
@ 2023-10-07 1:45 ` github-actions
2023-10-22 1:46 ` [PR PATCH] [Closed]: " github-actions
11 siblings, 0 replies; 13+ messages in thread
From: github-actions @ 2023-10-07 1:45 UTC (permalink / raw)
To: ml
[-- Attachment #1: Type: text/plain, Size: 305 bytes --]
New comment by github-actions[bot] on void-packages repository
https://github.com/void-linux/void-packages/pull/44930#issuecomment-1751552363
Comment:
Pull Requests become stale 90 days after last activity and are closed 14 days after that. If this pull request is still relevant bump it or assign it.
^ permalink raw reply [flat|nested] 13+ messages in thread
* Re: [PR PATCH] [Closed]: common/travis/xlint: make xlint only fatal for new templates
2023-07-08 22:28 [PR PATCH] common/travis/xlint: make xlint only fatal for new templates classabbyamp
` (10 preceding siblings ...)
2023-10-07 1:45 ` github-actions
@ 2023-10-22 1:46 ` github-actions
11 siblings, 0 replies; 13+ messages in thread
From: github-actions @ 2023-10-22 1:46 UTC (permalink / raw)
To: ml
[-- Attachment #1: Type: text/plain, Size: 902 bytes --]
There's a closed pull request on the void-packages repository
common/travis/xlint: make xlint only fatal for new templates
https://github.com/void-linux/void-packages/pull/44930
Description:
per discussion on irc, to help updates and other changes go more smoothly, xlint should only cause a CI failure if the linted template is new.
examples:
- succeeds because only a changed template errors: https://github.com/void-linux/void-packages/actions/runs/5496798220/jobs/10017025380
- fails because of a new package with errors: https://github.com/void-linux/void-packages/actions/runs/5496783595/jobs/10017001341
this does not affect the *reporting* of lint issues, those are still produced as annotations on the 'files changed' tab.
<!-- Uncomment relevant sections and delete options which are not applicable -->
#### Testing the changes
- I tested the changes in this PR: **YES**
^ permalink raw reply [flat|nested] 13+ messages in thread
end of thread, other threads:[~2023-10-22 1:46 UTC | newest]
Thread overview: 13+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2023-07-08 22:28 [PR PATCH] common/travis/xlint: make xlint only fatal for new templates classabbyamp
2023-07-08 22:29 ` [PR PATCH] [Updated] " classabbyamp
2023-07-08 22:41 ` classabbyamp
2023-07-08 22:42 ` classabbyamp
2023-07-08 22:44 ` classabbyamp
2023-07-08 22:51 ` classabbyamp
2023-07-08 22:53 ` classabbyamp
2023-07-08 22:55 ` classabbyamp
2023-07-08 22:58 ` classabbyamp
2023-07-08 23:00 ` classabbyamp
2023-07-08 23:02 ` classabbyamp
2023-10-07 1:45 ` github-actions
2023-10-22 1:46 ` [PR PATCH] [Closed]: " github-actions
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).