[libvirt-perl PATCH v2 3/3] gitlab: add a simple job that publishes the API docs as HTML

Daniel P. Berrangé berrange at redhat.com
Wed Apr 29 11:19:24 UTC 2020


The Perl modules have inline POD docs. This can be converted to HTML and
published as a GitLab artifact. The rendered HTML is kind of ugly but
improving this is left as an exercise for the future.

Signed-off-by: Daniel P. Berrangé <berrange at redhat.com>
---
 .gitlab-ci.yml | 15 +++++++++++++++
 1 file changed, 15 insertions(+)

diff --git a/.gitlab-ci.yml b/.gitlab-ci.yml
index 4a1472b..2fa54f2 100644
--- a/.gitlab-ci.yml
+++ b/.gitlab-ci.yml
@@ -3,6 +3,7 @@ stages:
   - prebuild
   - containers
   - build
+  - docs
 
 .container_job_template: &container_job_definition
   image: docker:stable
@@ -157,3 +158,17 @@ build-ubuntu-1604:
 build-ubuntu-1804:
   <<: *build_job_definition
   image: ${CI_REGISTRY_IMAGE}/buildenv-ubuntu-1804:latest
+
+apiref:
+  stage: docs
+  image: perl
+  script:
+    - mkdir apiref
+    - perl -MPod::Simple::HTMLBatch -e Pod::Simple::HTMLBatch::go  lib apiref
+  artifacts:
+    expose_as: 'API Reference'
+    name: 'apiref'
+    when: on_success
+    expire_in: 30 days
+    paths:
+      - apiref
-- 
2.25.4




More information about the libvir-list mailing list