mirror of
https://github.com/kovidgoyal/calibre.git
synced 2025-07-09 03:04:10 -04:00
...
This commit is contained in:
parent
104614612f
commit
b49eed0582
@ -34,7 +34,7 @@ class TheHindu(BasicNewsRecipe):
|
|||||||
recipe_specific_options = {
|
recipe_specific_options = {
|
||||||
'location': {
|
'location': {
|
||||||
'short': 'The name of the local edition',
|
'short': 'The name of the local edition',
|
||||||
'long': ('If The Hindu is available in your local town/city,\n'
|
'long': ('If The Hindu is available in your local town/city, '
|
||||||
'set this to your location, for example, hyderabad\n'
|
'set this to your location, for example, hyderabad\n'
|
||||||
'Available Editions: bengaluru, chennai, coimbatore, delhi, '
|
'Available Editions: bengaluru, chennai, coimbatore, delhi, '
|
||||||
'erode, hyderabad, international, kochi, kolkata,\n'
|
'erode, hyderabad, international, kochi, kolkata,\n'
|
||||||
|
@ -26,7 +26,7 @@ class ht(BasicNewsRecipe):
|
|||||||
recipe_specific_options = {
|
recipe_specific_options = {
|
||||||
'location': {
|
'location': {
|
||||||
'short': 'The name of the local edition',
|
'short': 'The name of the local edition',
|
||||||
'long': ('If The Hindustan Times is available in your local town/city,\n'
|
'long': ('If The Hindustan Times is available in your local town/city, '
|
||||||
'set this to your location, for example, Delhi\nAvailable Editions:'
|
'set this to your location, for example, Delhi\nAvailable Editions:'
|
||||||
'Delhi, Mumbai, Chandigarh, Lucknow, Patna, Bengaluru, Pune, Gurgaon,'
|
'Delhi, Mumbai, Chandigarh, Lucknow, Patna, Bengaluru, Pune, Gurgaon,'
|
||||||
'Ludhiana, Rajasthan, Amritsar,\nEast UP, Haryana, Jammu, Navi Mumbai,'
|
'Ludhiana, Rajasthan, Amritsar,\nEast UP, Haryana, Jammu, Navi Mumbai,'
|
||||||
|
@ -21,9 +21,9 @@ def resize(x):
|
|||||||
return v
|
return v
|
||||||
|
|
||||||
m_fr = {
|
m_fr = {
|
||||||
1: 'janvier', 2: 'février', 3: 'mars', 4: 'avril',
|
1: 'Janvier', 2: 'Février', 3: 'Mars', 4: 'Avril',
|
||||||
5: 'mai', 6: 'juin', 7: 'juillet', 8: 'août',
|
5: 'Mai', 6: 'Juin', 7: 'Juillet', 8: 'Août',
|
||||||
9: 'septembre', 10: 'octobre', 11: 'novembre', 12: 'décembre'
|
9: 'Septembre', 10: 'Octobre', 11: 'Novembre', 12: 'Décembre'
|
||||||
}
|
}
|
||||||
|
|
||||||
def json_to_html(raw):
|
def json_to_html(raw):
|
||||||
@ -34,7 +34,7 @@ def json_to_html(raw):
|
|||||||
|
|
||||||
auth = '<p class="auth">{}</p>\n'
|
auth = '<p class="auth">{}</p>\n'
|
||||||
dt = datetime.fromisoformat(data['last_updated_date'][:-1]) + timedelta(seconds=time.timezone)
|
dt = datetime.fromisoformat(data['last_updated_date'][:-1]) + timedelta(seconds=time.timezone)
|
||||||
dt = dt.strftime('%d ' + m_fr[dt.month] + ' %Y')
|
dt = dt.strftime(m_fr[dt.month] + '%d, %Y')
|
||||||
a = [x['name'] for x in data['credits']['by']]
|
a = [x['name'] for x in data['credits']['by']]
|
||||||
if a:
|
if a:
|
||||||
auth = auth.format(', '.join(a) + ' | ' + dt)
|
auth = auth.format(', '.join(a) + ' | ' + dt)
|
||||||
@ -86,6 +86,7 @@ class Liberation(BasicNewsRecipe):
|
|||||||
oldest_article = 1.15
|
oldest_article = 1.15
|
||||||
remove_empty_feeds = True
|
remove_empty_feeds = True
|
||||||
articles_are_obfuscated = True
|
articles_are_obfuscated = True
|
||||||
|
timefmt = '[ %s]' % datetime.now().strftime(m_fr[datetime.now().month] '%d, %Y')
|
||||||
ignore_duplicate_articles = {'title', 'url'}
|
ignore_duplicate_articles = {'title', 'url'}
|
||||||
key = 'ZWplZVBlaW5nZWl0YWVnaG8zd2VlbmdlZXlvaHB1'
|
key = 'ZWplZVBlaW5nZWl0YWVnaG8zd2VlbmdlZXlvaHB1'
|
||||||
masthead_url = 'https://journal.liberation.fr/img/logo.svg'
|
masthead_url = 'https://journal.liberation.fr/img/logo.svg'
|
||||||
|
Loading…
x
Reference in New Issue
Block a user