diff --git a/assets/radar-rules.js b/assets/radar-rules.js index a03f345fb2785f..07dee835d9f738 100644 --- a/assets/radar-rules.js +++ b/assets/radar-rules.js @@ -266,7 +266,6 @@ { title: '首页 / 自考快递', docs: 'https://docs.rsshub.app/routes/government#bei-jing-jiao-yu-kao-shi-yuan', source: ['/zkkd'], target: '/gov/beijing/bjeea/zkkd' }, ], }, - 'ems.com.cn': { _name: '中国邮政速递物流', www: [{ title: '新闻', docs: 'https://docs.rsshub.app/routes/other#zhong-guo-you-zheng-su-di-wu-liu', source: '/aboutus/xin_wen_yu_shi_jian', target: '/ems/news' }] }, 'nppa.gov.cn': { _name: '国家新闻出版署', www: [ diff --git a/lib/radar-rules.js b/lib/radar-rules.js index 93cdda736be36f..24304fe173176e 100644 --- a/lib/radar-rules.js +++ b/lib/radar-rules.js @@ -366,35 +366,6 @@ module.exports = { }, ], }, - 'csc.edu.cn': { - _name: '国家留学网', - www: [ - { - title: '遴选通知', - docs: 'https://docs.rsshub.app/routes/other#guo-jia-liu-xue-wang', - source: '/*', - target: '/csc/notice/lxtz', - }, - { - title: '综合项目专栏', - docs: 'https://docs.rsshub.app/routes/other#guo-jia-liu-xue-wang', - source: '/*', - target: '/csc/notice/xmzl', - }, - { - title: '常见问题解答', - docs: 'https://docs.rsshub.app/routes/other#guo-jia-liu-xue-wang', - source: '/*', - target: '/csc/notice/wtjd', - }, - { - title: '录取公告', - docs: 'https://docs.rsshub.app/routes/other#guo-jia-liu-xue-wang', - source: '/*', - target: '/csc/notice/lqgg', - }, - ], - }, // 'biquge5200.com': { // www: [ // { diff --git a/lib/router.js b/lib/router.js index d95c415e92fb05..5958b06b048768 100644 --- a/lib/router.js +++ b/lib/router.js @@ -19,9 +19,6 @@ const lazyloadRouteHandler = (routeHandlerPath) => (ctx) => { // Benedict Evans router.get('/benedictevans', lazyloadRouteHandler('./routes/benedictevans/recent.js')); -// 自如 -router.get('/ziroom/room/:city/:iswhole/:room/:keyword', lazyloadRouteHandler('./routes/ziroom/room')); - // 简书 // router.get('/jianshu/home', lazyloadRouteHandler('./routes/jianshu/home')); // router.get('/jianshu/collection/:id', lazyloadRouteHandler('./routes/jianshu/collection')); @@ -418,9 +415,6 @@ router.get('/tits-guru/daily', lazyloadRouteHandler('./routes/titsguru/daily')); router.get('/tits-guru/category/:type', lazyloadRouteHandler('./routes/titsguru/category')); router.get('/tits-guru/model/:name', lazyloadRouteHandler('./routes/titsguru/model')); -// TSSstatus -router.get('/tssstatus/:board/:build', lazyloadRouteHandler('./routes/tssstatus')); - // Anime1 router.get('/anime1/anime/:time/:name', lazyloadRouteHandler('./routes/anime1/anime')); router.get('/anime1/search/:keyword', lazyloadRouteHandler('./routes/anime1/search')); @@ -535,9 +529,6 @@ router.get('/xiaoheihe/user/:id', lazyloadRouteHandler('./routes/xiaoheihe/user' router.get('/xiaoheihe/news', lazyloadRouteHandler('./routes/xiaoheihe/news')); router.get('/xiaoheihe/discount/:platform?', lazyloadRouteHandler('./routes/xiaoheihe/discount')); -// 惠誉评级 -router.get('/fitchratings/site/:type', lazyloadRouteHandler('./routes/fitchratings/site')); - // ebb router.get('/ebb', lazyloadRouteHandler('./routes/ebb')); @@ -570,9 +561,6 @@ router.get('/security/pulses', lazyloadRouteHandler('./routes/security/pulses')) router.get('/wegene/column/:type/:category', lazyloadRouteHandler('./routes/wegene/column')); router.get('/wegene/newest', lazyloadRouteHandler('./routes/wegene/newest')); -// instapaper -router.get('/instapaper/person/:name', lazyloadRouteHandler('./routes/instapaper/person')); - // UI 中国 router.get('/ui-cn/article', lazyloadRouteHandler('./routes/ui-cn/article')); router.get('/ui-cn/user/:id', lazyloadRouteHandler('./routes/ui-cn/user')); @@ -634,9 +622,6 @@ router.redirect('/matters/hot', '/matters/latest/heat'); // Deprecated router.get('/matters/tags/:tid', lazyloadRouteHandler('./routes/matters/tags')); router.get('/matters/author/:uid', lazyloadRouteHandler('./routes/matters/author')); -// MobData -router.get('/mobdata/report', lazyloadRouteHandler('./routes/mobdata/report')); - // 古诗文网 router.get('/gushiwen/recommend/:annotation?', lazyloadRouteHandler('./routes/gushiwen/recommend')); @@ -653,9 +638,6 @@ router.get('/bupt/funbox', lazyloadRouteHandler('./routes/universities/bupt/funb // 广东海洋大学 router.get('/gdoujwc', lazyloadRouteHandler('./routes/universities/gdou/jwc/jwtz')); -// 马良行 -router.get('/mlhang', lazyloadRouteHandler('./routes/mlhang/latest')); - // PlayStation Store router.get('/ps/list/:gridName', lazyloadRouteHandler('./routes/ps/list')); router.get('/ps/trophy/:id', lazyloadRouteHandler('./routes/ps/trophy')); @@ -665,9 +647,6 @@ router.get('/ps/:lang?/product/:gridName', lazyloadRouteHandler('./routes/ps/pro // Quanta Magazine router.get('/quantamagazine/archive', lazyloadRouteHandler('./routes/quantamagazine/archive')); -// 福利资源-met.red -router.get('/metred/fuli', lazyloadRouteHandler('./routes/metred/fuli')); - // MIT router.get('/mit/graduateadmissions/:type/:name', lazyloadRouteHandler('./routes/universities/mit/graduateadmissions')); router.get('/mit/ocw-top', lazyloadRouteHandler('./routes/universities/mit/ocw-top')); @@ -682,9 +661,6 @@ router.get('/asahi/:genre?/:category?', lazyloadRouteHandler('./routes/asahi/ind // SoundCloud router.get('/soundcloud/tracks/:user', lazyloadRouteHandler('./routes/soundcloud/tracks')); -// 且听风吟福利 -router.get('/qtfyfl/:category', lazyloadRouteHandler('./routes/qtfyfl/category')); - // 派代 router.get('/paidai', lazyloadRouteHandler('./routes/paidai/index')); router.get('/paidai/bbs', lazyloadRouteHandler('./routes/paidai/bbs')); @@ -812,10 +788,6 @@ router.get('/siren/news', lazyloadRouteHandler('./routes/siren/index')); router.get('/xuetangx/course/:cid/:type', lazyloadRouteHandler('./routes/xuetangx/course_info')); router.get('/xuetangx/course/list/:mode/:credential/:status/:type?', lazyloadRouteHandler('./routes/xuetangx/course_list')); -// wikihow -router.get('/wikihow/index', lazyloadRouteHandler('./routes/wikihow/index.js')); -router.get('/wikihow/category/:category/:type', lazyloadRouteHandler('./routes/wikihow/category.js')); - // 正版中国 // router.get('/getitfree/category/:category?', lazyloadRouteHandler('./routes/getitfree/category.js')); // router.get('/getitfree/search/:keyword?', lazyloadRouteHandler('./routes/getitfree/search.js')); @@ -839,9 +811,6 @@ router.get('/keyakizaka46/blog', lazyloadRouteHandler('./routes/keyakizaka46/blo // router.get('/hinatazaka46/blog', lazyloadRouteHandler('./routes/hinatazaka46/blog')); // router.get('/sakurazaka46/blog', lazyloadRouteHandler('./routes/sakurazaka46/blog')); -// 模型网 -router.get('/moxingnet', lazyloadRouteHandler('./routes/moxingnet')); - // 湖北大学 router.get('/hubu/news/:type', lazyloadRouteHandler('./routes/universities/hubu/news')); @@ -859,9 +828,6 @@ router.get('/ctfhub/search/:limit?/:form?/:class?/:title?', lazyloadRouteHandler // 中国日报 router.get('/chinadaily/english/:category', lazyloadRouteHandler('./routes/chinadaily/english.js')); -// DHL -router.get('/dhl/:id', lazyloadRouteHandler('./routes/dhl/shipment-tracking')); - // Hanime router.get('/hanime/video', lazyloadRouteHandler('./routes/hanime/video')); @@ -894,24 +860,12 @@ router.get('/youzan/goods/:id', lazyloadRouteHandler('./routes/youzan/goods')); router.get('/queshu/sale', lazyloadRouteHandler('./routes/queshu/sale')); router.get('/queshu/book/:bookid', lazyloadRouteHandler('./routes/queshu/book')); -// MITRE -router.get('/mitre/publications', lazyloadRouteHandler('./routes/mitre/publications')); - -// SANS -router.get('/sans/summit_archive', lazyloadRouteHandler('./routes/sans/summit_archive')); - // LaTeX 开源小屋 router.get('/latexstudio/home', lazyloadRouteHandler('./routes/latexstudio/home')); // 邮箱 // router.get('/mail/imap/:email/:folder*', lazyloadRouteHandler('./routes/mail/imap')); -// 好队友 -router.get('/network360/jobs', lazyloadRouteHandler('./routes/network360/jobs')); - -// 智联招聘 -router.get('/zhilian/:city/:keyword', lazyloadRouteHandler('./routes/zhilian/index')); - // 北华航天工业学院 - 新闻 router.get('/nciae/news', lazyloadRouteHandler('./routes/universities/nciae/news')); // 北华航天工业学院 - 通知公告 @@ -979,9 +933,6 @@ router.get('/cell/cover', lazyloadRouteHandler('./routes/cell/cover')); router.get('/mcbbs/forum/:type', lazyloadRouteHandler('./routes/mcbbs/forum')); router.get('/mcbbs/post/:tid/:authorid?', lazyloadRouteHandler('./routes/mcbbs/post')); -// Pocket -router.get('/pocket/trending', lazyloadRouteHandler('./routes/pocket/trending')); - // 每日猪价 router.get('/pork-price', lazyloadRouteHandler('./routes/pork-price')); @@ -1073,10 +1024,6 @@ router.get('/galaxylab', lazyloadRouteHandler('./routes/galaxylab/index')); // NOSEC 安全讯息平台 router.get('/nosec/:keykind?', lazyloadRouteHandler('./routes/nosec/index')); -// 新趣集 -router.get('/xinquji/today', lazyloadRouteHandler('./routes/xinquji/today')); -router.get('/xinquji/today/internal', lazyloadRouteHandler('./routes/xinquji/internal')); - // discuz // router.get('/discuz/:ver([7|x])/:cid([0-9]{2})/:link(.*)', lazyloadRouteHandler('./routes/discuz/discuz')); // router.get('/discuz/:ver([7|x])/:link(.*)', lazyloadRouteHandler('./routes/discuz/discuz')); @@ -1091,17 +1038,6 @@ router.get('/weixin/miniprogram/framework', lazyloadRouteHandler('./routes/tence router.get('/weixin/miniprogram/devtools', lazyloadRouteHandler('./routes/tencent/wechat/miniprogram/devtools')); // 开发者工具更新日志 router.get('/weixin/miniprogram/wxcloud/:caty?', lazyloadRouteHandler('./routes/tencent/wechat/miniprogram/wxcloud')); // 云开发更新日志 -// 新冠肺炎疫情动态 -router.get('/coronavirus/caixin', lazyloadRouteHandler('./routes/coronavirus/caixin')); -router.get('/coronavirus/dxy/data/:province?/:city?', lazyloadRouteHandler('./routes/coronavirus/dxy-data')); -router.get('/coronavirus/dxy', lazyloadRouteHandler('./routes/coronavirus/dxy')); -router.get('/coronavirus/scmp', lazyloadRouteHandler('./routes/coronavirus/scmp')); -router.get('/coronavirus/nhc', lazyloadRouteHandler('./routes/coronavirus/nhc')); -router.get('/coronavirus/mogov-2019ncov/:lang', lazyloadRouteHandler('./routes/coronavirus/mogov-2019ncov')); -router.get('/coronavirus/qq/fact', lazyloadRouteHandler('./routes/tencent/factcheck')); -router.get('/coronavirus/sg-moh', lazyloadRouteHandler('./routes/coronavirus/sg-moh')); -router.get('/coronavirus/yahoo-japan/:tdfk?', lazyloadRouteHandler('./routes/coronavirus/yahoo-japan')); - // 南京林业大学教务处 router.get('/njfu/jwc/:category?', lazyloadRouteHandler('./routes/universities/njfu/jwc')); @@ -1137,12 +1073,6 @@ router.get('/haohaozhu/discover/:keyword?', lazyloadRouteHandler('./routes/haoha router.get('/magireco/announcements', lazyloadRouteHandler('./routes/magireco/announcements')); router.get('/magireco/event_banner', lazyloadRouteHandler('./routes/magireco/event_banner')); -// booksource -router.get('/booksource', lazyloadRouteHandler('./routes/booksource/index')); - -// ku -router.get('/ku/:name?', lazyloadRouteHandler('./routes/ku/index')); - // 我有一片芝麻地 router.get('/blogs/hedwig/:type', lazyloadRouteHandler('./routes/blogs/hedwig')); @@ -1186,9 +1116,6 @@ router.get('/hnust/graduate/:type?', lazyloadRouteHandler('./routes/universities // Checkra1n router.get('/checkra1n/releases', lazyloadRouteHandler('./routes/checkra1n/releases')); -// 四川省科学技术厅 -router.get('/sckjt/news/:type?', lazyloadRouteHandler('./routes/sckjt/news')); - // 湖北工业大学 router.get('/hbut/news/:type', lazyloadRouteHandler('./routes/universities/hbut/news')); router.get('/hbut/cs/:type', lazyloadRouteHandler('./routes/universities/hbut/cs')); @@ -1199,10 +1126,6 @@ router.get('/acwifi', lazyloadRouteHandler('./routes/acwifi')); // MIT科技评论 // router.get('/mittrchina/:type', lazyloadRouteHandler('./routes/mittrchina')); -// iYouPort -router.get('/iyouport/article', lazyloadRouteHandler('./routes/iyouport')); -router.get('/iyouport/:category?', lazyloadRouteHandler('./routes/iyouport')); - // etoland router.get('/etoland/:bo_table', lazyloadRouteHandler('./routes/etoland/board')); @@ -1492,13 +1415,6 @@ router.get('/icity/:id', lazyloadRouteHandler('./routes/icity/index')); // 台湾中央通讯社 // router.get('/cna/:id?', lazyloadRouteHandler('./routes/cna/index')); -// 守望先锋 -router.get('/ow/patch', lazyloadRouteHandler('./routes/ow/patch')); - -// 中国工程科技知识中心 -router.get('/cktest/app/:ctgroup?/:domain?', lazyloadRouteHandler('./routes/cktest/app')); -router.get('/cktest/policy', lazyloadRouteHandler('./routes/cktest/policy')); - // 妈咪帮 router.get('/mamibuy/:caty?/:age?/:sort?', lazyloadRouteHandler('./routes/mamibuy/index')); @@ -1542,9 +1458,6 @@ router.get('/citavi/:caty?', lazyloadRouteHandler('./routes/citavi/index')); // Sesame router.get('/sesame/release_notes', lazyloadRouteHandler('./routes/sesame/release_notes')); -// 佐川急便 -router.get('/sagawa/:id', lazyloadRouteHandler('./routes/sagawa/index')); - // QNAP router.get('/qnap/release-notes/:id', lazyloadRouteHandler('./routes/qnap/release-notes')); @@ -1842,9 +1755,6 @@ router.get('/hainanu/ssszs', lazyloadRouteHandler('./routes/hainanu/ssszs')); // 游戏年轮 router.get('/bibgame/:category?/:type?', lazyloadRouteHandler('./routes/bibgame/category')); -// 澳門特別行政區政府各公共部門獎助貸學金服務平台 -router.get('/macau-bolsas/:lang?', lazyloadRouteHandler('./routes/macau-bolsas/index')); - // PotPlayer router.get('/potplayer/update/:language?', lazyloadRouteHandler('./routes/potplayer/update')); diff --git a/lib/routes/booksource/index.js b/lib/routes/booksource/index.js deleted file mode 100644 index 77d130d4def00a..00000000000000 --- a/lib/routes/booksource/index.js +++ /dev/null @@ -1,22 +0,0 @@ -const got = require('@/utils/got'); - -const api = 'http://api.booksource.store/repo/list?sort=update_time&page=1&size=10'; -module.exports = async (ctx) => { - const response = await got.get(api); - const data = response.data; - ctx.state.data = { - title: `BOOKSOURCE.STORE`, - link: 'http://booksource.store/', - description: `BOOKSOURCE.STORE RSS`, - item: data.map((item) => ({ - title: `${item.name} - v${item.version}`, - link: `http://${item.url}`, - author: item.owner, - pubDate: item.update_time, - description: `

