[VOL-5100] - periodic-voltha-test-bbsim
jjb/pipeline/voltha/master/bbsim-tests.groovy
---------------------------------------------
o misc npm-groovy-lint cleanups:
- indentation, quotes, typed vars, etc.
- convert tabs to space (expand -i -t 8)
o Stage('Install Kind')
- wrap install_kind call in a script{} block for evaluation.
- no primitives available like sh() to provide needed script{} context.
o Re-enable IAM method now that branch_name is fixed.
makefiles/lint/include.mk
makefiles/lint/groovy/include.mk
makefiles/lint/groovy/install.mk
--------------------------------
o (WIP) Add skeleton targets for lint-groovy able to install
npm-groovy-lint on demand for local use.
Change-Id: Ifbf72ae9cb021d28c15a783454278ac2c680e45e
diff --git a/makefiles/lint/groovy.mk b/makefiles/lint/groovy/include.mk
similarity index 100%
rename from makefiles/lint/groovy.mk
rename to makefiles/lint/groovy/include.mk
diff --git a/makefiles/lint/groovy/install.mk b/makefiles/lint/groovy/install.mk
index 7843e8f..fcfa8d6 100644
--- a/makefiles/lint/groovy/install.mk
+++ b/makefiles/lint/groovy/install.mk
@@ -1,4 +1,49 @@
+# -*- makefile -*-
+# -----------------------------------------------------------------------
+# Copyright 2022-2023 Open Networking Foundation (ONF) and the ONF Contributors
+#
+# Licensed under the Apache License, Version 2.0 (the "License");
+# you may not use this file except in compliance with the License.
+# You may obtain a copy of the License at
+#
+# http://www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing, software
+# distributed under the License is distributed on an "AS IS" BASIS,
+# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+# See the License for the specific language governing permissions and
+# limitations under the License.
+# -----------------------------------------------------------------------
-# curl -O -L https://npmjs.org/install.sh
-# sh install
-# curl -L https://npmjs.org/install.sh | sh
+##-------------------##
+##---] GLOBALS [---##
+##-------------------##
+lint-groovy-cmds += $(shell which npm-groovy-lint)
+lint-groovy-cmds += $(HOME)/.npm/bin/npm-groovy-lint
+lint-groovy-cmds += /usr/bin/npm-groovy-lint
+# lint-groovy-cmds += /dev/null# # force existence
+
+lint-groovy-cmd = $(firstword $(wildcard $(lint-groovy-cmds)))
+
+##-------------------##
+##---] TARGETS [---##
+##-------------------##
+ifndef NO-LINT-GROOVY
+
+ lint : lint-groovy
+endif
+
+## -----------------------------------------------------------------------
+## Intent: Install npm-groovy-lint
+## -----------------------------------------------------------------------
+$(lint-groovy-cmd) : lint-groovy-install
+lint-groovy-install:
+
+## -----------------------------------------------------------------------
+## Intent: Display command help
+## -----------------------------------------------------------------------
+help-summary ::
+ @echo ' lint-groovy-install Syntax check groovy sources'
+
+# [EOF]
+
diff --git a/makefiles/lint/groovy/urls b/makefiles/lint/groovy/urls
index aa5c5eb..4d9ba27 100644
--- a/makefiles/lint/groovy/urls
+++ b/makefiles/lint/groovy/urls
@@ -5,4 +5,7 @@
https://github.com/nvuillam/npm-groovy-lint
+# Homepage
+installhttps://nvuillam.github.io/npm-groovy-lint/
+
# [EOF]
diff --git a/makefiles/lint/include.mk b/makefiles/lint/include.mk
index 7cfed79..e928fc3 100644
--- a/makefiles/lint/include.mk
+++ b/makefiles/lint/include.mk
@@ -28,7 +28,7 @@
@echo "[LINT]"
include $(ONF_MAKEDIR)/lint/doc8/include.mk
-include $(ONF_MAKEDIR)/lint/groovy.mk
+include $(ONF_MAKEDIR)/lint/groovy/include.mk
include $(ONF_MAKEDIR)/lint/jjb.mk
include $(ONF_MAKEDIR)/lint/json.mk
include $(ONF_MAKEDIR)/lint/license/include.mk