From: Alex Stancu Date: Tue, 30 Jun 2020 16:07:54 +0000 (+0300) Subject: Bug fix. X-Git-Tag: 1.0.3~14 X-Git-Url: https://gerrit.o-ran-sc.org/r/gitweb?p=sim%2Fo1-interface.git;a=commitdiff_plain;h=b8166cdc5294cdee0c717085d659b4a8f0834313 Bug fix. Fix bug where YANG models contain only submodule definition throw error. Issue-ID: SIM-32 Change-Id: Ibd4ec1ac51235cb8f955f5a1cf7bb4d1c7402fd1 Signed-off-by: Alex Stancu --- diff --git a/ntsimulator/yang/auto-load-yangs.sh b/ntsimulator/yang/auto-load-yangs.sh index 3c4f409..fe2a1c1 100755 --- a/ntsimulator/yang/auto-load-yangs.sh +++ b/ntsimulator/yang/auto-load-yangs.sh @@ -57,6 +57,13 @@ else skip_model=true fi done + + isSubmoduleOnly=$(pyang -f submodule --submodule-only $model) + + if [ "$isSubmoduleOnly" == "True" ]; then + echo "Skipping installation of model $modelName because it only contains submodules..." + continue + fi if [ "$skip_model" = true ]; then echo "Skipping installation of excluded model $modelName..."