vagrant test: patch yangmodels, changed to main
This commit is contained in:
parent
8d5694cc1c
commit
3d59077894
1 changed files with 4 additions and 1 deletions
|
|
@ -275,6 +275,7 @@ $sshcmd ./clixon.sh $release $wwwuser ${with_restconf}
|
||||||
|
|
||||||
# Tests require yangmodels and openconfig
|
# Tests require yangmodels and openconfig
|
||||||
cat<<EOF > $dir/yangmodels.sh
|
cat<<EOF > $dir/yangmodels.sh
|
||||||
|
set -eux
|
||||||
cd /usr/local/share
|
cd /usr/local/share
|
||||||
test -d yang || mkdir yang
|
test -d yang || mkdir yang
|
||||||
cd yang
|
cd yang
|
||||||
|
|
@ -284,10 +285,12 @@ git remote add -f origin https://github.com/YangModels/yang
|
||||||
git config core.sparseCheckout true
|
git config core.sparseCheckout true
|
||||||
echo "standard/" >> .git/info/sparse-checkout
|
echo "standard/" >> .git/info/sparse-checkout
|
||||||
echo "experimental/" >> .git/info/sparse-checkout
|
echo "experimental/" >> .git/info/sparse-checkout
|
||||||
git pull origin master
|
git pull origin main
|
||||||
# Patch yang syntax errors
|
# Patch yang syntax errors
|
||||||
sed s/=\ olt\'/=\ \'olt\'/g /usr/local/share/yang/standard/ieee/published/802.3/ieee802-ethernet-pon.yang > ieee802-ethernet-pon2.yang
|
sed s/=\ olt\'/=\ \'olt\'/g /usr/local/share/yang/standard/ieee/published/802.3/ieee802-ethernet-pon.yang > ieee802-ethernet-pon2.yang
|
||||||
mv ieee802-ethernet-pon2.yang /usr/local/share/yang/standard/ieee/published/802.3/ieee802-ethernet-pon.yang
|
mv ieee802-ethernet-pon2.yang /usr/local/share/yang/standard/ieee/published/802.3/ieee802-ethernet-pon.yang
|
||||||
|
sudo sed 's/”/"/' /usr/local/share/yang/standard/iana/iana-if-type@2022-03-07.yang > iana-if-type@2022-03-07-2.yang
|
||||||
|
sudo mv iana-if-type@2022-03-07-2.yang /usr/local/share/yang/standard/iana/iana-if-type@2022-03-07.yang
|
||||||
# openconfig
|
# openconfig
|
||||||
cd /usr/local/share
|
cd /usr/local/share
|
||||||
test -d openconfig || mkdir openconfig
|
test -d openconfig || mkdir openconfig
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue