Skip to content
GitLab
Projects
Groups
Snippets
/
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
Menu
Open sidebar
Olivier Stasse
Gepetto Utils
Commits
ff82bb68
Commit
ff82bb68
authored
Apr 06, 2018
by
Guilhem Saurel
Browse files
doc.{py,sh} to autodeploy doc from gepgitlab artifacts
parent
3331891a
Changes
2
Hide whitespace changes
Inline
Side-by-side
scripts/doc.py
0 → 100755
View file @
ff82bb68
#!/usr/bin/env python3
import
os
from
pathlib
import
Path
from
zipfile
import
ZipFile
from
io
import
BytesIO
import
requests
DOC
=
Path
(
'/net/cetus/data/gepetto/Doc'
)
GITLAB
=
'https://gepgitlab.laas.fr'
VERSION
=
'16.04'
PR_NS_BR
=
[
(
'pinocchio'
,
[
(
'gsaurel'
,
[
'autodeploy-doc'
,
]),
]),
]
for
project
,
namespaces
in
PR_NS_BR
:
for
namespace
,
branches
in
namespaces
:
for
branch
in
branches
:
path
=
DOC
/
namespace
/
project
/
branch
path
.
mkdir
(
parents
=
True
,
exist_ok
=
True
)
r
=
requests
.
get
(
f
'
{
GITLAB
}
/
{
namespace
}
/
{
project
}
/-/jobs/artifacts/
{
branch
}
/download'
,
{
'job'
:
f
'robotpkg-
{
project
}
-
{
VERSION
}
'
},
stream
=
True
)
ZipFile
(
BytesIO
(
r
.
content
)).
extractall
(
str
(
path
))
scripts/doc.sh
0 → 100755
View file @
ff82bb68
#!/bin/bash
set
-e
cd
/net/cetus/data/gepetto/Doc
for
namespace
in
*
;
do
pushd
$namespace
for
project
in
*
;
do
pushd
$project
for
branch
in
*
;
do
pushd
$branch
[[
-d
doc/doxygen-html
]]
||
continue
cp
-r
doc/doxygen-html/
*
.
rm
-r
doc
popd
done
popd
done
popd
done
Write
Preview
Supports
Markdown
0%
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment