Skip to content

Commit

Permalink
feat: init
Browse files Browse the repository at this point in the history
  • Loading branch information
alisonjoe committed Feb 17, 2024
1 parent 2e4481b commit ee1e80f
Show file tree
Hide file tree
Showing 4 changed files with 11 additions and 10 deletions.
2 changes: 1 addition & 1 deletion wallpaper_scrapy/scrapy.cfg
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,6 @@
[settings]
default = wallpaper_scrapy.settings

[deploy]
[deploy:wallpaper]
url = http://192.168.1.105:6800/
project = wallpaper_scrapy
4 changes: 2 additions & 2 deletions wallpaper_scrapy/wallpaper_scrapy/hugomiddlewares.py
Original file line number Diff line number Diff line change
Expand Up @@ -21,8 +21,8 @@ def hugo_gen_html(self, item, spider):
working_directory = settings.get('WALLPAPER_BASE')

self.hugo_gen_toml(item, working_directory)
#self.hugo_gen(working_directory)
#self.push_github(working_directory)
self.hugo_gen(working_directory)
self.push_github(working_directory)

def hugo_gen_toml(self, item, cwd_path):
# 读取 TOML 模板文件
Expand Down
12 changes: 6 additions & 6 deletions wallpaper_scrapy/wallpaper_scrapy/settings.py
Original file line number Diff line number Diff line change
Expand Up @@ -61,12 +61,12 @@
'wallpaper_scrapy.pipelines.WallpaperImgDownloadPipeline': 300
}

#IMAGES_STORE="/app/wallpaper/static"
#BLOG_STORE="/app/wallpaper/content/blog"
#WALLPAPER_BASE="/app/wallpaper"
WALLPAPER_BASE="/Users/alison/WorkSpace/Wallpaper/"
IMAGES_STORE="/Users/alison/WorkSpace/Wallpaper/static"
BLOG_STORE="/Users/alison/WorkSpace/Wallpaper/content/blog"
WALLPAPER_BASE="/app/Wallpaper"
IMAGES_STORE="/app/Wallpaper/static"
BLOG_STORE="/app/Wallpaper/content/blog"
#WALLPAPER_BASE="/Users/alison/WorkSpace/Wallpaper/"
#IMAGES_STORE="/Users/alison/WorkSpace/Wallpaper/static"
#BLOG_STORE="/Users/alison/WorkSpace/Wallpaper/content/blog"

# Set settings whose default value is deprecated to a future-proof value
REQUEST_FINGERPRINTER_IMPLEMENTATION = "2.7"
Expand Down
3 changes: 2 additions & 1 deletion wallpaper_scrapy/wallpaper_scrapy/spiders/bing.py
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,8 @@ class WallpaperBingSpider(scrapy.Spider):

def start_requests(self):
for url in self.start_urls:
yield SplashRequest(url=url, callback=self.parse)
#yield SplashRequest(url=url, callback=self.parse, args={'wait': 6, 'timeout':60})
yield Request(url=url, callback=self.parse)


def parse(self, response):
Expand Down

0 comments on commit ee1e80f

Please sign in to comment.