Martin Cosyns | f88ed6e | 2020-12-02 10:30:10 +0100 | [diff] [blame] | 1 | #!/bin/bash |
| 2 | # Copyright 2020 ADTRAN, Inc. |
| 3 | # |
| 4 | # Licensed under the Apache License, Version 2.0 (the "License"); |
| 5 | # you may not use this file except in compliance with the License. |
| 6 | # You may obtain a copy of the License at |
| 7 | # |
| 8 | # http://www.apache.org/licenses/LICENSE-2.0 |
| 9 | # |
| 10 | # Unless required by applicable law or agreed to in writing, software |
| 11 | # distributed under the License is distributed on an "AS IS" BASIS, |
| 12 | # WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. |
| 13 | # See the License for the specific language governing permissions and |
| 14 | |
| 15 | for version in $(curl -s https://pypi.org/pypi/device-management-interface/json | jq '.releases | keys' | jq '.[]'); do |
| 16 | version=${version//\"/} |
| 17 | filename=dmi_${version//\./\_} |
| 18 | |
| 19 | python3 -m pip install -q device-management-interface==$version |
| 20 | |
| 21 | if [ -d "./grpc_robot/services/dmi/$filename" ]; then |
| 22 | |
| 23 | python3 -m robot.libdoc -P . grpc_robot.Dmi docs/$filename.html |
| 24 | python3 -m robot.libdoc -P . grpc_robot.Dmi docs/$filename.xml |
| 25 | fi |
| 26 | |
| 27 | done |
| 28 | |
| 29 | python3 -m robot.libdoc -P . grpc_robot.Collections docs/collections.html |
| 30 | python3 -m robot.libdoc -P . grpc_robot.Collections docs/collections.xml |
| 31 | python3 -m robot.libdoc -P . grpc_robot.DmiTools docs/dmi_tools.html |
| 32 | python3 -m robot.libdoc -P . grpc_robot.DmiTools docs/dmi_tools.xml |