Skip to content
GitLab
Menu
Projects
Groups
Snippets
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
Menu
Open sidebar
Alexandre Bulté
validata-doc
Commits
dee2b990
Commit
dee2b990
authored
May 31, 2018
by
Pierre Dittgen
Browse files
Don't add 'errors' subdirectory in target directory
parent
030be10f
Changes
1
Hide whitespace changes
Inline
Side-by-side
data_quality_spec_to_md.py
View file @
dee2b990
...
...
@@ -44,12 +44,10 @@ def generate_documentation(JSON_SPEC_FILE="spec-fr_FR.json", TARGET_DIR="./"):
'''
assert
os
.
path
.
exists
(
TARGET_DIR
)
assert
os
.
path
.
exists
(
JSON_SPEC_FILE
)
root_dir
=
os
.
path
.
join
(
TARGET_DIR
,
"errors"
)
if
not
os
.
path
.
exists
(
root_dir
):
os
.
makedirs
(
root_dir
)
with
open
(
JSON_SPEC_FILE
,
"r"
,
encoding
=
"utf-8"
)
as
_file
:
specs
=
json
.
load
(
_file
)
root_dir
=
TARGET_DIR
readme
=
os
.
path
.
join
(
root_dir
,
"index.md"
)
index_content
=
[]
for
error_id
,
error
in
specs
[
"errors"
].
items
():
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
.
Attach a 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