网址: ${item.url}

-

作者: ${item.owner}

-

更新时间: ${item.update_time}

-

${item.rank || item.account ? '其它:' : ''} ${item.rank === true ? '排行榜' : ''} ${item.account === true ? '网站账号登录' : ''}

`, - })), - }; -}; diff --git a/lib/routes/cktest/app.js b/lib/routes/cktest/app.js deleted file mode 100644 index 426763259b2ef2..00000000000000 --- a/lib/routes/cktest/app.js +++ /dev/null @@ -1,34 +0,0 @@ -const got = require('@/utils/got'); -const cheerio = require('cheerio'); - -module.exports = async (ctx) => { - const ctgroup = ctx.params.ctgroup ? (ctx.params.ctgroup === '0' ? '' : 'CTGRGUP==' + ctx.params.ctgroup) : ''; - const domain = ctx.params.domain ? 'DOMAIN==' + ctx.params.domain : ''; - - const rootUrl = `http://www.ckcest.cn/home/app/list?category=${ctgroup}${ctgroup && domain ? ' AND ' : ''}${domain}`; - const response = await got({ - method: 'get', - url: rootUrl, - }); - - const $ = cheerio.load(response.data); - const items = $('.search-result-list') - .map((_, item) => { - item = $(item); - const a = item.find('h4.sc-title a'); - return { - title: a.text(), - link: a.attr('href'), - description: item.find('.applySummary-new').text(), - author: item.find('.applyInfor-new span').eq(1).text(), - pubDate: new Date(item.find('.applyInfor-new span').eq(0).text() + ' GMT+8').toUTCString(), - }; - }) - .get(); - - ctx.state.data = { - title: '知识应用 - 中国工程科技知识中心', - link: rootUrl, - item: items, - }; -}; diff --git a/lib/routes/cktest/policy.js b/lib/routes/cktest/policy.js deleted file mode 100644 index 26d6f8673310e0..00000000000000 --- a/lib/routes/cktest/policy.js +++ /dev/null @@ -1,43 +0,0 @@ -const got = require('@/utils/got'); -const cheerio = require('cheerio'); - -module.exports = async (ctx) => { - const id = '1005'; - - const rootUrl = `http://mall.ckcest.cn/mall/listContent.ilf?dbId=${id}&text=&express=&secondSearchExpress=&order=3&page=1&limit=10`; - const response = await got({ - method: 'get', - url: rootUrl, - }); - - const list = response.data.results.datas.map((item) => ({ - link: item.detail_url, - })); - - const items = await Promise.all( - list.map((item) => - ctx.cache.tryGet(item.link, async () => { - const detailResponse = await got({ - method: 'get', - url: item.link, - }); - const content = cheerio.load(detailResponse.data); - - const dateArray = content('meta[name="firstpublishedtime"]').attr('content').split('-'); - const time = dateArray.pop(); - - item.pubDate = `${dateArray.join('-')} ${time}`; - item.title = content('title').text().split('_')[0]; - item.description = content('.wrap').html() || content('.policyLibraryOverview_content').html(); - - return item; - }) - ) - ); - - ctx.state.data = { - title: '产业政策 - 中国工程科技知识中心', - link: rootUrl, - item: items, - }; -}; diff --git a/lib/routes/coronavirus/caixin.js b/lib/routes/coronavirus/caixin.js deleted file mode 100644 index aeaf51bfeb761c..00000000000000 --- a/lib/routes/coronavirus/caixin.js +++ /dev/null @@ -1,34 +0,0 @@ -const got = require('@/utils/got'); -const cheerio = require('cheerio'); -const date = require('@/utils/date'); - -module.exports = async (ctx) => { - const response = await got({ - method: 'get', - url: 'http://m.app.caixin.com/m_topic_detail/1473.html', - }); - - const data = response.data; - - const $ = cheerio.load(data); - const list = $('li.photo'); - - ctx.state.data = { - title: '新冠肺炎防疫全纪录-财新网', - description: $('.lead').html(), - link: 'http://m.app.caixin.com/m_topic_detail/1473.html', - item: - list && - list - .map((index, item) => { - item = $(item); - return { - title: item.find('dt').text(), - description: item.find('dd').html(), - link: item.find('a').attr('href'), - pubDate: date(item.find('em').text()), - }; - }) - .get(), - }; -}; diff --git a/lib/routes/coronavirus/dxy-data.js b/lib/routes/coronavirus/dxy-data.js deleted file mode 100644 index 062ba128496b07..00000000000000 --- a/lib/routes/coronavirus/dxy-data.js +++ /dev/null @@ -1,86 +0,0 @@ -const got = require('@/utils/got'); -const { JSDOM } = require('jsdom'); - -module.exports = async (ctx) => { - const PROVINCE = ctx.params.province || '国内'; - let CITY = ctx.params.city || ''; - - const link = 'https://ncov.dxy.cn/ncovh5/view/pneumonia'; - - const response = await got({ - method: 'get', - url: link, - }); - - const dom = new JSDOM(response.data, { - runScripts: 'dangerously', - }); - - const item = { - description: '', - }; - - let AREA, DATA, META; - - const getProvince = () => { - AREA = PROVINCE; - DATA = dom.window.getAreaStat.find((item) => item.provinceShortName === PROVINCE); - - if (!DATA) { - // 省份名不存在 - return getCountry(); - } - - if (CITY) { - return getCity(); - } - - DATA.cities.forEach((city) => { - item.description += `${city.cityName}累计确诊 ${city.confirmedCount} 例,累计死亡 ${city.deadCount} 例,累计治愈 ${city.curedCount} 例。

