lightly init

This commit is contained in:
hillerliao
2022-08-09 18:20:57 +08:00
parent 0001db454e
commit 6608cf1c2b
3 changed files with 41 additions and 35 deletions

6
.lightly/settings.toml Normal file
View File

@@ -0,0 +1,6 @@
title = "lightly settings"
ports = []
[languages]

View File

@@ -5,7 +5,7 @@ domain = 'http://www.bjnews.com.cn'
def parse(post): def parse(post):
item = {} item = {}
item['description'] = item['title'] = post.css('a::text').extract_first() item['description'] = item['title'] = post.css('a::text').extract_first()
item['link'] = post.css('a::attr(href)').extract_first() item['link'] = post.css('a::attr(href)').extract_first()
return item return item