combine lines
This commit is contained in:
parent
ac246dc0c8
commit
2c58075c6b
@ -51,39 +51,25 @@ def update_wiki(token_id, token_secret, update_csv, update_films_by_year, update
|
||||
|
||||
bar.finish()
|
||||
|
||||
with IncrementalBar('Generating pages', max=update_page_count, check_tty=False) as bar:
|
||||
if update_films_by_year:
|
||||
films_by_year_page = FilmsByYear.build_page(films_by_year)
|
||||
bar.next()
|
||||
if update_films_by_country:
|
||||
films_by_country_page = FilmsByCountry.build_page(films_by_country)
|
||||
bar.next()
|
||||
if update_film_references:
|
||||
films_by_reference_page = FilmsByReference.build_page(films_by_reference)
|
||||
bar.next()
|
||||
if update_hidden_themes:
|
||||
hidden_themes_page = HiddenThemes.build_page(hidden_themes)
|
||||
bar.next()
|
||||
if update_keyword_scores:
|
||||
keyword_scores_page = KeywordScores.build_page(keyword_scores)
|
||||
bar.next()
|
||||
|
||||
bar.finish()
|
||||
|
||||
with IncrementalBar('Updating pages', max=update_page_count, check_tty=False) as bar:
|
||||
if update_films_by_year:
|
||||
films_by_year_page = FilmsByYear.build_page(films_by_year)
|
||||
Bookstack.update_page(VCinemaUtils.JACKNET_WIKI_URL, token_id, token_secret, FilmsByYear.PAGE_ID, markdown=films_by_year_page)
|
||||
bar.next()
|
||||
if update_films_by_country:
|
||||
films_by_country_page = FilmsByCountry.build_page(films_by_country)
|
||||
Bookstack.update_page(VCinemaUtils.JACKNET_WIKI_URL, token_id, token_secret, FilmsByCountry.PAGE_ID, markdown=films_by_country_page)
|
||||
bar.next()
|
||||
if update_film_references:
|
||||
films_by_reference_page = FilmsByReference.build_page(films_by_reference)
|
||||
Bookstack.update_page(VCinemaUtils.JACKNET_WIKI_URL, token_id, token_secret, FilmsByReference.PAGE_ID, markdown=films_by_reference_page)
|
||||
bar.next()
|
||||
if update_hidden_themes:
|
||||
hidden_themes_page = HiddenThemes.build_page(hidden_themes)
|
||||
Bookstack.update_page(VCinemaUtils.JACKNET_WIKI_URL, token_id, token_secret, HiddenThemes.PAGE_ID, markdown=hidden_themes_page)
|
||||
bar.next()
|
||||
if update_keyword_scores:
|
||||
keyword_scores_page = KeywordScores.build_page(keyword_scores)
|
||||
Bookstack.update_page(VCinemaUtils.JACKNET_WIKI_URL, token_id, token_secret, KeywordScores.PAGE_ID, markdown=keyword_scores_page)
|
||||
bar.next()
|
||||
|
||||
|
Loading…
x
Reference in New Issue
Block a user