mirror of https://gitlab.com/bashrc2/epicyon
Snake case
parent
438f06aea9
commit
cbbe8812bd
|
@ -18438,7 +18438,7 @@ def runDaemon(content_license_url: str,
|
|||
full_width_tl_button_header: bool,
|
||||
show_publish_as_icon: bool,
|
||||
max_followers: int,
|
||||
maxNewsPosts: int,
|
||||
max_news_posts: int,
|
||||
maxMirroredArticles: int,
|
||||
maxNewswireFeedSizeKb: int,
|
||||
max_newswire_postsPerSource: int,
|
||||
|
@ -18650,7 +18650,7 @@ def runDaemon(content_license_url: str,
|
|||
httpd.maxMirroredArticles = maxMirroredArticles
|
||||
|
||||
# maximum number of posts in the news timeline/outbox
|
||||
httpd.maxNewsPosts = maxNewsPosts
|
||||
httpd.max_news_posts = max_news_posts
|
||||
|
||||
# The maximum number of tags per post which can be
|
||||
# attached to RSS feeds pulled in via the newswire
|
||||
|
|
14
epicyon.py
14
epicyon.py
|
@ -209,8 +209,8 @@ parser.add_argument('--maxMirroredArticles',
|
|||
default=100,
|
||||
help='Maximum number of news articles to mirror.' +
|
||||
' Set to zero for indefinite mirroring.')
|
||||
parser.add_argument('--maxNewsPosts',
|
||||
dest='maxNewsPosts', type=int,
|
||||
parser.add_argument('--max_news_posts',
|
||||
dest='max_news_posts', type=int,
|
||||
default=0,
|
||||
help='Maximum number of news timeline posts to keep. ' +
|
||||
'Zero for no expiry.')
|
||||
|
@ -3048,10 +3048,10 @@ maxMirroredArticles = \
|
|||
if maxMirroredArticles is not None:
|
||||
args.maxMirroredArticles = int(maxMirroredArticles)
|
||||
|
||||
maxNewsPosts = \
|
||||
getConfigParam(base_dir, 'maxNewsPosts')
|
||||
if maxNewsPosts is not None:
|
||||
args.maxNewsPosts = int(maxNewsPosts)
|
||||
max_news_posts = \
|
||||
getConfigParam(base_dir, 'max_news_posts')
|
||||
if max_news_posts is not None:
|
||||
args.max_news_posts = int(max_news_posts)
|
||||
|
||||
max_followers = \
|
||||
getConfigParam(base_dir, 'max_followers')
|
||||
|
@ -3233,7 +3233,7 @@ if __name__ == "__main__":
|
|||
args.full_width_tl_button_header,
|
||||
args.show_publish_as_icon,
|
||||
args.max_followers,
|
||||
args.maxNewsPosts,
|
||||
args.max_news_posts,
|
||||
args.maxMirroredArticles,
|
||||
args.maxNewswireFeedSizeKb,
|
||||
args.max_newswire_postsPerSource,
|
||||
|
|
|
@ -840,7 +840,7 @@ def runNewswireDaemon(base_dir: str, httpd,
|
|||
httpd.content_license_url)
|
||||
print('Newswire feed converted to ActivityPub')
|
||||
|
||||
if httpd.maxNewsPosts > 0:
|
||||
if httpd.max_news_posts > 0:
|
||||
archiveDir = base_dir + '/archive'
|
||||
archiveSubdir = \
|
||||
archiveDir + '/accounts/news@' + domain + '/outbox'
|
||||
|
@ -849,7 +849,7 @@ def runNewswireDaemon(base_dir: str, httpd,
|
|||
domain, base_dir, 'outbox',
|
||||
archiveSubdir,
|
||||
httpd.recentPostsCache,
|
||||
httpd.maxNewsPosts)
|
||||
httpd.max_news_posts)
|
||||
|
||||
# wait a while before the next feeds update
|
||||
for tick in range(120):
|
||||
|
|
Loading…
Reference in New Issue