Skip to content
GitLab
Menu
Projects
Groups
Snippets
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
Menu
Open sidebar
groupe-calcul
spip2pelican
Commits
e52a749f
Commit
e52a749f
authored
Jun 06, 2018
by
Matthieu Boileau
Browse files
Rearrange config.yml
parent
9a294a67
Changes
2
Hide whitespace changes
Inline
Side-by-side
config.yml
View file @
e52a749f
...
...
@@ -10,8 +10,9 @@ categories:
-
14
groupe
:
2
skip
:
49
#rubriques: spip_rubriques_clean.yml
#articles: spip_articles_clean.yml
#documents: spip_documents.yml
#authors: spip_auteurs_clean.yml
#authors_links: spip_auteurs_liens.yml
#spip_file:
# rubriques: spip_rubriques_clean.yml
# articles: spip_articles_clean.yml
# documents: spip_documents.yml
# authors: spip_auteurs_clean.yml
# authors_links: spip_auteurs_liens.yml
spip2pelican.py
View file @
e52a749f
...
...
@@ -420,12 +420,13 @@ class Website:
# Set attributes from config.yml file or use default values
self
.
site_url
=
cfg
[
'site_url'
]
self
.
default_author
=
cfg
.
get
(
'default_author'
,
self
.
DEFAULT_AUTHOR
)
self
.
attachments_prefix
=
cfg
.
get
(
'attachments_prefix'
,
self
.
ATTACHMENTS_PREFIX
)
self
.
rubriques_filename
=
cfg
.
get
(
'rubriques'
,
self
.
RUBRIQUES_FILENAME
)
self
.
articles_filename
=
cfg
.
get
(
'articles'
,
self
.
ARTICLES_FILENAME
)
self
.
documents_filename
=
cfg
.
get
(
'documents'
,
self
.
DOCUMENTS_FILENAME
)
self
.
authors_filename
=
cfg
.
get
(
'authors'
,
self
.
AUTHORS_FILENAME
)
self
.
authors_links_filename
=
cfg
.
get
(
'authors_links'
,
self
.
AUTHORS_LINKS_FILENAME
)
spip_file
=
cfg
.
get
(
'spip_file'
,
{})
self
.
attachments_prefix
=
spip_file
.
get
(
'attachments_prefix'
,
self
.
ATTACHMENTS_PREFIX
)
self
.
rubriques_filename
=
spip_file
.
get
(
'rubriques'
,
self
.
RUBRIQUES_FILENAME
)
self
.
articles_filename
=
spip_file
.
get
(
'articles'
,
self
.
ARTICLES_FILENAME
)
self
.
documents_filename
=
spip_file
.
get
(
'documents'
,
self
.
DOCUMENTS_FILENAME
)
self
.
authors_filename
=
spip_file
.
get
(
'authors'
,
self
.
AUTHORS_FILENAME
)
self
.
authors_links_filename
=
spip_file
.
get
(
'authors_links'
,
self
.
AUTHORS_LINKS_FILENAME
)
self
.
categories
=
{
-
1
:
"spip_divers"
}
for
pelican_category
,
spip_rubrique
in
cfg
[
'categories'
].
items
():
if
type
(
spip_rubrique
)
==
int
:
...
...
Write
Preview
Supports
Markdown
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