From a0b604e08d261d3c4a0f1cf86a4b597f5697b31a Mon Sep 17 00:00:00 2001 From: garciadeblas Date: Thu, 14 Mar 2024 19:50:59 +0100 Subject: [PATCH] Update yang2swagger version to 2.1.0 Change-Id: I16dc02009cc61f8452f3a0787b288d9c140c4ea8 Signed-off-by: garciadeblas --- Dockerfile | 4 ++-- Makefile | 16 ++++++---------- devops-stages/stage-test.sh | 4 ++-- requirements-dist.in | 2 +- tox.ini | 1 + 5 files changed, 12 insertions(+), 15 deletions(-) diff --git a/Dockerfile b/Dockerfile index 3ca4992..cdecfd2 100644 --- a/Dockerfile +++ b/Dockerfile @@ -44,5 +44,5 @@ RUN pip install tox==3.24.5 RUN DEBIAN_FRONTEND=noninteractive apt-get update && \ DEBIAN_FRONTEND=noninteractive apt-get -y install wget build-essential dh-make \ - openjdk-8-jdk maven -RUN update-java-alternatives --set /usr/lib/jvm/java-1.8.0-openjdk-amd64 + openjdk-17-jdk maven +RUN update-java-alternatives --jre-headless --set /usr/lib/jvm/java-1.17.0-openjdk-amd64 diff --git a/Makefile b/Makefile index 90cd86a..c62ef10 100644 --- a/Makefile +++ b/Makefile @@ -16,8 +16,8 @@ # NOTE: pyang and pyangbind are required for build -.PHONY: all clean package trees deps yang-ietf openapi_schemas yang2swagger -JAVA := /usr/lib/jvm/java-8-openjdk-amd64/jre/bin/java +.PHONY: all clean package trees yang-ietf openapi_schemas yang2swagger +JAVA := /usr/lib/jvm/java-17-openjdk-amd64/bin/java PYANG := pyang ifeq ($(OS),Windows_NT) # is Windows_NT on XP, 2000, 7, Vista, 10... PYTHON_INTERPRETER := python @@ -94,7 +94,7 @@ $(TREES_DIR): osm.yaml: yang-ietf yang2swagger $(Q)echo generating $@ - $(Q)$(JAVA) -jar ${HOME}/.m2/repository/com/mrv/yangtools/swagger-generator-cli/1.1.14/swagger-generator-cli-1.1.14-executable.jar -yang-dir $(MODEL_DIR) -output $(OUT_DIR)/$@ + $(Q)$(JAVA) -jar ${HOME}/.m2/repository/com/mrv/yangtools/swagger-generator-cli/2.1.0/swagger-generator-cli-2.1.0-executable.jar -yang-dir $(MODEL_DIR) -output $(OUT_DIR)/$@ yang-ietf: $(Q)wget -q https://raw.githubusercontent.com/YangModels/yang/master/standard/ietf/RFC/ietf-yang-types%402013-07-15.yang -O $(MODEL_DIR)/ietf-yang-types.yang @@ -105,17 +105,13 @@ yang-ietf: yang2swagger: $(Q)mkdir -p ${HOME}/.m2 $(Q)wget -q -O ${HOME}/.m2/settings.xml https://raw.githubusercontent.com/opendaylight/odlparent/master/settings.xml - git clone https://github.com/bartoszm/yang2swagger.git - git -C yang2swagger checkout tags/1.1.14 - mvn -f yang2swagger/pom.xml clean install + $(Q)git clone https://github.com/bartoszm/yang2swagger.git + $(Q)git -C yang2swagger checkout tags/2.1.0 + $(Q)mvn -f yang2swagger/pom.xml clean install package: ./build-docs.sh -deps: - $(Q)mkdir -p ${HOME}/.m2 - $(Q)cp -n ${HOME}/.m2/settings.xml ${HOME}/.m2/settings.xml.orig ; wget -q -O - https://raw.githubusercontent.com/opendaylight/odlparent/master/settings.xml > ${HOME}/.m2/settings.xml - sol006_deps: $(Q)git clone --single-branch --branch v2.6.1 https://forge.etsi.org/rep/nfv/SOL006.git sol006_model $(Q)patch -p2 < patch/deref_warnings.patch diff --git a/devops-stages/stage-test.sh b/devops-stages/stage-test.sh index 067d896..409d1aa 100755 --- a/devops-stages/stage-test.sh +++ b/devops-stages/stage-test.sh @@ -16,5 +16,5 @@ # License for the specific language governing permissions and limitations # under the License. -OUTPUT=$(TOX_PARALLEL_NO_SPINNER=1 tox --parallel=auto) -printf "$OUTPUT" +echo "Launching tox" +TOX_PARALLEL_NO_SPINNER=1 tox --parallel=auto diff --git a/requirements-dist.in b/requirements-dist.in index 4f8784f..2f86ee0 100644 --- a/requirements-dist.in +++ b/requirements-dist.in @@ -15,4 +15,4 @@ stdeb setuptools-version-command -setuptools<60 \ No newline at end of file +setuptools<60 diff --git a/tox.ini b/tox.ini index 4a2494a..8963e76 100644 --- a/tox.ini +++ b/tox.ini @@ -29,6 +29,7 @@ setenv = VIRTUAL_ENV={envdir} passenv = HOME deps = -r{toxinidir}/requirements.txt skip_install = true +parallel_show_output = true ####################################################################################### -- 2.25.1