`; - }); - - item.title = `${AREA}累计确诊 ${DATA.confirmedCount} 例,现存确诊 ${DATA.currentConfirmedCount} 例,累计死亡 ${DATA.deadCount} 例,累计治愈 ${DATA.curedCount} 例`; - }; - - const getCity = () => { - AREA = CITY; - DATA = DATA.cities.find((c) => c.cityName.includes(CITY)); - - if (DATA) { - item.title = `${DATA.cityName}累计确诊 ${DATA.confirmedCount} 例,现存确诊 ${DATA.currentConfirmedCount} 例,累计死亡 ${DATA.deadCount} 例,累计治愈 ${DATA.curedCount} 例`; - } else { - // 城市不存在 - CITY = ''; - return getProvince(); - } - }; - - const getCountry = () => { - AREA = '国内'; - META = dom.window.getStatisticsService; - - item.title = `国内累计确诊 ${META.confirmedCount} 例${META.confirmedIncr ? `(较昨日 ${(META.confirmedIncr > 0 ? '+' : '') + META.confirmedIncr})` : ''},现存确诊 ${META.currentConfirmedCount} 例${ - META.currentConfirmedIncr ? `(较昨日 ${(META.currentConfirmedIncr > 0 ? '+' : '') + META.currentConfirmedIncr})` : '' - },累计死亡 ${META.deadCount} 例${META.deadIncr ? `(较昨日 ${(META.deadIncr > 0 ? '+' : '') + META.deadIncr})` : ''},累计治愈 ${META.curedCount} 例${ - META.curedIncr ? `(较昨日 ${(META.curedIncr > 0 ? '+' : '') + META.curedIncr})` : '' - }`; - }; - - if (PROVINCE !== '国内' && PROVINCE !== '全国') { - getProvince(); - } else { - getCountry(); - } - - if (META && META.modifyTime) { - item.pubDate = new Date(META.modifyTime).toUTCString(); - } - item.link = link; - item.guid = item.title; - - ctx.state.data = { - title: `${AREA}新冠病毒疫情数据统计 - 丁香园`, - link, - item: [item], - }; -}; diff --git a/lib/routes/coronavirus/dxy.js b/lib/routes/coronavirus/dxy.js deleted file mode 100644 index c95f1688a7e63c..00000000000000 --- a/lib/routes/coronavirus/dxy.js +++ /dev/null @@ -1,27 +0,0 @@ -const got = require('@/utils/got'); -const { JSDOM } = require('jsdom'); - -module.exports = async (ctx) => { - const response = await got({ - method: 'get', - url: 'https://ncov.dxy.cn/ncovh5/view/pneumonia', - }); - - const dom = new JSDOM(response.data, { - runScripts: 'dangerously', - }); - - const data = dom.window.getTimelineService1; - - ctx.state.data = { - title: '全球新型肺炎疫情实时播报-丁香园', - link: 'https://ncov.dxy.cn/ncovh5/view/pneumonia', - item: data.map((item) => ({ - title: item.title, - description: item.summary, - pubDate: new Date(item.pubDate).toUTCString(), - author: item.infoSource, - link: item.sourceUrl, - })), - }; -}; diff --git a/lib/routes/coronavirus/mogov-2019ncov.js b/lib/routes/coronavirus/mogov-2019ncov.js deleted file mode 100644 index 4cf18378e8c625..00000000000000 --- a/lib/routes/coronavirus/mogov-2019ncov.js +++ /dev/null @@ -1,49 +0,0 @@ -const got = require('@/utils/got'); -const cheerio = require('cheerio'); - -module.exports = async (ctx) => { - const language = ctx.params.lang.toLowerCase(); - const languageKey = language === 'ch' ? 'zhant' : language; - - const dataUrl = 'https://gcloud.gcs.gov.mo/json/ncvbase.json'; - const response = await got({ - method: 'get', - url: dataUrl, - }); - - const items = response.data.json - .filter((item) => item['broadcastStatus_' + languageKey] === 'Broadcasted') - .slice(0, 20) - .map((item) => { - const title = item['subject_' + languageKey]; - const $ = cheerio.load('
'); - if (item.contentPhotos) { - $('#photo').append(item.contentPhotos.map((photo) => ``)); - } - $('#content').append(item['content_' + languageKey]); - $('#department').append(item['departments_' + languageKey]); - const description = $('#root').html(); - const pubDate = new Date(item['broadcastTime_' + languageKey] + ' +8').toUTCString(); - const link = item['url_' + languageKey]; - return { - title, - description, - pubDate, - link, - }; - }); - - const titleMapping = { - ch: '澳門特別行政區政府 抗疫專頁:最新消息', - pt: 'Macau Pagina Electrónica Especial Contra Epidemias: Notícias', - en: 'Macao Pagina Electrónica Especial Contra Epidemias: What’s New', - }; - const sourceLink = `https://www.ssm.gov.mo/apps1/PreventWuhanInfection/${language}.aspx`; - - ctx.state.data = { - title: titleMapping[language], - link: sourceLink, - description: titleMapping[language], - item: items, - }; -}; diff --git a/lib/routes/coronavirus/nhc.js b/lib/routes/coronavirus/nhc.js deleted file mode 100644 index 8c6ba20d0ca29c..00000000000000 --- a/lib/routes/coronavirus/nhc.js +++ /dev/null @@ -1,30 +0,0 @@ -const cheerio = require('cheerio'); -const got = require('@/utils/got'); - -module.exports = async (ctx) => { - const url = `http://www.nhc.gov.cn/xcs/yqtb/list_gzbd.shtml`; - - const res = await got.get(url); - const $ = cheerio.load(res.data); - const list = $('.zxxx_list a'); - ctx.state.data = { - title: '疫情通报-国家卫健委', - link: url, - item: - list && - list - .map((index, item) => { - item = $(item); - const title = item.text(); - const address = item.attr('href'); - const host = `http://www.nhc.gov.cn/`; - return { - title, - description: title, - link: host + address, - guid: host + address, - }; - }) - .get(), - }; -}; diff --git a/lib/routes/coronavirus/scmp.js b/lib/routes/coronavirus/scmp.js deleted file mode 100644 index 4fa6c8d460afdb..00000000000000 --- a/lib/routes/coronavirus/scmp.js +++ /dev/null @@ -1,32 +0,0 @@ -const got = require('@/utils/got'); -const cheerio = require('cheerio'); - -module.exports = async (ctx) => { - const response = await got({ - method: 'get', - url: 'https://www.scmp.com/topics/coronavirus-outbreak', - }); - - const data = response.data; - - const $ = cheerio.load(data); - const list = $('.article'); - - ctx.state.data = { - title: 'China coronavirus outbreak - SCMP', - description: $('.topic__desc--p').html(), - link: 'https://www.scmp.com/topics/coronavirus-outbreak', - item: - list && - list - .map((index, item) => { - item = $(item); - return { - title: item.find('.article__title').text(), - description: item.find('.article__summary').html(), - link: item.find('.article__link').attr('href') || item.find('.article-title__article-link').attr('href'), - }; - }) - .get(), - }; -}; diff --git a/lib/routes/coronavirus/sg-moh.js b/lib/routes/coronavirus/sg-moh.js deleted file mode 100644 index 94fbeb54c6b80f..00000000000000 --- a/lib/routes/coronavirus/sg-moh.js +++ /dev/null @@ -1,40 +0,0 @@ -const got = require('@/utils/got'); -const cheerio = require('cheerio'); - -module.exports = async (ctx) => { - const dataUrl = 'https://www.moh.gov.sg/covid-19/past-updates'; - const response = await got({ - method: 'get', - url: dataUrl, - }); - - const $ = cheerio.load(response.data); - const list = $('section.body-content div.sfContentBlock:nth-of-type(2) table tr').slice(1, 21); - - const items = list - .filter((_, item) => { - item = $(item); - const dateRaw = item.find('td:first-child').text().trim(); - return dateRaw !== 'Date'; - }) - .map((_, item) => { - item = $(item); - const title = item.find('a').first().text(); - const dateRaw = item.find('td:first-child').text().trim(); - const pubDate = Date.parse(dateRaw) && dateRaw; - const link = item.find('a').attr('href'); - return { - title, - pubDate, - link, - }; - }) - .get(); - - ctx.state.data = { - title: 'Past Updates On COVID-19 Local Situation', - link: dataUrl, - description: 'Past Updates On COVID-19 Local Situation', - item: items, - }; -}; diff --git a/lib/routes/coronavirus/yahoo-japan.js b/lib/routes/coronavirus/yahoo-japan.js deleted file mode 100644 index 50aa1fae7fb593..00000000000000 --- a/lib/routes/coronavirus/yahoo-japan.js +++ /dev/null @@ -1,77 +0,0 @@ -const got = require('@/utils/got'); -const cheerio = require('cheerio'); -const dayjs = require('dayjs'); - -module.exports = async (ctx) => { - const tdfk = ctx.params.tdfk || false; - const uri = tdfk ? `https://news.yahoo.co.jp/pages/article/covid19${tdfk}` : `https://news.yahoo.co.jp/pages/article/20200207`; - const req_header = { 'User-Agent': 'Mozilla/5.0 (Linux; Android 9; SM-G960F Build/PPR1.180610.011; wv) AppleWebKit/537.36 (KHTML, like Gecko) Version/4.0 Chrome/74.0.3729.157 Mobile Safari/537.36' }; - - const resp = await got({ - method: 'get', - url: uri, - headers: req_header, - }); - - const $ = cheerio.load(resp.data); - - const this_year = dayjs().year(); - const this_month = dayjs().month() + 1; - - const art_uri = []; - $('#layoutFooter ul.dlpThumbLink a').each((i, e) => { - const link = $(e).attr('href'); - const text = $(e).find('.dlpThumbText span').eq(0).text(); - const author = $(e).find('.dlpQuote').text(); - const date = $(e).find('.dlpDate').text() + ' +9'; // explicit timezone - - let date_obj = dayjs(date).year(this_year); - - if (date_obj.month() + 1 > this_month) { - // if the article is from the last year - date_obj = date_obj.year(this_year - 1); - } - - art_uri.push({ l: link, t: text, a: author, d: date_obj.toString() }); - }); - - const getNews = async (uri) => { - const ret = { - link: uri.l, - title: uri.t, - author: uri.a, - pubDate: uri.d, - description: null, - }; - - if (!uri.l.includes('//news.yahoo.co.jp')) { - return ret; // do not process uncertain pages - } - - const page_data = await ctx.cache.tryGet(uri.l, async () => { - const resp = await got({ - method: 'get', - url: uri.l, - headers: req_header, - }); - return resp.data; - }); - - const $doc = cheerio.load(page_data); - - const iso_date = $doc('meta[name="pubdate"]').attr('content'); - ret.pubDate = dayjs(iso_date).toString(); - ret.description = $doc('div.article_body').html() || $doc('meta[name="description"]').attr('content'); - - return ret; - }; - - const items = await Promise.all(art_uri.map(getNews)); - - ctx.state.data = { - title: $('title').text(), - link: uri, - description: $('meta[name="description"]').attr('content'), - item: items, - }; -}; diff --git a/lib/routes/dhl/shipment-tracking.js b/lib/routes/dhl/shipment-tracking.js deleted file mode 100644 index fd49497eff647b..00000000000000 --- a/lib/routes/dhl/shipment-tracking.js +++ /dev/null @@ -1,56 +0,0 @@ -const got = require('@/utils/got'); - -const monthMap = { - 一月: 0, - 二月: 1, - 三月: 2, - 四月: 3, - 五月: 4, - 六月: 5, - 七月: 6, - 八月: 7, - 九月: 8, - 十月: 9, - 十一月: 10, - 十二月: 11, -}; - -module.exports = async (ctx) => { - const id = ctx.params && ctx.params.id; - - const response = await got({ - method: 'get', - url: `https://www.logistics.dhl/shipmentTracking?AWB=${id}&countryCode=CN&languageCode=zh`, - headers: { - Accept: 'application/json', - }, - }); - const data = response.data; - const result = data.results[0]; - - const link = `https://www.logistics.dhl/cn-zh/home/tracking/tracking-express.html?tracking-id=${id}`; - - ctx.state.data = { - title: `Shipment tracking for DHL (${id})`, - link, - item: result.checkpoints.map((checkpoint) => { - const [, month, day, year] = checkpoint.date.match(/^[^,]+, ([^ ]+) (\d+), (\d+)/i); - const [, hour, minute] = checkpoint.time.match(/(\d+):(\d+)/); - const date = new Date(); - - date.setFullYear(year); - date.setMonth(monthMap[month]); - date.setDate(day); - date.setHours(hour); - date.setMinutes(minute); - date.setSeconds(0); - date.setMilliseconds(0); - - return { - title: checkpoint.description, - pubDate: date.toUTCString(), - link: `${link}&checkpoint=${encodeURIComponent(checkpoint.counter)}`, - }; - }), - }; -}; diff --git a/lib/routes/fitchratings/site.js b/lib/routes/fitchratings/site.js deleted file mode 100644 index dfa6f937279cfb..00000000000000 --- a/lib/routes/fitchratings/site.js +++ /dev/null @@ -1,33 +0,0 @@ -const got = require('@/utils/got'); -const cheerio = require('cheerio'); - -module.exports = async (ctx) => { - const type = ctx.params.type; - - const link = `https://www.fitchratings.com/site/${type}`; - const listData = await got.get(link); - const $list = cheerio.load(listData.data); - ctx.state.data = { - title: `${type} - 惠誉评级`, - link, - item: await Promise.all( - $list('div.card-text-container') - .slice(0, 10) - .map((_, el) => { - const $el = $list(el); - const $a = $el.find('h4 a'); - - const href = $a.attr('href'); - const title = $a.text(); - const description = $el.find('div p').text(); - - return { - title, - description, - link: href, - }; - }) - .get() - ), - }; -}; diff --git a/lib/routes/instapaper/person.js b/lib/routes/instapaper/person.js deleted file mode 100644 index eb48440d5a3799..00000000000000 --- a/lib/routes/instapaper/person.js +++ /dev/null @@ -1,28 +0,0 @@ -const got = require('@/utils/got'); -const cheerio = require('cheerio'); - -module.exports = async (ctx) => { - const name = ctx.params.name; - const link = `https://www.instapaper.com/p/${name}`; - - const response = await got.get(link); - const $ = cheerio.load(response.data); - - const out = $('article.article_item.article_browse') - .slice(0, 10) - .map(function () { - const info = { - title: $(this).find('div.js_title_row.title_row a').attr('title'), - link: $(this).find('div.js_title_row.title_row a').attr('href'), - description: $(this).find('div.article_preview').text(), - }; - return info; - }) - .get(); - - ctx.state.data = { - title: `${name}-Instapaper分享`, - link, - item: out, - }; -}; diff --git a/lib/routes/iyouport/index.js b/lib/routes/iyouport/index.js deleted file mode 100644 index d779c82308d01e..00000000000000 --- a/lib/routes/iyouport/index.js +++ /dev/null @@ -1,35 +0,0 @@ -const parser = require('@/utils/rss-parser'); -const utils = require('./utils'); - -module.exports = async (ctx) => { - let category = ctx.params.category_id; - if (category === 'article') { - category = ''; - } // backward compatability - const rssUrl = category ? `https://www.iyouport.org/category/${category}/atom` : `https://www.iyouport.org/atom`; - const feed = await parser.parseURL(rssUrl); - - const items = await Promise.all( - feed.items.map((item) => - ctx.cache.tryGet(item.link, async () => ({ - title: item.title, - id: item.guid, - pubDate: new Date(item.pubDate).toUTCString(), - author: item.creator, - link: item.link, - description: await utils.ProcessFeed(item.link), - category: item.categories, - icon: 'https://i2.wp.com/www.iyouport.org/wp-content/uploads/2019/04/cropped-iyouport-2.png', - })) - ) - ); - - ctx.state.data = { - title: feed.title, - link: feed.link, - description: feed.description, - item: items, - language: 'zh-cn', - icon: 'https://i2.wp.com/www.iyouport.org/wp-content/uploads/2019/04/cropped-iyouport-2.png', - }; -}; diff --git a/lib/routes/iyouport/utils.js b/lib/routes/iyouport/utils.js deleted file mode 100644 index a30b41fffc5157..00000000000000 --- a/lib/routes/iyouport/utils.js +++ /dev/null @@ -1,22 +0,0 @@ -const got = require('@/utils/got'); -const cheerio = require('cheerio'); - -const ProcessFeed = async (link) => { - const fullTextGet = await got.get(link); - const $ = cheerio.load(fullTextGet.data); - $('iframe').remove(); - $('.wpcnt').remove(); - $('.sharedaddy.sd-sharing-enabled').remove(); - $('.sharedaddy.sd-block.sd-like.jetpack-likes-widget-wrapper.jetpack-likes-widget-unloaded').remove(); - $('.jp-relatedposts').remove(); - $('.entry-content noscript').remove(); - $('.entry-content img').removeAttr('data-lazy-src'); - $('.entry-content img').removeAttr('data-lazy-srcset'); - $('.entry-content img').removeAttr('srcset'); - const fullText = $('.entry-content').html(); - return fullText; -}; - -module.exports = { - ProcessFeed, -}; diff --git a/lib/routes/ku/index.js b/lib/routes/ku/index.js deleted file mode 100644 index ad6863517c46c5..00000000000000 --- a/lib/routes/ku/index.js +++ /dev/null @@ -1,31 +0,0 @@ -const got = require('@/utils/got'); - -const nameProps = { - yuedu: '阅读', - yiciyuan: '异次元', - haikuo: '海阔', -}; - -module.exports = async (ctx) => { - const name = ctx.params.name || 'yuedu'; - const api = `http://ku.mumuceo.com/${name}/index/getlist`; - const response = await got.post(api, { - json: { - page: 1, - limit: 10, - }, - }); - const data = response.data.data; - ctx.state.data = { - title: `${nameProps[name]} - 源仓库`, - link: 'http://ku.mumuceo.com/', - description: `源仓库 - ${nameProps[name]} RSS`, - item: data.map((item) => ({ - title: item.yuansite, - link: `http://ku.mumuceo.com/${name}/detail/index/id/${item.id}.html`, - author: item.username, - pubDate: item.time, - description: item.yuan, - })), - }; -}; diff --git a/lib/routes/macau-bolsas/index.js b/lib/routes/macau-bolsas/index.js deleted file mode 100644 index fd9bda0ab266c8..00000000000000 --- a/lib/routes/macau-bolsas/index.js +++ /dev/null @@ -1,47 +0,0 @@ -const got = require('@/utils/got'); -const cheerio = require('cheerio'); - -module.exports = async (ctx) => { - const lang = ctx.params.lang; - const url = `https://www.bolsas.gov.mo/${lang === 'pt' ? lang : ''}`; - const response = await got({ - method: 'get', - url, - }); - const $Wrapper = cheerio.load(response.data); - const liItems = $Wrapper('ul.news-list li'); - const items = await Promise.all( - liItems && - liItems - .map(async (_, item) => { - const $item = $Wrapper(item); - const $newsItem = $item.find('.news-item'); - const bureau = $newsItem.find('.label').text(); - const title = $newsItem.find('.title').text(); - const link = $newsItem.find('.title').attr('href'); - const pubDate = new Date($item.find('.date').text() + 'T00:00:00+0800'); - const description = await ctx.cache.tryGet(link, async () => { - const response = await got({ - method: 'get', - url: link, - }); - const $ = cheerio.load(response.data); - return $('.news-content').html(); - }); - return Promise.resolve({ - title: `[${bureau}] ${title}`, - link, - description, - pubDate, - }); - }) - .get() - ); - - ctx.state.data = { - title: '澳門特別行政區政府各公共部門獎助貸學金服務平台', - link: url, - description: '澳門特別行政區政府各公共部門獎助貸學金服務平台', - item: items, - }; -}; diff --git a/lib/routes/metred/fuli.js b/lib/routes/metred/fuli.js deleted file mode 100644 index 6f3739134f1ade..00000000000000 --- a/lib/routes/metred/fuli.js +++ /dev/null @@ -1,42 +0,0 @@ -const got = require('@/utils/got'); - -async function getItemDetail(itemId, ctx) { - const link = `https://met.red/api/h/weal/getSingleDetail?wealId=${itemId}`; - - const cache = ctx.cache.get(link); - if (cache) { - return cache; - } - - const { data: response } = await got.get(link); - const image = `
`; - const coupon = response.data.url ? `
点击前往活动
` : ''; - const content = image + coupon + response.data.content; - - ctx.cache.set(link, content); - - return content; -} - -async function getItemList() { - const response = await got('https://met.red/api/h/weal/getListForData'); - return response.data.data; -} - -module.exports = async (ctx) => { - const itemList = await getItemList(); - - ctx.state.data = { - title: '福利资源-met.red', - url: 'https://met.red/h/weal/list', - description: '福利资源更新提醒', - item: await Promise.all( - itemList.map(async (item) => ({ - title: item.name, - link: `https://met.red/h/weal/detail/${item.id}`, - description: await getItemDetail(item.id, ctx), - guid: item.id, - })) - ), - }; -}; diff --git a/lib/routes/mitre/publications.js b/lib/routes/mitre/publications.js deleted file mode 100644 index c21ea1ef0ac897..00000000000000 --- a/lib/routes/mitre/publications.js +++ /dev/null @@ -1,27 +0,0 @@ -// MITRE - All Publications - -// const got = require('@/utils/got'); -// const cheerio = require('cheerio'); -const buildData = require('@/utils/common-config'); - -module.exports = async (ctx) => { - const link = `https://www.mitre.org/publications/all`; - const host = `https://www.mitre.org`; - ctx.state.data = await buildData({ - link, - url: link, - title: `%title%`, - params: { - title: 'MITRE: All Publications', - host, - link, - }, - item: { - item: 'div.list-item', - title: `$('div.list-item div.list-main a span.title').text()`, - link: `'%host%' + $('div.list-item div.list-main a').attr('href')`, - category: `$('div.list-item div.list-main a span.time').text()`, - description: `$('div.list-item div.list-main a span.teaser').html()`, - }, - }); -}; diff --git a/lib/routes/mlhang/latest.js b/lib/routes/mlhang/latest.js deleted file mode 100644 index afecf98b1fbff0..00000000000000 --- a/lib/routes/mlhang/latest.js +++ /dev/null @@ -1,23 +0,0 @@ -const got = require('@/utils/got'); -const api_url = 'https://www.mlhang.com/search/contents?start=0&count=10'; -const host = 'https://www.mlhang.com'; - -module.exports = async (ctx) => { - const response = await got({ - method: 'get', - url: api_url, - }); - const data = response.data.data.docs; - - ctx.state.data = { - title: '马良行|建筑行业知识分享平台', - link: host, - description: '马良行文章更新提醒', - item: data.map((item) => ({ - title: item['title.0.name'], - description: item.detail, - pubDate: new Date(item.updateTime * 1), - link: host + item.resurl, - })), - }; -}; diff --git a/lib/routes/mobdata/report.js b/lib/routes/mobdata/report.js deleted file mode 100644 index b8ca229262112d..00000000000000 --- a/lib/routes/mobdata/report.js +++ /dev/null @@ -1,30 +0,0 @@ -const got = require('@/utils/got'); -const date = require('@/utils/date'); - -module.exports = async (ctx) => { - const apiUrl = 'http://admin.mob.com/api/mobdata/report/list'; - const pageUrl = 'http://mobdata.mob.com/mobdata/report'; - - const resp = await got({ - method: 'post', - url: apiUrl, - headers: { - Referer: pageUrl, - 'Content-Type': 'application/json', - }, - }); - - const list = resp.data.list; - const items = list.map((item) => ({ - title: item.title, - description: `${item.desc}
查看报告`, - pubDate: date(item.created_at), - link: item.report_path, - })); - ctx.state.data = { - title: 'MobData分析报告', - link: pageUrl, - description: 'MobData分析报告', - item: items, - }; -}; diff --git a/lib/routes/moxingnet/index.js b/lib/routes/moxingnet/index.js deleted file mode 100644 index 5f4f6e13a2f19f..00000000000000 --- a/lib/routes/moxingnet/index.js +++ /dev/null @@ -1,61 +0,0 @@ -const got = require('@/utils/got'); -const cheerio = require('cheerio'); -const iconv = require('iconv-lite'); - -module.exports = async (ctx) => { - const baseUrl = 'http://moxing.net/'; - const response = await got({ - method: 'get', - url: baseUrl, - responseType: 'buffer', - }); - const data = iconv.decode(response.data, 'gb2312'); - const $ = cheerio.load(data); - const list = $('ul.text_list.text_list_f14 li') - .get() - .map((item) => { - const $ = cheerio.load(item); - return baseUrl + $('a').attr('href'); - }) - .filter((link) => !link.includes('taobao')); - - const ProcessLink = async (link) => { - const response = await got({ - method: 'get', - url: link, - responseType: 'buffer', - }); - const data = iconv.decode(response.data, 'gb2312'); - const $ = cheerio.load(data); - - let desc = $('#endtext').html(); - const next_page_link = $('#pages').children().last().attr('href'); - if (next_page_link !== undefined && baseUrl + next_page_link !== link) { - const next_page = await ProcessLink(baseUrl + next_page_link); - desc += next_page.desc; - } - return { - title: $('title').text(), - desc, - }; - }; - - const out = await Promise.all( - list.map(async (link) => { - const cache = await ctx.cache.get(link); - if (cache) { - return Promise.resolve(JSON.parse(cache)); - } - - const feed = await ProcessLink(link); - const single = { - title: feed.title, - description: feed.desc, - link, - }; - ctx.cache.set(link, JSON.stringify(single)); - return Promise.resolve(single); - }) - ); - ctx.state.data = { title: '模型网', link: baseUrl, item: out }; -}; diff --git a/lib/routes/network360/jobs.js b/lib/routes/network360/jobs.js deleted file mode 100644 index e9751da42d706f..00000000000000 --- a/lib/routes/network360/jobs.js +++ /dev/null @@ -1,24 +0,0 @@ -const got = require('@/utils/got'); - -module.exports = async (ctx) => { - const response = await got({ - method: 'get', - url: `https://ourwork-api.nework360.com/job/getHotJobList?pageNum=1&limit=100`, - }); - - const data = response.data.data; - - const items = data.map((jobDetail) => ({ - title: jobDetail.title, - link: `https://www.nework360.com/job/detail/${jobDetail.jobId}`, - author: jobDetail.publisherId, - description: jobDetail.description, - pubDate: new Date(jobDetail.createTime).toUTCString(), - })); - - ctx.state.data = { - title: '好队友-远程工作', - link: 'https://www.nework360.com/job/hots', - item: items, - }; -}; diff --git a/lib/routes/ow/patch.js b/lib/routes/ow/patch.js deleted file mode 100644 index 3e5f027ae0f09f..00000000000000 --- a/lib/routes/ow/patch.js +++ /dev/null @@ -1,23 +0,0 @@ -const got = require('@/utils/got'); - -module.exports = async (ctx) => { - const rootUrl = 'https://ow.blizzard.cn'; - const currentUrl = `${rootUrl}/action/article/patch?p=1&pageSize=10`; - const response = await got({ - method: 'get', - url: currentUrl, - }); - - const items = response.data.data.list.map((item) => ({ - title: item.description, - link: `${rootUrl}/article/news/${item.articleId}`, - description: item.content, - pubDate: new Date(item.publishTime).toUTCString(), - })); - - ctx.state.data = { - title: '《守望先锋》补丁说明', - link: `${rootUrl}/game/patch-notes`, - item: items, - }; -}; diff --git a/lib/routes/pocket/trending.js b/lib/routes/pocket/trending.js deleted file mode 100644 index c03c69fc803692..00000000000000 --- a/lib/routes/pocket/trending.js +++ /dev/null @@ -1,31 +0,0 @@ -const got = require('@/utils/got'); -const cheerio = require('cheerio'); - -module.exports = async (ctx) => { - const url = 'https://getpocket.com/explore/trending'; - - const response = await got.get(url); - const $ = cheerio.load(response.data); - - const list = $('article').get(); - ctx.state.data = { - title: 'Trending on Pocket', - description: 'Top Articles and Videos about Trending on Pocket', - link: url, - item: list.map((item) => { - item = $(item); - const middle_link = new URL(item.find('a').first().attr('href')); - const media = item - .find('.media') - .attr('style') - .match(/url\('(.*?)'\);/)[1]; - const pic_html = media ? `` : ''; - return { - title: item.find('.title').text(), - author: item.find('.details > span').first().text(), - description: `

