[gnome-shell] ci: Ensure eslint output exists
- From: Florian Müllner <fmuellner src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [gnome-shell] ci: Ensure eslint output exists
- Date: Wed, 16 Oct 2019 15:42:35 +0000 (UTC)
commit caa50dc1a3e6a3772318f892c011821f0f89ad79
Author: Florian Müllner <fmuellner gnome org>
Date: Wed Aug 14 13:14:23 2019 +0200
ci: Ensure eslint output exists
We are a long time away from an error-free eslint run,
but when we get there eventually, let's not trip over
non-existent files ...
https://gitlab.gnome.org/GNOME/gnome-shell/merge_requests/730
.gitlab-ci/run-eslint.sh | 10 ++++++++--
1 file changed, 8 insertions(+), 2 deletions(-)
---
diff --git a/.gitlab-ci/run-eslint.sh b/.gitlab-ci/run-eslint.sh
index ae4aee979f..edcdfc1fd8 100755
--- a/.gitlab-ci/run-eslint.sh
+++ b/.gitlab-ci/run-eslint.sh
@@ -16,8 +16,14 @@ run_eslint() {
ARGS_LEGACY='--config lint/eslintrc-legacy.json'
local extra_args=ARGS_$1
- local output=OUTPUT_$1
- eslint -f unix ${!extra_args} -o ${!output} js
+ local output_var=OUTPUT_$1
+ local output=${!output_var}
+
+ # ensure output exists even if eslint doesn't report any errors
+ mkdir -p $(dirname $output)
+ touch $output
+
+ eslint -f unix ${!extra_args} -o $output js
}
list_commit_range_additions() {
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]