@@ -61,40 +61,78 @@ const db = new sqlite3.Database('mega.sqlite3', (err) => {
6161
6262// -----------------------------------------------------------------------------
6363// Data
64+ //
65+
6466
6567const communities = [
6668 {
67- slug : 'localnews ' ,
68- instance : 'tucson.social ' ,
69+ slug : 'godot ' ,
70+ instance : 'programming.dev ' ,
6971 feeds : [
70- 'localnews ' ,
72+ 'godot ' ,
7173 ]
7274 } ,
7375 {
74- slug : 'tucsonpolitics ' ,
75- instance : 'tucson.social ' ,
76+ slug : 'unreal_engine ' ,
77+ instance : 'programming.dev ' ,
7678 feeds : [
77- 'localpolitics ' ,
79+ 'unreal ' ,
7880 ]
7981 } ,
8082]
8183
84+ // Feed data is stored in the following format:
85+ // joinfeeds will only include posts in common between the source feed and those in the list - It is processed first.
86+ // exclude will remove posts from the feed based on the contents of another feed - It is processed second.
87+ // pinCategories will pin posts in the feed that match the category name and are within the specified number of days
88+ // content is the name of the field in the feed that contains the post content. Defaults to 'content' if not specified
89+ //
90+ // const feeds = [
91+ // {
92+ // name: 'feedname',
93+ // url: 'https://www.some-news-site.com/category/rss/news/',
94+ // content: 'description',
95+ // exclude: [
96+ // 'feedname2', // the feed contains posts from feedname2, which we don't want. So we exclude feedname2 to get feedname only.
97+ // ],
98+ // joinfeeds: [
99+ // 'feedname3', // the feed contains posts from feedname3, which we want. So we join feedname3 to get feedname and feedname3.
100+ // ],
101+ // pinCategories: [
102+ // { name: 'categoryname', days: 7 }, // the feed contains posts from categoryname, which we want. So we pin categoryname posts from the feed.
103+ // ]
104+ // },
105+ // {
106+ // name: 'feedname2',
107+ // url: 'https://www.some-news-site.com/category/rss/politics/',
108+ // content: 'content'
109+ // },
110+ // {
111+ // name: 'feedname3',
112+ // url: 'https://www.some-news-site.com/category/rss/localnews/',
113+ // content: 'content'
114+ // }
115+ // ]
116+ //
117+
118+
82119const feeds = [
83120 {
84- name : 'localnews ' ,
85- url : 'https://www.tucsonsentinel.com/category/ rss/local/ ' ,
86- content : 'description' ,
87- exclude : [
88- 'localpolitics ', // the local feed contains politics, which we don't want. So we exclude the localpolitics feed to get local news only.
89- ]
121+ name : 'godot ' ,
122+ url : 'https://godotengine.org/ rss.xml ' ,
123+ pinCategories : [
124+ { name : 'Release' , days : 7 } ,
125+ { name : 'Pre-release ', days : 7 } ,
126+ ] ,
90127 } ,
91128 {
92- name : 'localpolitics' ,
93- url : 'https://www.tucsonsentinel.com/category/rss/politics/' ,
94- content : 'description' ,
95- joinfeeds : [
96- 'localnews' , // the politics feed contains national politics, which we don't want. So we join the local news feed to get local politics.
97- ]
129+ name : 'unreal' ,
130+ url : 'https://www.unrealengine.com/en-US/rss' ,
131+ content : 'summary' ,
132+ } ,
133+ {
134+ name : 'unity' ,
135+ url : 'https://blogs.unity3d.com/feed/' ,
98136 }
99137]
100138
0 commit comments