${item.find('.excerpt').text()}

` + pic_html, - link: middle_link.searchParams.get('url') || middle_link.href, - }; - }), - }; -}; diff --git a/lib/routes/qtfyfl/category.js b/lib/routes/qtfyfl/category.js deleted file mode 100644 index 6fe704bf014cbf..00000000000000 --- a/lib/routes/qtfyfl/category.js +++ /dev/null @@ -1,91 +0,0 @@ -const got = require('@/utils/got'); -const cheerio = require('cheerio'); - -const categoryCodes = { - latest: '最新文章', - fulishe: '福利社', - qiuchuchu: '求出处', - taotuji: '套图集', - menshijian: '门事件', - neihantu: '内涵图', - // "zngirls":"宅男女神", - dianyingxiazai: '电影下载', - yingshi: '影视资讯', - dianshiju: '电视剧下载', - dongman: '动漫下载', - caidan: '电影彩蛋', - juqing: '影视剧情', - zhangzishi: '涨姿势', - yule: '娱乐', - mingxing: '明星八卦', - music: '音乐歌曲', - games: '游戏', - software: '电脑软件', - shishiredian: '实时热点', - xljt: '心灵鸡汤', - fhdq: '符号大全', - guoji: '国际新闻', - tech: '科技苑', - other: '其他', - // "youqiubiying": "有求必应", -}; - -const host = 'http://www.qtfy9.com'; - -module.exports = async (ctx) => { - const category = ctx.params.category; - const iTitle = categoryCodes[category]; - let link; - if (category === 'latest') { - link = host; - } else { - link = host + `/${category}`; - } - const response = await got.get(link); - - const $ = cheerio.load(response.data); - - const list = $('article') - .slice(0, 21) - .map(function () { - const info = { - title: $(this).find('header').find('h2').find('a').attr('title'), - link: $(this).find('header').find('h2').find('a').attr('href'), - }; - return info; - }) - .get(); - - const out = await Promise.all( - list.map(async (info) => { - const title = info.title; - const itemUrl = info.link; - - const cache = await ctx.cache.get(itemUrl); - if (cache) { - return Promise.resolve(JSON.parse(cache)); - } - - const response = await got.get(itemUrl); - - const $ = cheerio.load(response.data); - const description = $('div.txt').html().trim(); - const date = $('time').text(); - - const single = { - title, - link: itemUrl, - description, - pubDate: new Date(date).toUTCString(), - }; - ctx.cache.set(itemUrl, JSON.stringify(single)); - return Promise.resolve(single); - }) - ); - - ctx.state.data = { - title: `${iTitle}-且听风吟福利`, - link, - item: out, - }; -}; diff --git a/lib/routes/sagawa/index.js b/lib/routes/sagawa/index.js deleted file mode 100644 index a7be78d8baec9f..00000000000000 --- a/lib/routes/sagawa/index.js +++ /dev/null @@ -1,67 +0,0 @@ -const got = require('@/utils/got'); -const cheerio = require('cheerio'); - -module.exports = async (ctx) => { - const rootUrl = 'http://k2k.sagawa-exp.co.jp/p/sagawa/web/okurijoinput.jsp'; - - let response = await got({ - method: 'get', - url: rootUrl, - }), - $ = cheerio.load(response.data); - - response = await got({ - method: 'post', - url: rootUrl, - form: { - jsf_tree_64: $('#jsf_tree_64').attr('value'), - jsf_state_64: $('#jsf_state_64').attr('value'), - jsf_viewid: '/web/okurijoinput.jsp', - 'main:no1': ctx.params.id, - 'main:no2': '', - 'main:no3': '', - 'main:no4': '', - 'main:no5': '', - 'main:no6': '', - 'main:no7': '', - 'main:no8': '', - 'main:no9': '', - 'main:no10': '', - 'main:correlation': 1, - 'main:toiStart': 'Track it', - main_SUBMIT: 1, - 'main:_link_hidden_': '', - }, - }); - - $ = cheerio.load(response.data); - - let items = $('.table_okurijo_detail2').eq(1).find('tr').slice(1); - - items = items - .map((index, item) => { - item = $(item); - const td = item.find('td'); - - let pubDate = td.eq(1).text(); - if (pubDate.length === 79) { - pubDate = `${new Date().getFullYear()}/${td.eq(1).text()}`; - } - - const description = index === items.length - 1 ? `

