mirror of
https://github.com/DIYgod/RSSHub.git
synced 2026-08-29 01:53:47 +08:00
feat: remove notOperational routes - blog
This commit is contained in:
@@ -344,7 +344,6 @@
|
||||
},
|
||||
],
|
||||
},
|
||||
'jian-ning.com': { _name: '建宁闲谈', '.': [{ title: '文章', docs: 'https://docs.rsshub.app/routes/blog#jian-ning-xian-tan', source: '/*', target: '/blogs/jianning' }] },
|
||||
'eventernote.com': { _name: 'Eventernote', www: [{ title: '声优活动及演唱会', docs: 'https://docs.rsshub.app/routes/anime#eventernote', source: '/actors/:name/:id/events', target: '/eventernote/actors/:name/:id' }] },
|
||||
'huya.com': { _name: '虎牙直播', '.': [{ title: '直播间开播', docs: 'https://docs.rsshub.app/routes/live#hu-ya-zhi-bo-zhi-bo-jian-kai-bo', source: '/:id', target: '/huya/live/:id' }] },
|
||||
'craigslist.org': { _name: 'Craigslist', '.': [{ title: '商品搜索列表', docs: 'https://docs.rsshub.app/routes/shopping#craigslist' }] },
|
||||
|
||||
@@ -902,17 +902,6 @@ module.exports = {
|
||||
},
|
||||
],
|
||||
},
|
||||
'jian-ning.com': {
|
||||
_name: '建宁闲谈',
|
||||
'.': [
|
||||
{
|
||||
title: '文章',
|
||||
docs: 'https://docs.rsshub.app/routes/blog#jian-ning-xian-tan',
|
||||
source: '/*',
|
||||
target: '/blogs/jianning',
|
||||
},
|
||||
],
|
||||
},
|
||||
'huya.com': {
|
||||
_name: '虎牙直播',
|
||||
'.': [
|
||||
|
||||
@@ -1272,9 +1272,6 @@ router.get('/centbrowser/history', lazyloadRouteHandler('./routes/centbrowser/hi
|
||||
// 755
|
||||
router.get('/755/user/:username', lazyloadRouteHandler('./routes/755/user'));
|
||||
|
||||
// Kernel Aliyun
|
||||
router.get('/aliyun-kernel/index', lazyloadRouteHandler('./routes/aliyun-kernel/index'));
|
||||
|
||||
// Vulture
|
||||
router.get('/vulture/:tag/:excludetags?', lazyloadRouteHandler('./routes/vulture/index'));
|
||||
|
||||
@@ -1477,10 +1474,6 @@ router.get('/sckjt/news/:type?', lazyloadRouteHandler('./routes/sckjt/news'));
|
||||
// 绝对领域
|
||||
router.get('/jdlingyu/:type', lazyloadRouteHandler('./routes/jdlingyu/index'));
|
||||
|
||||
// Hi, DIYgod
|
||||
router.get('/blogs/diygod/animal-crossing', lazyloadRouteHandler('./routes/blogs/diygod/animal-crossing'));
|
||||
router.get('/blogs/diygod/gk', lazyloadRouteHandler('./routes/blogs/diygod/gk'));
|
||||
|
||||
// 湖北工业大学
|
||||
router.get('/hbut/news/:type', lazyloadRouteHandler('./routes/universities/hbut/news'));
|
||||
router.get('/hbut/cs/:type', lazyloadRouteHandler('./routes/universities/hbut/cs'));
|
||||
@@ -1777,9 +1770,6 @@ router.get('/tencent/bigdata', lazyloadRouteHandler('./routes/tencent/bigdata/in
|
||||
// 搜韵网
|
||||
router.get('/souyun/today', lazyloadRouteHandler('./routes/souyun/today'));
|
||||
|
||||
// JustRun
|
||||
router.get('/justrun', lazyloadRouteHandler('./routes/justrun/index'));
|
||||
|
||||
// 中山网新闻
|
||||
router.get('/zsnews/index/:cateid', lazyloadRouteHandler('./routes/zsnews/index'));
|
||||
|
||||
@@ -1832,9 +1822,6 @@ router.get('/secshi', lazyloadRouteHandler('./routes/secshi/index'));
|
||||
// 出海笔记
|
||||
router.get('/chuhaibiji', lazyloadRouteHandler('./routes/chuhaibiji/index'));
|
||||
|
||||
// 建宁闲谈
|
||||
router.get('/blogs/jianning', lazyloadRouteHandler('./routes/blogs/jianning'));
|
||||
|
||||
// 互动吧
|
||||
router.get('/hudongba/:city/:id', lazyloadRouteHandler('./routes/hudongba/index'));
|
||||
|
||||
@@ -2277,9 +2264,6 @@ router.get('/hugo/releases', lazyloadRouteHandler('./routes/hugo/releases'));
|
||||
// 东立出版
|
||||
router.get('/tongli/news/:type', lazyloadRouteHandler('./routes/tongli/news'));
|
||||
|
||||
// 字型故事
|
||||
router.get('/fontstory', lazyloadRouteHandler('./routes/fontstory/tw'));
|
||||
|
||||
// 海南大学
|
||||
router.get('/hainanu/ssszs', lazyloadRouteHandler('./routes/hainanu/ssszs'));
|
||||
|
||||
|
||||
@@ -1,60 +0,0 @@
|
||||
const got = require('@/utils/got');
|
||||
const cheerio = require('cheerio');
|
||||
|
||||
module.exports = async (ctx) => {
|
||||
const baseUrl = 'https://kernel.taobao.org/';
|
||||
const response = await got({
|
||||
method: 'get',
|
||||
url: baseUrl,
|
||||
headers: {
|
||||
Referer: baseUrl,
|
||||
},
|
||||
});
|
||||
|
||||
const data = response.data;
|
||||
const $ = cheerio.load(data);
|
||||
const list = $('.container .post-item').get();
|
||||
const ProcessFeed = (data) => {
|
||||
const $ = cheerio.load(data);
|
||||
|
||||
// 提取内容
|
||||
return {
|
||||
desc: $('.container .post-content').html(),
|
||||
publish_time: $('.post-meta > time').attr('datetime'),
|
||||
};
|
||||
};
|
||||
const items = await Promise.all(
|
||||
list.map(async (item) => {
|
||||
const $ = cheerio.load(item);
|
||||
const $a = $('.article-title > a');
|
||||
const link = baseUrl + $a.attr('href');
|
||||
const cache = await ctx.cache.get(link);
|
||||
if (cache) {
|
||||
return Promise.resolve(JSON.parse(cache));
|
||||
}
|
||||
|
||||
const response = await got({
|
||||
method: 'get',
|
||||
url: link,
|
||||
});
|
||||
const feed = ProcessFeed(response.data);
|
||||
const description = feed.desc;
|
||||
const pubDate = feed.publish_time;
|
||||
|
||||
const single = {
|
||||
title: $a.text(),
|
||||
description,
|
||||
link,
|
||||
pubDate,
|
||||
};
|
||||
ctx.cache.set(link, JSON.stringify(single));
|
||||
return Promise.resolve(single);
|
||||
})
|
||||
);
|
||||
|
||||
ctx.state.data = {
|
||||
title: 'Kernel Aliyun',
|
||||
link: baseUrl,
|
||||
item: items,
|
||||
};
|
||||
};
|
||||
@@ -1,39 +0,0 @@
|
||||
const got = require('@/utils/got');
|
||||
const cheerio = require('cheerio');
|
||||
const { parseDate } = require('@/utils/parse-date');
|
||||
|
||||
module.exports = async (ctx) => {
|
||||
const response = await got({
|
||||
method: 'get',
|
||||
url: 'https://diygod.me/animal-crossing',
|
||||
});
|
||||
|
||||
const data = response.data;
|
||||
|
||||
const $ = cheerio.load(data);
|
||||
$('style').remove();
|
||||
const list = $('.post-body h2');
|
||||
|
||||
ctx.state.data = {
|
||||
title: 'DIYgod 的动森日记',
|
||||
link: 'https://diygod.me/animal-crossing',
|
||||
item:
|
||||
list &&
|
||||
list
|
||||
.map((index, item) => {
|
||||
item = $(item);
|
||||
let description = '';
|
||||
item.nextUntil('h2').each((index, item) => {
|
||||
description += $(item).html();
|
||||
});
|
||||
return {
|
||||
title: item.text(),
|
||||
description,
|
||||
link: `https://diygod.me/animal-crossing/#${item.attr('id')}`,
|
||||
pubDate: parseDate(item.text().split(' ')[1], 'M月D日'),
|
||||
guid: item.text().split(' ')[0],
|
||||
};
|
||||
})
|
||||
.get(),
|
||||
};
|
||||
};
|
||||
@@ -1,33 +0,0 @@
|
||||
const got = require('@/utils/got');
|
||||
const cheerio = require('cheerio');
|
||||
|
||||
module.exports = async (ctx) => {
|
||||
const response = await got({
|
||||
method: 'get',
|
||||
url: 'https://diygod.me/gk',
|
||||
});
|
||||
|
||||
const data = response.data;
|
||||
|
||||
const $ = cheerio.load(data);
|
||||
const list = $('.gk-item');
|
||||
|
||||
ctx.state.data = {
|
||||
title: 'DIYgod 的可爱的手办们',
|
||||
link: 'https://diygod.me/gk',
|
||||
item:
|
||||
list &&
|
||||
list
|
||||
.map((index, item) => {
|
||||
item = $(item);
|
||||
const title = item.find('.gk-desc p').eq(0).text().slice(3);
|
||||
return {
|
||||
title,
|
||||
description: item.html(),
|
||||
link: 'https://diygod.me/gk',
|
||||
guid: title,
|
||||
};
|
||||
})
|
||||
.get(),
|
||||
};
|
||||
};
|
||||
@@ -1,45 +0,0 @@
|
||||
const got = require('@/utils/got');
|
||||
const cheerio = require('cheerio');
|
||||
const iconv = require('iconv-lite');
|
||||
const url = require('url');
|
||||
|
||||
module.exports = async (ctx) => {
|
||||
const base_url = `http://jian-ning.com/all-articles.html`;
|
||||
const response = await got({
|
||||
method: 'get',
|
||||
url: base_url,
|
||||
responseType: 'buffer',
|
||||
});
|
||||
const data = iconv.decode(response.data, 'gbk');
|
||||
const $ = cheerio.load(data);
|
||||
const list = $('li');
|
||||
const out = list
|
||||
.map(async (i, item) => {
|
||||
const link = url.resolve('http://jian-ning.com', $(item).find('a').attr('href'));
|
||||
const description = await ctx.cache.tryGet(link, async () => {
|
||||
const result = await got({
|
||||
method: 'get',
|
||||
url: link,
|
||||
responseType: 'buffer',
|
||||
headers: {
|
||||
Referer: base_url,
|
||||
},
|
||||
});
|
||||
const content = cheerio.load(iconv.decode(result.data, 'gbk'));
|
||||
return content('td td').html();
|
||||
});
|
||||
const post = {
|
||||
title: $(item).find('a').text(),
|
||||
link,
|
||||
pubDate: $(item).find('span').text(),
|
||||
description,
|
||||
};
|
||||
return post;
|
||||
})
|
||||
.get();
|
||||
ctx.state.data = {
|
||||
title: $('head > title').text(),
|
||||
link: base_url,
|
||||
item: await Promise.all(out),
|
||||
};
|
||||
};
|
||||
@@ -1,48 +0,0 @@
|
||||
const got = require('@/utils/got');
|
||||
const cheerio = require('cheerio');
|
||||
|
||||
const { parseDate } = require('@/utils/parse-date');
|
||||
const timezone = require('@/utils/timezone');
|
||||
|
||||
function getArticle(ctx, list) {
|
||||
const now = list.map((line) =>
|
||||
ctx.cache.tryGet(line, async () => {
|
||||
const articleRaw = await got.get(`https://www.dynacw.com.tw/fontstory/${line}`);
|
||||
const $ = cheerio.load(articleRaw.data);
|
||||
const titleRaw = $('h2.col-xs-12.tc-deeppink').first().text();
|
||||
const tag = $('div.date-txt.col-xs-8.tc-gray').first().text();
|
||||
const timeRaw = $('div.date-txt.col-xs-4.tc-gray.text-right');
|
||||
$('main.container').find('ol.breadcrumb.hidden-xs').remove();
|
||||
$('main.container').find('section.row').first().remove();
|
||||
$('main.container').find('section.pages.row').remove();
|
||||
const desc = $('main.container').html();
|
||||
|
||||
return {
|
||||
title: `${titleRaw}(${tag})`,
|
||||
description: desc,
|
||||
pubDate: timezone(parseDate(timeRaw.text(), 'YYYY年MM月DD日'), +8),
|
||||
link: `https://www.dynacw.com.tw/fontstory/${line}`,
|
||||
};
|
||||
})
|
||||
);
|
||||
return Promise.all(now);
|
||||
}
|
||||
|
||||
module.exports = async (ctx) => {
|
||||
const response = await got({
|
||||
method: 'get',
|
||||
url: 'https://www.dynacw.com.tw/fontstory/fontstory.aspx',
|
||||
});
|
||||
|
||||
const $ = cheerio.load(response.data);
|
||||
const dom = $('div.font-item.col-xs-12');
|
||||
const relink = dom.map((_index, li) => $(li).find('a').first().attr('href'));
|
||||
const list = relink.toArray();
|
||||
|
||||
const rss = await getArticle(ctx, list.slice(0, 10));
|
||||
ctx.state.data = {
|
||||
title: '字型故事|華康字型',
|
||||
link: 'https://www.dynacw.com.tw/fontstory/fontstory.aspx',
|
||||
item: rss,
|
||||
};
|
||||
};
|
||||
@@ -1,44 +0,0 @@
|
||||
const got = require('@/utils/got');
|
||||
const cheerio = require('cheerio');
|
||||
|
||||
module.exports = async (ctx) => {
|
||||
const currentUrl = 'http://justrun.thisistap.com/';
|
||||
const response = await got({
|
||||
method: 'get',
|
||||
url: currentUrl,
|
||||
});
|
||||
const $ = cheerio.load(response.data);
|
||||
const list = $('#main article header h2 a')
|
||||
.slice(0, 10)
|
||||
.map((_, item) => {
|
||||
item = $(item);
|
||||
return {
|
||||
title: item.text(),
|
||||
link: item.attr('href'),
|
||||
};
|
||||
})
|
||||
.get();
|
||||
|
||||
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);
|
||||
|
||||
item.description = content('div.single-content').html();
|
||||
item.pubDate = new Date(content('meta[property="article:published_time"]').attr('content')).toUTCString();
|
||||
|
||||
return item;
|
||||
})
|
||||
)
|
||||
);
|
||||
|
||||
ctx.state.data = {
|
||||
title: $('title').text(),
|
||||
link: currentUrl,
|
||||
item: items,
|
||||
};
|
||||
};
|
||||
@@ -1,54 +0,0 @@
|
||||
const got = require('@/utils/got');
|
||||
const cheerio = require('cheerio');
|
||||
|
||||
async function getList(rootUrl) {
|
||||
const pages = [];
|
||||
let next = rootUrl;
|
||||
do {
|
||||
// eslint-disable-next-line no-await-in-loop
|
||||
const response = await got({ method: 'get', url: next });
|
||||
const $ = cheerio.load(response.data);
|
||||
pages.push(
|
||||
$('article').map((_, item) => ({
|
||||
title: $(item).find('.post-card-title').text(),
|
||||
link: rootUrl + $(item).find('.post-card-content-link').attr('href'),
|
||||
}))
|
||||
);
|
||||
next = $('link[rel=next]').attr('href');
|
||||
} while (next);
|
||||
return pages.reduce((acc, page) => cheerio.merge(acc, page)).get();
|
||||
}
|
||||
|
||||
module.exports = async (ctx) => {
|
||||
const rootUrl = 'https://blog.leanstack.com/';
|
||||
|
||||
const list = await getList(rootUrl);
|
||||
|
||||
const items = (
|
||||
await Promise.all(
|
||||
list.map(({ link, title }) =>
|
||||
ctx.cache.tryGet(link, () =>
|
||||
got({ method: 'get', url: link })
|
||||
.then(({ data }) => {
|
||||
const content = cheerio.load(data);
|
||||
|
||||
return {
|
||||
link,
|
||||
title,
|
||||
author: 'Ash Maurya',
|
||||
description: (content('.post-full-image').html() ?? '') + content('.post-content').html(),
|
||||
pubDate: content('meta[property="article:published_time"]').attr('content'),
|
||||
};
|
||||
})
|
||||
.catch(() => null)
|
||||
)
|
||||
)
|
||||
)
|
||||
).filter((x) => x !== null);
|
||||
|
||||
ctx.state.data = {
|
||||
title: "Ash Maurya's blog",
|
||||
link: rootUrl,
|
||||
item: items,
|
||||
};
|
||||
};
|
||||
@@ -1,3 +0,0 @@
|
||||
module.exports = {
|
||||
'/ash-maurya': ['james-tindal'],
|
||||
};
|
||||
@@ -1,13 +0,0 @@
|
||||
module.exports = {
|
||||
'blog.leanstack.com': {
|
||||
_name: "Ash Maurya's blog",
|
||||
'.': [
|
||||
{
|
||||
title: "Ash Maurya's blog",
|
||||
docs: 'https://docs.rsshub.app/routes/en/blog#ash-maurya',
|
||||
source: ['/'],
|
||||
target: '/ash-maurya',
|
||||
},
|
||||
],
|
||||
},
|
||||
};
|
||||
@@ -1,3 +0,0 @@
|
||||
module.exports = function (router) {
|
||||
router.get('/', require('./index'));
|
||||
};
|
||||
@@ -20,14 +20,6 @@ module.exports = {
|
||||
},
|
||||
},
|
||||
],
|
||||
sites: [
|
||||
{
|
||||
title: 'Sites',
|
||||
docs: 'https://docs.rsshub.app/routes/blog#google-sites',
|
||||
source: ['/site/:id/*', '/site/:id'],
|
||||
target: '/google/sites/:id',
|
||||
},
|
||||
],
|
||||
fonts: [
|
||||
{
|
||||
title: 'Fonts - Sort by Name',
|
||||
|
||||
@@ -1,75 +0,0 @@
|
||||
const got = require('@/utils/got');
|
||||
const cheerio = require('cheerio');
|
||||
|
||||
const base = 'https://sites.google.com/';
|
||||
|
||||
module.exports = async (ctx) => {
|
||||
const id = ctx.params.id;
|
||||
|
||||
const init_url = `https://sites.google.com/site/${id}/system/app/pages/sitemap/list?offset=0`;
|
||||
const init_response = await got.get(init_url);
|
||||
|
||||
const test_pages_count = init_response.data.match(/'sites-pagination-next-link-top', (\d+),/);
|
||||
if (!test_pages_count) {
|
||||
throw 'Site Not Found';
|
||||
}
|
||||
const pages_count = parseInt(test_pages_count[1]);
|
||||
|
||||
const url = pages_count > 20 ? `https://sites.google.com/site/${id}/system/app/pages/sitemap/list?offset=${pages_count - 20}` : init_url;
|
||||
const response = url === init_url ? init_response : await got.get(url);
|
||||
|
||||
const $ = cheerio.load(response.data);
|
||||
|
||||
const site_name = $('a#sites-chrome-userheader-title').text();
|
||||
const list = $('.sites-table > tbody > tr').get();
|
||||
|
||||
const parseContent = (htmlString) => {
|
||||
const $ = cheerio.load(htmlString);
|
||||
|
||||
const content = $('#sites-canvas-main-content');
|
||||
|
||||
return {
|
||||
description: content.html(),
|
||||
};
|
||||
};
|
||||
|
||||
const out = await Promise.all(
|
||||
list.map(async (item, index) => {
|
||||
const $ = cheerio.load(item);
|
||||
|
||||
const title = $('a');
|
||||
const path = title.attr('href');
|
||||
const link = base + path;
|
||||
const time = new Date();
|
||||
time.setMinutes(time.getMinutes() - pages_count + index);
|
||||
|
||||
const cache = await ctx.cache.get(link);
|
||||
if (cache) {
|
||||
return Promise.resolve(JSON.parse(cache));
|
||||
}
|
||||
|
||||
const rssitem = {
|
||||
title: title.text().trim(),
|
||||
link,
|
||||
pubDate: time,
|
||||
author: site_name,
|
||||
};
|
||||
|
||||
try {
|
||||
const response = await got.get(link);
|
||||
const result = parseContent(response.data);
|
||||
rssitem.description = result.description;
|
||||
} catch (err) {
|
||||
return Promise.resolve('');
|
||||
}
|
||||
ctx.cache.set(link, JSON.stringify(rssitem));
|
||||
return Promise.resolve(rssitem);
|
||||
})
|
||||
);
|
||||
|
||||
ctx.state.data = {
|
||||
title: `${site_name} - Google Sites`,
|
||||
link: url,
|
||||
item: out.filter((item) => item !== ''),
|
||||
};
|
||||
};
|
||||
@@ -1,29 +0,0 @@
|
||||
const got = require('@/utils/got');
|
||||
const cheerio = require('cheerio');
|
||||
|
||||
const BLOG_URL = 'https://blog.huangz.me/';
|
||||
|
||||
module.exports = async (ctx) => {
|
||||
const resp = await got({
|
||||
method: 'get',
|
||||
url: BLOG_URL,
|
||||
});
|
||||
const $ = cheerio.load(resp.body);
|
||||
const list = $('.toctree-l2');
|
||||
|
||||
const items = await Promise.all(
|
||||
list.map((index, item) => {
|
||||
const link = `${BLOG_URL}${$(item).find('a').attr('href')}`;
|
||||
|
||||
return ctx.cache.tryGet(link, () => ({
|
||||
title: $(item).find('a').text(),
|
||||
link,
|
||||
}));
|
||||
})
|
||||
);
|
||||
ctx.state.data = {
|
||||
title: 'huangz/blog',
|
||||
link: 'https://blog.huangz.me',
|
||||
item: items,
|
||||
};
|
||||
};
|
||||
@@ -1,3 +0,0 @@
|
||||
module.exports = {
|
||||
'/': ['stormbuf'],
|
||||
};
|
||||
@@ -1,13 +0,0 @@
|
||||
module.exports = {
|
||||
'huangz.me': {
|
||||
_name: '黄健宏博客',
|
||||
blog: [
|
||||
{
|
||||
title: '文章',
|
||||
docs: 'https://docs.rsshub.app/routes/blog#huang-jian-hong-bo-ke',
|
||||
source: ['/*.html'],
|
||||
target: '/huangz',
|
||||
},
|
||||
],
|
||||
},
|
||||
};
|
||||
@@ -1,3 +0,0 @@
|
||||
module.exports = function (router) {
|
||||
router.get('/', require('./index'));
|
||||
};
|
||||
@@ -1,35 +0,0 @@
|
||||
const got = require('@/utils/got');
|
||||
const cheerio = require('cheerio');
|
||||
const { parseDate } = require('@/utils/parse-date');
|
||||
const baseUrl = 'https://www.jiaoliudao.com';
|
||||
|
||||
module.exports = async (ctx) => {
|
||||
const { data } = await got(`${baseUrl}/wp-json/wp/v2/posts`, {
|
||||
searchParams: {
|
||||
per_page: ctx.query.limit ? parseInt(ctx.query.limit) : 100,
|
||||
},
|
||||
});
|
||||
|
||||
const items = data.map((item) => {
|
||||
const $ = cheerio.load(item.content.rendered, null, false);
|
||||
$('img').each((_, img) => {
|
||||
if (img.attribs['data-original']) {
|
||||
img.attribs.src = img.attribs['data-original'];
|
||||
delete img.attribs['data-original'];
|
||||
}
|
||||
});
|
||||
return {
|
||||
title: item.title.rendered,
|
||||
description: $.html(),
|
||||
pubDate: parseDate(item.date_gmt),
|
||||
link: item.link,
|
||||
};
|
||||
});
|
||||
|
||||
ctx.state.data = {
|
||||
title: '交流岛资源网-专注网络资源收集',
|
||||
image: `${baseUrl}/favicon.ico`,
|
||||
link: baseUrl,
|
||||
item: items,
|
||||
};
|
||||
};
|
||||
@@ -1,3 +0,0 @@
|
||||
module.exports = {
|
||||
'/': ['TonyRL'],
|
||||
};
|
||||
@@ -1,13 +0,0 @@
|
||||
module.exports = {
|
||||
'jiaoliudao.com': {
|
||||
_name: '交流岛资源网',
|
||||
'.': [
|
||||
{
|
||||
title: '最新文章',
|
||||
docs: 'https://docs.rsshub.app/routes/blog#jiao-liu-dao-zi-yuan-wang',
|
||||
source: ['/'],
|
||||
target: '/jiaoliudao',
|
||||
},
|
||||
],
|
||||
},
|
||||
};
|
||||
@@ -1,3 +0,0 @@
|
||||
module.exports = (router) => {
|
||||
router.get('/', require('./index'));
|
||||
};
|
||||
@@ -1,19 +0,0 @@
|
||||
const buildData = require('@/utils/common-config');
|
||||
|
||||
module.exports = async (ctx) => {
|
||||
const link = 'https://blog.miris.design/';
|
||||
|
||||
ctx.state.data = await buildData({
|
||||
link,
|
||||
url: link,
|
||||
title: 'Miris Whisper',
|
||||
author: 'Miris',
|
||||
description: 'Esoteric technical and sometimes personal stuff...',
|
||||
item: {
|
||||
item: 'ul > li',
|
||||
title: `$('li > a').contents().filter(function () { return this.type === 'text' }).text()`,
|
||||
link: `$('li > a').attr('href')`,
|
||||
pubDate: `parseDate($('li > a > .date').text().slice(1, 11))`,
|
||||
},
|
||||
});
|
||||
};
|
||||
@@ -1,3 +0,0 @@
|
||||
module.exports = {
|
||||
'/blog': ['chazeon'],
|
||||
};
|
||||
@@ -1,11 +0,0 @@
|
||||
module.exports = {
|
||||
'miris.design': {
|
||||
_name: 'Miris',
|
||||
blog: [
|
||||
{
|
||||
title: 'Miris Whispers',
|
||||
docs: 'https://docs.rsshub.app/routes/en/blog#miris-design',
|
||||
},
|
||||
],
|
||||
},
|
||||
};
|
||||
@@ -1,3 +0,0 @@
|
||||
module.exports = function (router) {
|
||||
router.get('/blog', require('./blog'));
|
||||
};
|
||||
@@ -1,34 +0,0 @@
|
||||
const got = require('@/utils/got');
|
||||
const cheerio = require('cheerio');
|
||||
const { parseDate } = require('@/utils/parse-date');
|
||||
module.exports = async (ctx) => {
|
||||
const response = await got('https://polkadot.network/blog');
|
||||
|
||||
const $ = cheerio.load(response.data);
|
||||
const list = $('.container .row .card > div > a:nth-child(2)');
|
||||
const items = await Promise.all(
|
||||
list
|
||||
.map((_, originItem) => {
|
||||
const item = {
|
||||
title: $(originItem).find('h5').text().trim(),
|
||||
link: 'https://polkadot.network' + $(originItem).attr('href'),
|
||||
};
|
||||
return ctx.cache.tryGet(item.link, async () => {
|
||||
const detailResponse = await got(item.link);
|
||||
const content = cheerio.load(detailResponse.data);
|
||||
const meta = JSON.parse(content('script[type="application/ld+json"]').text());
|
||||
item.author = meta.author.name;
|
||||
item.description = content('main .container').eq(1).html();
|
||||
item.pubDate = parseDate(meta.datePublished);
|
||||
return item;
|
||||
});
|
||||
})
|
||||
.get()
|
||||
);
|
||||
ctx.state.data = {
|
||||
title: $('head title').text(),
|
||||
link: 'https://polkadot.network/blog/',
|
||||
image: $('link[rel=icon]').attr('href'),
|
||||
item: items,
|
||||
};
|
||||
};
|
||||
@@ -1,3 +0,0 @@
|
||||
module.exports = {
|
||||
'/blog': ['iceqing'],
|
||||
};
|
||||
@@ -1,13 +0,0 @@
|
||||
module.exports = {
|
||||
'polkadot.network': {
|
||||
_name: 'Polkadot',
|
||||
'.': [
|
||||
{
|
||||
title: 'Blog',
|
||||
docs: 'https://docs.rsshub.app/routes/blog#polkadot',
|
||||
source: ['/', '/blog/', '/blog/*'],
|
||||
target: '/polkadot/blog',
|
||||
},
|
||||
],
|
||||
},
|
||||
};
|
||||
@@ -1,3 +0,0 @@
|
||||
module.exports = function (router) {
|
||||
router.get('/blog', require('./home'));
|
||||
};
|
||||
@@ -1,24 +0,0 @@
|
||||
const got = require('@/utils/got');
|
||||
const { parseDate } = require('@/utils/parse-date');
|
||||
const timezone = require('@/utils/timezone');
|
||||
|
||||
module.exports = async (ctx) => {
|
||||
const limit = ctx.query.limit ? parseInt(ctx.query.limit) : 10;
|
||||
const response = await got({
|
||||
method: 'get',
|
||||
url: 'https://pub.polkaworld.pro/articles?_sort=PublishDate:desc&_limit=' + limit,
|
||||
});
|
||||
const docList = response.data;
|
||||
|
||||
ctx.state.data = {
|
||||
title: 'PolkaWorld-资讯',
|
||||
link: 'https://www.polkaworld.org/',
|
||||
item: docList.map((item) => ({
|
||||
title: item.Title,
|
||||
description: item.Title,
|
||||
pubDate: timezone(parseDate(item.PublishDate), 0),
|
||||
author: item.author.Name,
|
||||
link: 'https://www.polkaworld.org/articles/' + item.URL,
|
||||
})),
|
||||
};
|
||||
};
|
||||
@@ -1,3 +0,0 @@
|
||||
module.exports = {
|
||||
'/polkaworld/newest': ['iceqing'],
|
||||
};
|
||||
@@ -1,13 +0,0 @@
|
||||
module.exports = {
|
||||
'polkaworld.org': {
|
||||
_name: 'PolkaWorld',
|
||||
www: [
|
||||
{
|
||||
title: '最新资讯',
|
||||
docs: 'https://docs.rsshub.app/routes/blog#polkaworld',
|
||||
source: ['/', '/articles/:name'],
|
||||
target: '/polkaworld/newest',
|
||||
},
|
||||
],
|
||||
},
|
||||
};
|
||||
@@ -1,3 +0,0 @@
|
||||
module.exports = function (router) {
|
||||
router.get('/newest', require('./home'));
|
||||
};
|
||||
@@ -1,5 +1,5 @@
|
||||
module.exports = {
|
||||
'miris.design': {
|
||||
'stratechery.com': {
|
||||
_name: 'Stratechery by Ben Thompson',
|
||||
blog: [
|
||||
{
|
||||
|
||||
@@ -1,55 +0,0 @@
|
||||
const got = require('@/utils/got');
|
||||
const cheerio = require('cheerio');
|
||||
const { parseDate } = require('@/utils/parse-date');
|
||||
|
||||
module.exports = async (ctx) => {
|
||||
const id = ctx.params.id ?? '';
|
||||
const what = ctx.params.what ?? '';
|
||||
|
||||
const rootUrl = 'https://whoscall.com';
|
||||
const currentUrl = `${rootUrl}/zh-hant/blog/${id ? `${what}/${id}` : 'articles'}`;
|
||||
|
||||
const response = await got({
|
||||
method: 'get',
|
||||
url: currentUrl,
|
||||
});
|
||||
|
||||
const $ = cheerio.load(response.data);
|
||||
|
||||
const list = $('.post-card__title a')
|
||||
.map((_, item) => {
|
||||
item = $(item);
|
||||
|
||||
return {
|
||||
title: item.text(),
|
||||
link: `${rootUrl}${item.attr('href')}`,
|
||||
};
|
||||
})
|
||||
.get();
|
||||
|
||||
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);
|
||||
|
||||
item.description = content('.blog-article__body').html();
|
||||
item.pubDate = parseDate(detailResponse.data.match(/"datePublished":"(.*)","dateModified"/)[1]);
|
||||
|
||||
return item;
|
||||
})
|
||||
)
|
||||
);
|
||||
|
||||
ctx.state.data = {
|
||||
title: $('title')
|
||||
.text()
|
||||
.replace(/ - 第\d+頁/, ''),
|
||||
link: currentUrl,
|
||||
item: items,
|
||||
};
|
||||
};
|
||||
@@ -1,5 +0,0 @@
|
||||
module.exports = {
|
||||
'/': ['nczitzk'],
|
||||
'/tags/:tag?': ['nczitzk'],
|
||||
'/categories/:category?': ['nczitzk'],
|
||||
};
|
||||
@@ -1,25 +0,0 @@
|
||||
module.exports = {
|
||||
'whoscall.com': {
|
||||
_name: 'Whoscall',
|
||||
'.': [
|
||||
{
|
||||
title: '最新文章',
|
||||
docs: 'https://docs.rsshub.app/routes/blog#whoscall-zui-xin-wen-zhang',
|
||||
source: ['/zh-hant/blog/articles', '/'],
|
||||
target: '/whoscall',
|
||||
},
|
||||
{
|
||||
title: '分類',
|
||||
docs: 'https://docs.rsshub.app/routes/blog#whoscall-fen-lei',
|
||||
source: ['/zh-hant/blog/categories/:category', '/'],
|
||||
target: '/whoscall/categories/:category?',
|
||||
},
|
||||
{
|
||||
title: '標籤',
|
||||
docs: 'https://docs.rsshub.app/routes/blog#whoscall-biao-qian',
|
||||
source: ['/zh-hant/blog/tags/:tag', '/'],
|
||||
target: '/whoscall/tags/:tag?',
|
||||
},
|
||||
],
|
||||
},
|
||||
};
|
||||
@@ -1,3 +0,0 @@
|
||||
module.exports = function (router) {
|
||||
router.get('/:what?/:id?', require('./index'));
|
||||
};
|
||||
@@ -68,16 +68,6 @@
|
||||
|
||||
<Route author="HankChow" example="/geocaching/blogs" path="/geocaching/blogs" radar="1" />
|
||||
|
||||
## Google Sites {#google-sites}
|
||||
|
||||
### Articles {#google-sites-articles}
|
||||
|
||||
<Route author="hoilc" example="/google/sites/outlierseconomics" path="/google/sites/:id" paramsDesc={['Site ID, can be found in URL']} notOperational="1" />
|
||||
|
||||
### Recent Changes {#google-sites-recent-changes}
|
||||
|
||||
<Route author="nczitzk" example="/google/sites/recentChanges/outlierseconomics" path="/google/sites/recentChanges/:id" paramsDesc={['Site ID, can be found in URL']} notOperational="1" />
|
||||
|
||||
## Gwern Branwen {#gwern-branwen}
|
||||
|
||||
### 博客 {#gwern-branwen-bo-ke}
|
||||
@@ -120,16 +110,6 @@
|
||||
|
||||
<Route author="gkkeys" path="/hexo/fluid/:url" example="/hexo/fluid/blog.tonyzhao.xyz" paramsDesc={['the blog URL without the protocol (http:// and https://)']} configRequired="1" />
|
||||
|
||||
## Hi, DIYgod {#hi-diygod}
|
||||
|
||||
### DIYgod 的动森日记 {#hi-diygod-diygod-de-dong-sen-ri-ji}
|
||||
|
||||
<Route author="DIYgod" example="/blogs/diygod/animal-crossing" path="/blogs/diygod/animal-crossing" notOperational="1" />
|
||||
|
||||
### DIYgod 的可爱的手办们 {#hi-diygod-diygod-de-ke-ai-de-shou-ban-men}
|
||||
|
||||
<Route author="DIYgod" example="/blogs/diygod/gk" path="/blogs/diygod/gk" notOperational="1" />
|
||||
|
||||
## Ian Spriggss {#ian-spriggss}
|
||||
|
||||
### Category {#ian-spriggss-category}
|
||||
@@ -140,12 +120,6 @@
|
||||
| portraits | characters |
|
||||
</Route>
|
||||
|
||||
## JustRun {#justrun}
|
||||
|
||||
### JustRun {#justrun-justrun}
|
||||
|
||||
<Route author="nczitzk" example="/justrun" path="/justrun" notOperational="1" />
|
||||
|
||||
## Kun Cheng {#kun-cheng}
|
||||
|
||||
### Essay {#kun-cheng-essay}
|
||||
@@ -164,12 +138,6 @@
|
||||
|
||||
<Route author="xyqfer" example="/leemeng" path="/leemeng" />
|
||||
|
||||
## Love the Problem {#love-the-problem}
|
||||
|
||||
### Ash Maurya's blog {#love-the-problem-ash-maurya-s-blog}
|
||||
|
||||
<Route author="james-tindal" example="/ash-maurya" path="/ash-maurya" notOperational="1" />
|
||||
|
||||
## MacMenuBar {#macmenubar}
|
||||
|
||||
### Recently {#macmenubar-recently}
|
||||
@@ -214,12 +182,6 @@
|
||||
:::
|
||||
</Route>
|
||||
|
||||
## Miris Whispers {#miris-whispers}
|
||||
|
||||
### Blog {#miris-whispers-blog}
|
||||
|
||||
<Route author="chazeon" example="/miris/blog" path="/miris/blog" notOperational="1" />
|
||||
|
||||
## Paul Graham {#paul-graham}
|
||||
|
||||
### Essays {#paul-graham-essays}
|
||||
@@ -232,22 +194,6 @@
|
||||
|
||||
<Route author="CitrusIce" example="/phrack" path="/phrack" />
|
||||
|
||||
## Polkadot {#polkadot}
|
||||
|
||||
### Blog {#polkadot-blog}
|
||||
|
||||
<Route author="iceqing" example="/polkadot/blog" path="/polkadot/blog" notOperational="1" />
|
||||
|
||||
## PolkaWorld {#polkaworld}
|
||||
|
||||
### Newest Articles {#polkaworld-newest-articles}
|
||||
|
||||
<Route author="iceqing" example="/polkaworld/newest" path="/polkaworld/newest" notOperational="1" />
|
||||
|
||||
:::tip
|
||||
Limit the number of entries to be retrieved by adding `?limit=x` to the end of the route, default value is `10`.
|
||||
:::
|
||||
|
||||
## Stratechery by Ben Thompson {#stratechery-by-ben-thompson}
|
||||
|
||||
### Blog {#stratechery-by-ben-thompson-blog}
|
||||
@@ -288,27 +234,6 @@ Limit the number of entries to be retrieved by adding `?limit=x` to the end of t
|
||||
|
||||
<Route author="TonyRL" example="/v1tx" path="/v1tx" radar="1" />
|
||||
|
||||
## Whoscall {#whoscall}
|
||||
|
||||
### 最新文章 {#whoscall-zui-xin-wen-zhang}
|
||||
|
||||
<Route author="nczitzk" example="/whoscall" path="/whoscall" notOperational="1" />
|
||||
|
||||
### 分類 {#whoscall-fen-lei}
|
||||
|
||||
<Route author="nczitzk" example="/whoscall/categories/5-Whoscall 百科" path="/whoscall/categories/:category?" paramsDesc={['分类,见下表,可在对应分類页 URL 中找到,默认为最新文章']} notOperational="1">
|
||||
| News | Whoscall 百科 | 防詐小學堂 | Whoscall 日常 |
|
||||
| ------ | --------------- | -------------- | --------------- |
|
||||
| 1-News | 5-Whoscall 百科 | 4 - 防詐小學堂 | 6-Whoscall 日常 |
|
||||
</Route>
|
||||
|
||||
### 標籤 {#whoscall-biao-qian}
|
||||
|
||||
<Route author="nczitzk" example="/whoscall/tags" path="/whoscall/tags/:tag?" paramsDesc={['標籤,见下表,可在对应標籤页 URL 中找到,默认为最新文章']} notOperational="1">
|
||||
| 防疫也防詐 | 防詐專家 | 來電辨識 | whoscall 日常 |
|
||||
| ---------- | -------- | -------- | ------------- |
|
||||
</Route>
|
||||
|
||||
## WordPress {#wordpress}
|
||||
|
||||
### Blog {#wordpress-blog}
|
||||
@@ -321,12 +246,6 @@ Limit the number of entries to be retrieved by adding `?limit=x` to the end of t
|
||||
|
||||
<Route author="nczitzk" example="/yuzu-emu/entry" path="/yuzu-emu/entry" />
|
||||
|
||||
## 阿里云系统组技术博客 {#a-li-yun-xi-tong-zu-ji-shu-bo-ke}
|
||||
|
||||
### 首页 {#a-li-yun-xi-tong-zu-ji-shu-bo-ke-shou-ye}
|
||||
|
||||
<Route author="attenuation" example="/aliyun-kernel/index" path="/aliyun-kernel/index" notOperational="1" />
|
||||
|
||||
## 博客园 {#bo-ke-yuan}
|
||||
|
||||
### 10 天推荐排行榜 {#bo-ke-yuan-10-tian-tui-jian-pai-hang-bang}
|
||||
@@ -391,24 +310,6 @@ Limit the number of entries to be retrieved by adding `?limit=x` to the end of t
|
||||
|
||||
<Route author="wxluckly" example="/xunhupay/blog" path="/xunhupay/blog" radar="1" />
|
||||
|
||||
## 華康字型故事 {#hua-kang-zi-xing-gu-shi}
|
||||
|
||||
### 博客 {#hua-kang-zi-xing-gu-shi-bo-ke}
|
||||
|
||||
<Route author="tpnonthealps" example="/fontstory" path="/fontstory" notOperational="1" />
|
||||
|
||||
## 黄健宏博客 {#huang-jian-hong-bo-ke}
|
||||
|
||||
### 文章 {#huang-jian-hong-bo-ke-wen-zhang}
|
||||
|
||||
<Route author="stormbuf" example="/huangz" path="/huangz" radar="1" notOperational="1" />
|
||||
|
||||
## 建宁闲谈 {#jian-ning-xian-tan}
|
||||
|
||||
### 文章 {#jian-ning-xian-tan-wen-zhang}
|
||||
|
||||
<Route author="changlan" example="/blogs/jianning" path="/blogs/jianning" radar="1" notOperational="1" />
|
||||
|
||||
## 劍心.回憶 {#jian-xin-hui-yi}
|
||||
|
||||
### 分类 {#jian-xin-hui-yi-fen-lei}
|
||||
@@ -453,12 +354,6 @@ Limit the number of entries to be retrieved by adding `?limit=x` to the end of t
|
||||
| drama\_deep | drama\_rating | drama\_column | drama\_interactive |
|
||||
</Route>
|
||||
|
||||
## 交流岛资源网 {#jiao-liu-dao-zi-yuan-wang}
|
||||
|
||||
### 最新文章 {#jiao-liu-dao-zi-yuan-wang-zui-xin-wen-zhang}
|
||||
|
||||
<Route author="TonyRL" example="/jiaoliudao" path="/jiaoliudao" radar="1" notOperational="1" />
|
||||
|
||||
## 敬维博客 {#jing-wei-bo-ke}
|
||||
|
||||
### 文章 {#jing-wei-bo-ke-wen-zhang}
|
||||
|
||||
Reference in New Issue
Block a user