${$('.ttl02 tbody tr').eq(1).text().replace('  ', '')}

` : ''; - - return { - link: rootUrl, - title: `${td.eq(1).text()} ${td.eq(0).text()} ${td.eq(2).text()}`, - pubDate: new Date(pubDate + ' GMT+9').toUTCString(), - description, - }; - }) - .get(); - - ctx.state.data = { - title: `佐川急便 - ${ctx.params.id}`, - link: rootUrl, - item: items, - }; -}; diff --git a/lib/routes/sans/summit_archive.js b/lib/routes/sans/summit_archive.js deleted file mode 100644 index 5c799c1c31a077..00000000000000 --- a/lib/routes/sans/summit_archive.js +++ /dev/null @@ -1,24 +0,0 @@ -// const got = require('@/utils/got'); -// const cheerio = require('cheerio'); -const buildData = require('@/utils/common-config'); - -module.exports = async (ctx) => { - const link = `https://www.sans.org/cyber-security-summit/archives/`; - const host = `https://www.sans.org`; - ctx.state.data = await buildData({ - link, - url: link, - title: `%title%`, - params: { - title: 'SANS Institute: Summit Archives', - host, - link, - }, - item: { - item: 'li.bottom-buffer', - title: `$('li.bottom-buffer strong').text()`, - link: `'%link%'`, - description: `$('li.bottom-buffer ul').html()`, - }, - }); -}; diff --git a/lib/routes/sckjt/news.js b/lib/routes/sckjt/news.js deleted file mode 100644 index 5c27898d6eb745..00000000000000 --- a/lib/routes/sckjt/news.js +++ /dev/null @@ -1,35 +0,0 @@ -const got = require('@/utils/got'); -const cheerio = require('cheerio'); - -const baseUrl = 'http://kjt.sc.gov.cn'; -const dateRegex = /\((\d{4})-(\d{2})-(\d{2})\)/; - -const map = { - tz: '/tz/index.jhtml', - gs: '/gs/index.jhtml', -}; - -module.exports = async (ctx) => { - const type = ctx.params.type || 'tz'; - const response = await got({ - method: 'get', - url: baseUrl + map[type], - }); - - const data = response.data; - const $ = cheerio.load(data); - ctx.state.data = { - title: '四川省科学技术厅', - link: baseUrl, - item: $('div[class="news_middle_top"]') - .next('div') - .children('h2') - .slice(0, 15) - .map((_, elem) => ({ - link: baseUrl + $(elem).children('a').attr('href'), - title: $(elem).children('a').text(), - pubDate: new Date($(elem).children('span').text().replace(dateRegex, '$1-$2-$3')).toUTCString(), - })) - .get(), - }; -}; diff --git a/lib/routes/tssstatus/index.js b/lib/routes/tssstatus/index.js deleted file mode 100644 index 597101d9d43cf0..00000000000000 --- a/lib/routes/tssstatus/index.js +++ /dev/null @@ -1,35 +0,0 @@ -const got = require('@/utils/got'); - -module.exports = async (ctx) => { - const { board, build } = ctx.params; - const response = await got({ - method: 'get', - url: `http://api.ineal.me/tss/${board}/${build}`, - }); - - const resultItem = Object.values(response.data).map((item) => { - const firmware = item.firmwares[0]; - const description = ` - signing: ${firmware.signing.toString()}
- started: ${firmware.started}
- stopped: ${firmware.stopped}
- model: ${item.model}
- board: ${item.board}
- version: ${firmware.version}
- build: ${firmware.build}
- `; - - return { - title: `signing: ${firmware.signing.toString()}-${item.model}-${firmware.version}`, - description, - guid: `${firmware.started} / ${firmware.stopped}`, - }; - }); - - ctx.state.data = { - title: 'TSSstatus', - link: 'http://api.ineal.me/tss/status', - description: "Real time status of every iOS firmware currently being signed by Apple's TSS server.", - item: resultItem, - }; -}; diff --git a/lib/routes/wikihow/category.js b/lib/routes/wikihow/category.js deleted file mode 100644 index 2da08f83ae649e..00000000000000 --- a/lib/routes/wikihow/category.js +++ /dev/null @@ -1,34 +0,0 @@ -const got = require('@/utils/got'); -const cheerio = require('cheerio'); - -module.exports = async (ctx) => { - const { category, type = 'all' } = ctx.params; - const link = encodeURI(`https://zh.wikihow.com/Category:${category}`); - const res = await got(link); - const $ = cheerio.load(res.data); - - const itemsSelector = type === 'all' ? '#cat_featured .thumbnail' : '#cat_all .thumbnail'; - const item = $(itemsSelector) - .map((_, ele) => { - const $item = cheerio.load(ele); - const title = '如何' + $item('.text span').text(); - const link = $item('a').attr('href'); - const thumbnail = $item('img').attr('data-src'); - return { - title, - description: ` - ${title}
- - `, - link, - }; - }) - .get(); - - ctx.state.data = { - title: `wikiHow - ${category}`, - description: `wikiHow - ${category}`, - link, - item, - }; -}; diff --git a/lib/routes/wikihow/index.js b/lib/routes/wikihow/index.js deleted file mode 100644 index 4af318427d0f94..00000000000000 --- a/lib/routes/wikihow/index.js +++ /dev/null @@ -1,32 +0,0 @@ -const got = require('@/utils/got'); -const cheerio = require('cheerio'); - -module.exports = async (ctx) => { - const link = `https://zh.wikihow.com/${encodeURIComponent('首页')}`; - const res = await got(link); - const $ = cheerio.load(res.data); - - const item = $('#fa_container td.image_map') - .map((_, ele) => { - const $item = cheerio.load(ele); - const title = '如何' + $item('.text span').text(); - const link = $item('.thumbnail > a').attr('href'); - const thumbnail = $item('.thumbnail img').attr('data-src'); - return { - title, - description: ` - ${title}
- - `, - link, - }; - }) - .get(); - - ctx.state.data = { - title: 'wikiHow - 首页', - description: 'wikiHow - 首页', - link, - item, - }; -}; diff --git a/lib/routes/xinquji/internal.js b/lib/routes/xinquji/internal.js deleted file mode 100644 index 159a1fa21fdd98..00000000000000 --- a/lib/routes/xinquji/internal.js +++ /dev/null @@ -1,15 +0,0 @@ -const got = require('@/utils/got'); - -module.exports = async (ctx) => { - const response = await got.get('https://xinquji.com/frontend/post/groups?cursor=0&only_internal=1'); - - ctx.state.data = { - title: '新趣集今日国内最佳', - link: 'https://xinquji.com', - item: response.data.data.map((item) => ({ - title: item.name, - description: `${item.name} ${item.description}`, - link: 'https://xinquji.com/posts/' + item.id + '?utm_source=rsshub', - })), - }; -}; diff --git a/lib/routes/xinquji/today.js b/lib/routes/xinquji/today.js deleted file mode 100644 index 35bb0ffd7b1903..00000000000000 --- a/lib/routes/xinquji/today.js +++ /dev/null @@ -1,15 +0,0 @@ -const got = require('@/utils/got'); - -module.exports = async (ctx) => { - const response = await got.get('https://xinquji.com/frontend/post/groups?cursor=0'); - - ctx.state.data = { - title: '新趣集今日最佳', - link: 'https://xinquji.com', - item: response.data.data.map((item) => ({ - title: item.name, - description: `${item.name} ${item.description}`, - link: 'https://xinquji.com/posts/' + item.id + '?utm_source=rsshub', - })), - }; -}; diff --git a/lib/routes/zhilian/index.js b/lib/routes/zhilian/index.js deleted file mode 100644 index af3583951fb3da..00000000000000 --- a/lib/routes/zhilian/index.js +++ /dev/null @@ -1,78 +0,0 @@ -const got = require('@/utils/got'); -const cheerio = require('cheerio'); - -module.exports = async (ctx) => { - const city = ctx.params.city; - const keyword = ctx.params.keyword; - const city_api_url = `https://fe-api.zhaopin.com/c/i/city-page/user-city?ipCity=${encodeURI(city)}`; - - const city_response = await got({ - method: 'get', - url: city_api_url, - }); - const city_response_data = city_response.data.data; - if (city_response_data.name) { - const job_api_url = `https://fe-api.zhaopin.com/c/i/sou?pageSize=20&cityId=${city_response_data.code}&workExperience=-1&education=5&companyType=-1&employmentType=-1&jobWelfareTag=-1&kw=${encodeURI(keyword)}&kt=3`; - const job_response = await got({ - method: 'get', - url: job_api_url, - }); - - // ## 获取列表 - const list = job_response.data.data.results; - // ## 定义输出的item - const out = await Promise.all( - // ### 遍历列表,筛选出自己想要的内容 - list.map(async (item) => { - const jobName = item.jobName; - const companyName = item.company.name; - const companyType = item.company.type.name; - const companySize = item.company.size.name; - const companyUrl = item.company.url; - const companyLogo = item.companyLogo; // logo - const salary = item.salary; - const jobType = item.jobType.items[0].name; - const positionURL = item.positionURL; // 原网页链接 - const updateDate = item.updateDate; // 更新时间 - - // 获取详情页面的介绍 - const detail_response = await got({ - method: 'get', - url: positionURL, - }); - const $ = cheerio.load(detail_response.data); - const detail_content = $('.describtion').html(); - // # 拼接相关信息 - // ## 拼接标题 - const title = `${jobName}[${salary}]-${jobType}`; - // ## 公司信息 - const companyDes = `

${companyName}

${companyType}[${companySize}]

点击查看公司详情
`; - const cache_information = positionURL + updateDate; // 确保唯一性 - const cache = await ctx.cache.get(cache_information); // ### 得到全局中的缓存信息 - // ### 判断缓存是否存在,如果存在即跳过此次获取的信息 - if (cache) { - return Promise.resolve(JSON.parse(cache)); - } - // ### 设置 RSS feed item - const single = { - title, - link: positionURL, - // author, - description: `如需申请此工作,建议打开原网页进行操作。

${companyDes}

${detail_content !== null ? detail_content : ''}`, - pubDate: updateDate, - }; - // // ### 设置缓存 - ctx.cache.set(cache_information, JSON.stringify(single)); - return Promise.resolve(single); - // } - }) - ); - - ctx.state.data = { - title: `${city}-${keyword} 相关工作 - 智联招聘`, - link: `https://sou.zhaopin.com/?jl=${city_response_data.code}&sf=0&st=0&el=5&kw=${encodeURI(keyword)}&kt=3`, - description: `${city} 的 ${keyword} 相关工作 - 智联招聘`, - item: out, - }; - } -}; diff --git a/lib/routes/ziroom/room.js b/lib/routes/ziroom/room.js deleted file mode 100644 index 6a71d290c1acd3..00000000000000 --- a/lib/routes/ziroom/room.js +++ /dev/null @@ -1,55 +0,0 @@ -const got = require('@/utils/got'); -const { isValidHost } = require('@/utils/valid-host'); - -module.exports = async (ctx) => { - const city = ctx.params.city || 'sh'; - const keyword = ctx.params.keyword || ''; - const iswhole = ctx.params.iswhole || '0'; - const room = ctx.params.room || '1'; - const domain = `${city === 'bj' ? '' : city + '.'}m.ziroom.com`; - - if (!isValidHost(city)) { - throw Error('Invalid city'); - } - - const response = await got({ - method: 'post', - url: `http://${domain}/list/ajax-get-data`, - headers: { - Referer: `http://${domain}/${city.toUpperCase()}/search.html`, - }, - form: { - recent_money: 0, - sort: 0, - is_whole: iswhole, - room, - key_word: keyword, - step: 0, - }, - }); - let data = response.data.data; // 当查询的结果不存在时,该 data 是个对象 { info: '数据加载完毕' } - // 判断数据的类型,如果有数据就是数组类型的,没有数据的话,就赋值为空数组 - data = - data instanceof Array - ? data - : [ - { - title: '我们找不到任何与您的搜索条件匹配的结果,但是调整您的搜索条件可能会有所帮助', - room_name: '', - list_img: '', - city: '', - id: '', - }, - ]; - - ctx.state.data = { - title: `自如的${keyword}${iswhole !== '0' ? '整租' : '合租'}${room}室房源`, - link: `http://${domain}`, - description: `自如的${keyword}${iswhole !== '0' ? '整租' : '合租'}${room}室房源`, - item: data.map((item) => ({ - title: item.title, - description: `${item.room_name}`, - link: `http://${domain}/${city.toUpperCase()}/room/${item.id}.html`, - })), - }; -}; diff --git a/lib/v2/csc/maintainer.js b/lib/v2/csc/maintainer.js deleted file mode 100644 index 0c01dcfcd81085..00000000000000 --- a/lib/v2/csc/maintainer.js +++ /dev/null @@ -1,3 +0,0 @@ -module.exports = { - '/notice/:type?': ['Derekmini'], -}; diff --git a/lib/v2/csc/notice.js b/lib/v2/csc/notice.js deleted file mode 100644 index 881fcbcf64d66c..00000000000000 --- a/lib/v2/csc/notice.js +++ /dev/null @@ -1,99 +0,0 @@ -const got = require('@/utils/got'); -const cheerio = require('cheerio'); -const url = require('url'); -const iconv = require('iconv-lite'); - -const baseUrl = 'https://www.csc.edu.cn'; - -const typeMap = { - lxtz: { - name: '遴选通知', - url: '/chuguo/list/24', - }, - xmzl: { - name: '综合项目专栏', - url: '/chuguo/list/26', - }, - wtjd: { - name: '常见问题解答', - url: '/chuguo/list/27', - }, - lqgg: { - name: '录取公告', - url: '/chuguo/list/28', - }, - xwzx: { - name: '新闻资讯', - url: '/news', - }, - xwgg: { - name: '新闻公告', - url: '/news/gonggao', - }, -}; - -module.exports = async (ctx) => { - const type = ctx.params.type || 'jjyw'; - const link = baseUrl + typeMap[type].url; - const response = await got({ - method: 'get', - url: link, - headers: { - Referer: baseUrl, - }, - responseType: 'buffer', - }); - const responseHtml = iconv.decode(response.data, 'gbk'); - const $ = cheerio.load(responseHtml); - - const urlList = $('.list-a li') - .slice(0, 10) - .map((i, e) => $('a', e).attr('href')) - .get(); - - const titleList = $('.list-a li') - .slice(0, 10) - .map((i, e) => $('a', e).attr('title')) - .get(); - - const dateList = $('.list-a li') - .slice(0, 10) - .map((i, e) => $('span', e).text()) - .get(); - - const out = await Promise.all( - urlList.map(async (itemUrl, index) => { - itemUrl = url.resolve(baseUrl, itemUrl); - - const cache = await ctx.cache.get(itemUrl); - if (cache) { - return Promise.resolve(JSON.parse(cache)); - } - const response = await got({ - method: 'get', - url: itemUrl, - responseType: 'buffer', - }); - const responseHtmlItem = iconv.decode(response.data, 'gbk'); - const $ = cheerio.load(responseHtmlItem); - const single = { - title: titleList[index], - link: itemUrl, - description: $('.contents') - .html() - .replace(/src="\//g, `src="${url.resolve(baseUrl, '.')}`) - .replace(/href="\//g, `href="${url.resolve(baseUrl, '.')}`) - .trim(), - pubDate: dateList[index], - }; - ctx.cache.set(itemUrl, JSON.stringify(single)); - return Promise.resolve(single); - }) - ); - - ctx.state.data = { - title: '国家留学网-' + typeMap[type].name, - link, - item: out, - }; -}; diff --git a/lib/v2/csc/radar.js b/lib/v2/csc/radar.js deleted file mode 100644 index 3f991674dbc01e..00000000000000 --- a/lib/v2/csc/radar.js +++ /dev/null @@ -1,31 +0,0 @@ -module.exports = { - 'csc.edu.cn': { - _name: '国家留学网', - www: [ - { - title: '遴选通知', - docs: 'https://docs.rsshub.app/routes/other#guo-jia-liu-xue-wang', - source: '/*', - target: '/csc/notice/lxtz', - }, - { - title: '综合项目专栏', - docs: 'https://docs.rsshub.app/routes/other#guo-jia-liu-xue-wang', - source: '/*', - target: '/csc/notice/xmzl', - }, - { - title: '常见问题解答', - docs: 'https://docs.rsshub.app/routes/other#guo-jia-liu-xue-wang', - source: '/*', - target: '/csc/notice/wtjd', - }, - { - title: '录取公告', - docs: 'https://docs.rsshub.app/routes/other#guo-jia-liu-xue-wang', - source: '/*', - target: '/csc/notice/lqgg', - }, - ], - }, -}; diff --git a/lib/v2/csc/router.js b/lib/v2/csc/router.js deleted file mode 100644 index f493eb3cf8c8fc..00000000000000 --- a/lib/v2/csc/router.js +++ /dev/null @@ -1,3 +0,0 @@ -module.exports = function (router) { - router.get('/notice/:type?', require('./notice')); -}; diff --git a/lib/v2/ems/apple.js b/lib/v2/ems/apple.js deleted file mode 100644 index 2eec3ef2501cd5..00000000000000 --- a/lib/v2/ems/apple.js +++ /dev/null @@ -1,42 +0,0 @@ -const got = require('@/utils/got'); -const { art } = require('@/utils/render'); -const path = require('path'); - -const rootUrl = 'https://www.ems.com.cn'; - -module.exports = async (ctx) => { - const id = ctx.params.id; - const link = `${rootUrl}/apple/query/${id}`; - const APIUrl = `${rootUrl}/apple/getMailNoLastRoutes`; - - const { trails } = await got - .post(APIUrl, { - form: { - mailNum: id, - }, - }) - .json(); - - let item; - try { - item = [ - { - title: `${trails[0][0].despatchCity} → ${trails[0][0].destinationCity}`, - link, - description: art(path.join(__dirname, 'templates/apple.art'), { - trails: trails[0], - }), - guid: trails[0][0], - }, - ]; - } catch (e) { - throw new Error(`没有找到 ${id} 的信息,请检查是否输入正确或者稍后再试。`); - } - - ctx.state.data = { - allowEmpty: true, - title: `Apple EMS 快递 ${id}`, - link, - item, - }; -}; diff --git a/lib/v2/ems/maintainer.js b/lib/v2/ems/maintainer.js deleted file mode 100644 index 2070e9f59e829c..00000000000000 --- a/lib/v2/ems/maintainer.js +++ /dev/null @@ -1,4 +0,0 @@ -module.exports = { - '/news': ['luyuhuang'], - '/apple/:id': ['Fatpandac'], -}; diff --git a/lib/v2/ems/news.js b/lib/v2/ems/news.js deleted file mode 100644 index 7a930c9eab8507..00000000000000 --- a/lib/v2/ems/news.js +++ /dev/null @@ -1,21 +0,0 @@ -const got = require('@/utils/got'); - -module.exports = async (ctx) => { - const response = await got({ - method: 'get', - url: 'http://www.ems.com.cn/ems/news/listNews', - }); - - const items = response.data.map((item) => ({ - title: item.title, - link: `http://www.ems.com.cn/ems/news/viewNews?id=${item.id}`, - pubDate: item.postDate, - description: item.content, - })); - - ctx.state.data = { - title: '中国邮政速递物流', - link: 'http://www.ems.com.cn/', - item: items, - }; -}; diff --git a/lib/v2/ems/radar.js b/lib/v2/ems/radar.js deleted file mode 100644 index 8c68f004971d98..00000000000000 --- a/lib/v2/ems/radar.js +++ /dev/null @@ -1,19 +0,0 @@ -module.exports = { - 'ems.com.cn': { - _name: '中国邮政速递物流', - www: [ - { - title: '新闻', - docs: 'https://docs.rsshub.app/routes/other#zhong-guo-you-zheng-su-di-wu-liu', - source: '/aboutus/xin_wen_yu_shi_jian.html', - target: '/ems/news', - }, - { - title: '苹果邮件', - docs: 'https://docs.rsshub.app/routes/other#zhong-guo-you-zheng-su-di-wu-liu', - source: ['/apple/query/:id'], - target: '/apple/ems/:id', - }, - ], - }, -}; diff --git a/lib/v2/ems/router.js b/lib/v2/ems/router.js deleted file mode 100644 index 21fd46f7a528eb..00000000000000 --- a/lib/v2/ems/router.js +++ /dev/null @@ -1,4 +0,0 @@ -module.exports = function (router) { - router.get('/news', require('./news')); - router.get('/apple/:id', require('./apple')); -}; diff --git a/lib/v2/ems/templates/apple.art b/lib/v2/ems/templates/apple.art deleted file mode 100644 index 2659fe22c6005d..00000000000000 --- a/lib/v2/ems/templates/apple.art +++ /dev/null @@ -1,6 +0,0 @@ -{{ each trails}} -

{{ $value.optime }}

-

{{ $value.opreateType}}

-

{{ $value.processingInstructions }}

-
-{{/each}} diff --git a/lib/v2/lever/index.js b/lib/v2/lever/index.js deleted file mode 100644 index a8672a4ca5008d..00000000000000 --- a/lib/v2/lever/index.js +++ /dev/null @@ -1,28 +0,0 @@ -const got = require('@/utils/got'); -const { parseDate } = require('@/utils/parse-date'); - -// Initiate a HTTP GET request -module.exports = async (ctx) => { - const domain = ctx.params.domain; - const response = await got(`https://api.lever.co/v0/postings/${domain}?mode=json`); - const data = response.data; - ctx.state.data = { - // the source title - title: `${domain}'s Job feed in RSS`, - // the source link - link: `https://api.lever.co/v0/postings/${domain}`, - // the source description - description: `Auto Generated RSS Spec for ${domain}`, - // iterate through all leaf objects - item: data.map((item) => ({ - // the article title - title: item.text, - // the article content - description: item.descriptionPlain, - // the article publish time - pubDate: parseDate(item.createdAt), - // the article link - link: item.hostedUrl, - })), - }; -}; diff --git a/lib/v2/lever/maintainer.js b/lib/v2/lever/maintainer.js deleted file mode 100644 index 550490aac09ddb..00000000000000 --- a/lib/v2/lever/maintainer.js +++ /dev/null @@ -1,3 +0,0 @@ -module.exports = { - '/:domain': ['tsarlewey'], -}; diff --git a/lib/v2/lever/radar.js b/lib/v2/lever/radar.js deleted file mode 100644 index acd81ffccc068e..00000000000000 --- a/lib/v2/lever/radar.js +++ /dev/null @@ -1,13 +0,0 @@ -module.exports = { - 'lever.co': { - _name: 'Lever', - '.': [ - { - title: 'Lever HRIS Job Boards Feed', - docs: 'https://docs.rsshub.app/routes/other#lever', - source: ['/:domain'], - target: '/lever/:domain', - }, - ], - }, -}; diff --git a/lib/v2/lever/router.js b/lib/v2/lever/router.js deleted file mode 100644 index 6d4b80086d5113..00000000000000 --- a/lib/v2/lever/router.js +++ /dev/null @@ -1,3 +0,0 @@ -module.exports = function (router) { - router.get('/:domain', require('./index.js')); -}; diff --git a/website/docs/routes/other.mdx b/website/docs/routes/other.mdx index 25b588764febda..ebce0337e76a32 100644 --- a/website/docs/routes/other.mdx +++ b/website/docs/routes/other.mdx @@ -91,12 +91,6 @@ See [#app-store-mac-app-store](/routes/program-update#app-store-mac-app-store) 2. Copy everything in the URL after `?`, for example: `https://www.autotrader.co.uk/car-search?radius=50&postcode=sw1a1aa&onesearchad=Used&onesearchad=Nearly%20New&onesearchad=New&price-to=9000&year-from=2012&body-type=Hatchback&transmission=Automatic&exclude-writeoff-categories=on` will produce `radius=50&postcode=sw1a1aa&onesearchad=Used&onesearchad=Nearly%20New&onesearchad=New&price-to=9000&year-from=2012&body-type=Hatchback&transmission=Automatic&exclude-writeoff-categories=on` -## BOOKSOURCE.STORE {#booksource-store} - -### 书源仓库更新 {#booksource-store-shu-yuan-cang-ku-geng-xin} - - - ## BOOKWALKERTW {#bookwalkertw} ### 热门新书 {#bookwalkertw-re-men-xin-shu} @@ -115,45 +109,11 @@ See [#app-store-mac-app-store](/routes/program-update#app-store-mac-app-store) -## Corona Virus Disease 2019 {#corona-virus-disease-2019} - -### 国家卫健委 - 疫情通报 {#corona-virus-disease-2019-guo-jia-wei-jian-wei-yi-qing-tong-bao} - - - -### 财新网 - 新冠肺炎防疫全纪录 {#corona-virus-disease-2019-cai-xin-wang-xin-guan-fei-yan-fang-yi-quan-ji-lu} - - - -### 丁香园 - 新冠病毒疫情实时播报 {#corona-virus-disease-2019-ding-xiang-yuan-xin-guan-bing-du-yi-qing-shi-shi-bo-bao} - - - -### 丁香园 - 新冠病毒疫情数据统计 {#corona-virus-disease-2019-ding-xiang-yuan-xin-guan-bing-du-yi-qing-shu-ju-tong-ji} - - - -### 腾讯新闻 - 新型冠状病毒肺炎实时辟谣 {#corona-virus-disease-2019-teng-xun-xin-wen-xin-xing-guan-zhuang-bing-du-fei-yan-shi-shi-pi-yao} - - - -### 腾讯新闻 - 新型冠状病毒肺炎疫情实时追踪 {#corona-virus-disease-2019-teng-xun-xin-wen-xin-xing-guan-zhuang-bing-du-fei-yan-yi-qing-shi-shi-zhui-zong} - -数据来源:[https://news.qq.com/zt2020/page/feiyan.htm#/](https://news.qq.com/zt2020/page/feiyan.htm#/) - -#### 中国本土数据统计 {#corona-virus-disease-2019-teng-xun-xin-wen-xin-xing-guan-zhuang-bing-du-fei-yan-yi-qing-shi-shi-zhui-zong-zhong-guo-ben-tu-shu-ju-tong-ji} - - - -#### 省市疫情数据 {#corona-virus-disease-2019-teng-xun-xin-wen-xin-xing-guan-zhuang-bing-du-fei-yan-yi-qing-shi-shi-zhui-zong-sheng-shi-yi-qing-shu-ju} - - - -### South China Morning Post - China coronavirus outbreak {#corona-virus-disease-2019-south-china-morning-post-china-coronavirus-outbreak} +### South China Morning Post - China coronavirus outbreak {#clickme-south-china-morning-post-china-coronavirus-outbreak} -### Macao Pagina Electrónica Especial Contra Epidemias: What’s New {#corona-virus-disease-2019-macao-pagina-electronica-especial-contra-epidemias-what-s-new} +### Macao Pagina Electrónica Especial Contra Epidemias: What’s New {#clickme-macao-pagina-electronica-especial-contra-epidemias-what-s-new} Official Website: [https://www.ssm.gov.mo/apps1/PreventWuhanInfection/en.aspx](https://www.ssm.gov.mo/apps1/PreventWuhanInfection/en.aspx) @@ -163,11 +123,11 @@ Official Website: [https://www.ssm.gov.mo/apps1/PreventWuhanInfection/en.aspx](h | ------- | ------- | ---------- | | ch | en | pt | -### Singapore Ministry of Health - Past Updates on 2019-nCov Local Situation in Singapore {#corona-virus-disease-2019-singapore-ministry-of-health-past-updates-on-2019-ncov-local-situation-in-singapore} +### Singapore Ministry of Health - Past Updates on 2019-nCov Local Situation in Singapore {#clickme-singapore-ministry-of-health-past-updates-on-2019-ncov-local-situation-in-singapore} -### Yahoo Japan 新型コロナウイルス感染症まとめ {#corona-virus-disease-2019-yahoo-japan-xin-xing-%E3%82%B3%E3%83%AD%E3%83%8A%E3%82%A6%E3%82%A4%E3%83%AB%E3%82%B9-gan-ran-zheng-%E3%81%BE%E3%81%A8%E3%82%81} +### Yahoo Japan 新型コロナウイルス感染症まとめ {#clickme-yahoo-japan-xin-xing-%E3%82%B3%E3%83%AD%E3%83%8A%E3%82%A6%E3%82%A4%E3%83%AB%E3%82%B9-gan-ran-zheng-%E3%81%BE%E3%81%A8%E3%82%81} Official Website: [https://news.yahoo.co.jp/pages/article/20200207](https://news.yahoo.co.jp/pages/article/20200207) @@ -185,12 +145,6 @@ Official Website: [https://news.yahoo.co.jp/pages/article/20200207](https://news -## DHL {#dhl} - -### DHL express {#dhl-dhl-express} - - - ## Email {#email} ### Email list {#email-email-list} @@ -247,12 +201,6 @@ Official Website: [https://news.yahoo.co.jp/pages/article/20200207](https://news -## Instapaper {#instapaper} - -### Personal sharing {#instapaper-personal-sharing} - - - ## Instructables {#instructables} ### Projects {#instructables-projects} @@ -263,18 +211,6 @@ Official Website: [https://news.yahoo.co.jp/pages/article/20200207](https://news | | circuits | workshop | craft | cooking | living | outside | teachers | -## iYouport {#iyouport} - -### 首页(旧版) {#iyouport-shou-ye-jiu-ban} - - - -### 分类 {#iyouport-fen-lei} - -支持 iyouport.org 页面 Header 全部分类。例如,`https://www.iyouport.org/category/osint` 对应 `/iyouport/osint`。若不填写 `category`,则输出全部文章,但比旧版首页 feed 有更多元数据。 - - - ## Japanpost 日本郵便 {#japanpost-ri-ben-you-bian} ### Track & Trace Service 郵便追跡サービス {#japanpost-ri-ben-you-bian-track-trace-service-you-bian-zhui-ji-%E3%82%B5%E3%83%BC%E3%83%93%E3%82%B9} @@ -285,16 +221,6 @@ Official Website: [https://news.yahoo.co.jp/pages/article/20200207](https://news | ja | en | -## King Arthur {#king-arthur} - -### Baking {#king-arthur-baking} - - - | Story | Recipes | Tips and Techniques | - | ----- | ------- | ------------------- | - | story | recipes | tips-and-techniques | - - ## Layoffs.fyi {#layoffs-fyi} ### Layoff Data Tracker {#layoffs-fyi-layoff-data-tracker} @@ -303,12 +229,6 @@ Official Website: [https://news.yahoo.co.jp/pages/article/20200207](https://news RSS source in the original site is outdated. -## Lever {#lever} - -### Recruitment {#lever-recruitment} - - - ## LinkedIn {#linkedin} ### Jobs {#linkedin-jobs} @@ -396,18 +316,6 @@ RSS source in the original site is outdated. 一例:如果用户希望输出全部订阅源中,最旧的两篇未读的文章,并希望在文章的标题栏显示订阅源的名字,同时希望输出内容在 MiniFlux 中被标为已读,那么路由设置应为:`/miniflux/all/direction=asc&status=unread&feed_name=1&mark=read&limit=2` -## MITRE {#mitre} - -### All Publications {#mitre-all-publications} - - - -## MobData {#mobdata} - -### 分析报告 {#mobdata-fen-xi-bao-gao} - - - ## Mozilla {#mozilla} ### Firefox Monitor {#mozilla-firefox-monitor} @@ -496,12 +404,6 @@ It is recommended to use with clipping tools such as Notion Web Clipper. -## Pocket {#pocket} - -### Trending {#pocket-trending} - - - ## Product Hunt {#product-hunt} > 官方 Feed 地址为: [https://www.producthunt.com/feed](https://www.producthunt.com/feed) @@ -520,12 +422,6 @@ It is recommended to use with clipping tools such as Notion Web Clipper. | all | development | design | operation | product | other | marketing | sales | -## SANS Institute {#sans-institute} - -### Latest conference materials {#sans-institute-latest-conference-materials} - - - ## Transformation {#transformation} Pass URL and transformation rules to convert HTML/JSON into RSS. @@ -614,14 +510,6 @@ Specify options (in the format of query string) in parameter `routeParams` param | `routeParams` | `title=Example` | -## TSSstatus (iOS downgrade channel) {#tssstatus-ios-downgrade-channel} - -### Status {#tssstatus-ios-downgrade-channel-status} - - - Board and Build can be found in [here](http://api.ineal.me/tss/status) - - ## Urban Dictionary {#urban-dictionary} ### Random words {#urban-dictionary-random-words} @@ -660,24 +548,6 @@ Specify options (in the format of query string) in parameter `routeParams` param -## wikiHow {#wikihow} - -### Home {#wikihow-home} - - - -### Category {#wikihow-category} - - - Top category can be found in [category Page](https://zh.wikihow.com/Special\:CategoryListing), support secondary directories - - Type - - | All | Recommend | - | --- | --------- | - | all | rec | - - ## Wise {#wise} ### FX Pair Yesterday {#wise-fx-pair-yesterday} @@ -727,16 +597,6 @@ Specify options (in the format of query string) in parameter `routeParams` param -## 澳門特別行政區政府各公共部門獎助貸學金服務平台 {#ao-men-te-bie-xing-zheng-qu-zheng-fu-ge-gong-gong-bu-men-jiang-zhu-dai-xue-jin-fu-wu-ping-tai} - -官方網址:[https://www.bolsas.gov.mo/](https://www.bolsas.gov.mo/) - - - | 中文 | 葡文 | - | ---- | ---- | - | ch | pt | - - ## 百度热搜 {#bai-du-re-sou} ### 榜单 {#bai-du-re-sou-bang-dan} @@ -775,12 +635,6 @@ Specify options (in the format of query string) in parameter `routeParams` param -## 福利资源 - met.red {#fu-li-zi-yuan-met-red} - -### 福利资源 - met.red {#fu-li-zi-yuan-met-red-fu-li-zi-yuan-met-red} - - - ## 古诗文网 {#gu-shi-wen-wang} ### 首页推荐 {#gu-shi-wen-wang-shou-ye-tui-jian} @@ -815,28 +669,6 @@ Specify options (in the format of query string) in parameter `routeParams` param | 会员动态 | 39 | -## 国家留学网 {#guo-jia-liu-xue-wang} - -### 通知 {#guo-jia-liu-xue-wang-tong-zhi} - - - | 遴选通知 | 综合项目专栏 | 常见问题解答 | 录取公告 | 新闻资讯 | 新闻公告 | - | -------- | ------------ | ------------ | -------- | -------- | -------- | - | lxtz | xmzl | wtjd | lqgg | xwzx | xwgg | - - -## 好队友 {#hao-dui-you} - -### 工作机会 {#hao-dui-you-gong-zuo-ji-hui} - - - -## 惠誉评级 {#hui-yu-ping-ji} - -### 板块信息 {#hui-yu-ping-ji-ban-kuai-xin-xi} - - - ## 静态模型爱好者 {#jing-tai-mo-xing-ai-hao-zhe} ### 新品信息 {#jing-tai-mo-xing-ai-hao-zhe-xin-pin-xin-xi} @@ -949,12 +781,6 @@ Specify options (in the format of query string) in parameter `routeParams` param -## 马良行 {#ma-liang-xing} - -### 产品更新 {#ma-liang-xing-chan-pin-geng-xin} - - - ## 每日生猪价格 {#mei-ri-sheng-zhu-jia-ge} ### 每日生猪价格更新 {#mei-ri-sheng-zhu-jia-ge-mei-ri-sheng-zhu-jia-ge-geng-xin} @@ -979,12 +805,6 @@ Specify options (in the format of query string) in parameter `routeParams` param | 0 | 1 | recommends | -## 模型网 {#mo-xing-wang} - -### 新闻 {#mo-xing-wang-xin-wen} - - - ## 汽油价格网 {#qi-you-jia-ge-wang} ### 今日油价查询 {#qi-you-jia-ge-wang-jin-ri-you-jia-cha-xun} @@ -997,24 +817,6 @@ Specify options (in the format of query string) in parameter `routeParams` param ::: -## 且听风吟福利 {#qie-ting-feng-yin-fu-li} - -### 分类 {#qie-ting-feng-yin-fu-li-fen-lei} - - - | 最新文章 | 福利社 | 求出处 | 套图集 | 门事件 | 内涵图 | 电影下载 | 影视资讯 | - | -------- | ------- | --------- | ------- | ---------- | -------- | -------------- | -------- | - | latest | fulishe | qiuchuchu | taotuji | menshijian | neihantu | dianyingxiazai | yingshi | - - | 电视剧下载 | 动漫下载 | 电影彩蛋 | 影视剧情 | 涨姿势 | 娱乐 | 明星八卦 | 音乐歌曲 | - | ---------- | -------- | -------- | -------- | ---------- | ---- | -------- | -------- | - | dianshiju | dongman | caidan | juqing | zhangzishi | yule | mingxing | music | - - | 游戏 | 电脑软件 | 实时热点 | 心灵鸡汤 | 符号大全 | 国际新闻 | 科技苑 | 其他 | - | ----- | -------- | ------------ | -------- | -------- | -------- | ------ | ----- | - | games | software | shishiredian | xljt | fhdq | xljt | tech | other | - - ## 親子王國 {#qin-zi-wang-guo} ### 板块 {#qin-zi-wang-guo-ban-kuai} @@ -1047,22 +849,6 @@ Specify options (in the format of query string) in parameter `routeParams` param -## 守望先锋 {#shou-wang-xian-feng} - -### 补丁说明 {#shou-wang-xian-feng-bu-ding-shuo-ming} - - - -## 四川省科学技术厅 {#si-chuan-sheng-ke-xue-ji-shu-ting} - -### 四川省科学技术厅 - 公示公告 {#si-chuan-sheng-ke-xue-ji-shu-ting-si-chuan-sheng-ke-xue-ji-shu-ting-gong-shi-gong-gao} - - - | 通知 | 公示公告 | - | ---- | -------- | - | tz | gs | - - ## 搜狗 {#sou-gou} ### 搜狗特色 LOGO {#sou-gou-sou-gou-te-se-logo} @@ -1125,61 +911,12 @@ Specify options (in the format of query string) in parameter `routeParams` param -## 新趣集 {#xin-qu-ji} - -> 官方 Feed 地址为: [https://xinquji.com/rss](https://xinquji.com/rss) - -### 今日最佳 {#xin-qu-ji-jin-ri-zui-jia} - - - -### 今日国内 {#xin-qu-ji-jin-ri-guo-nei} - - - ## 有据 {#you-ju} ### 最新文章列表 {#you-ju-zui-xin-wen-zhang-lie-biao} -## 源仓库 {#yuan-cang-ku} - -### 源仓库更新 {#yuan-cang-ku-yuan-cang-ku-geng-xin} - - - | 阅读 | 异次元 | 海阔 | - | ----- | -------- | ------ | - | yuedu | yiciyuan | haikuo | - - -## 智联招聘 {#zhi-lian-zhao-pin} - -### 搜索 {#zhi-lian-zhao-pin-sou-suo} - - - -## 中国工程科技知识中心 {#zhong-guo-gong-cheng-ke-ji-zhi-shi-zhong-xin} - -### 知识应用 {#zhong-guo-gong-cheng-ke-ji-zhi-shi-zhong-xin-zhi-shi-ying-yong} - - - 所属类别 - - | 专题知识服务 | 知识分析 | 知识工具 | 综合性知识服务 | 全部类别 | - | ------------ | -------- | -------- | -------------- | -------- | - | 2 | 3 | 4 | 1 | 0 | - - 领域 - - | 综合 | 农业 | 航天 | 地质 | 信息技术 | 林业 | 医药卫生 | 战略性新兴产业 | 能源 | 冶金 | 化工 | 地理信息 | 营养健康 | 工程科教图书 | 交通 | 创新设计 | 地理资源与生态 | 材料 | 气象 | 渔业 | 环境工程 | 试验技术 | 中草药 | 水利 | 海洋工程 | - | ---- | ---- | ---- | ---- | -------- | ---- | -------- | -------------- | ---- | ---- | ---- | -------- | -------- | ------------ | ---- | -------- | -------------- | ---- | ---- | ---- | -------- | -------- | ------ | ---- | -------- | - - -### 产业政策 {#zhong-guo-gong-cheng-ke-ji-zhi-shi-zhong-xin-chan-ye-zheng-ce} - - - ## 中国工商银行 {#zhong-guo-gong-shang-yin-hang} ### 外汇牌价 {#zhong-guo-gong-shang-yin-hang-wai-hui-pai-jia} @@ -1310,28 +1047,6 @@ Specify options (in the format of query string) in parameter `routeParams` param | short | zs | xh | xc | xhmr | xhmc | xcmr | xcmc | -## 中国邮政速递物流 {#zhong-guo-you-zheng-su-di-wu-liu} - -### 新闻 {#zhong-guo-you-zheng-su-di-wu-liu-xin-wen} - - - -### 苹果邮件 {#zhong-guo-you-zheng-su-di-wu-liu-ping-guo-you-jian} - - - -## 自如 {#zi-ru} - -### 房源 {#zi-ru-fang-yuan} - - - -## 佐川急便 {#zuo-chuan-ji-bian} - -### 查询快递 {#zuo-chuan-ji-bian-cha-xun-kuai-di} - - - ## はてな {#%E3%81%AF%E3%81%A6%E3%81%AA} ### はてな匿名ダイアリー - 人気記事アーカイブ {#%E3%81%AF%E3%81%A6%E3%81%AA-%E3%81%AF%E3%81%A6%E3%81%AA-ni-ming-%E3%83%80%E3%82%A4%E3%82%A2%E3%83%AA%E3%83%BC-ren-qi-ji-shi-%E3%82%A2%E3%83%BC%E3%82%AB%E3%82%A4%E3%83%96}