Skip to content

Commit

Permalink
add img download support
Browse files Browse the repository at this point in the history
  • Loading branch information
ResolveWang committed Nov 2, 2017
1 parent 53b6d25 commit 1828c85
Show file tree
Hide file tree
Showing 2 changed files with 7 additions and 5 deletions.
3 changes: 2 additions & 1 deletion config/__init__.py
Original file line number Diff line number Diff line change
Expand Up @@ -5,5 +5,6 @@
get_db_args, get_redis_args, get_timeout, get_crawl_interal, get_excp_interal,
get_max_repost_page, get_max_search_page, get_max_home_page, get_max_comment_page,
get_max_retries, get_broker_and_backend, get_redis_master, get_code_username, get_code_password,
get_running_mode, get_crawling_mode, get_share_host_count, get_cookie_expire_time, get_email_args
get_running_mode, get_crawling_mode, get_share_host_count, get_cookie_expire_time, get_email_args,
get_images_allow, get_images_path, get_images_type
)
9 changes: 5 additions & 4 deletions config/spider.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -35,15 +35,16 @@ share_host_count: 5
# the expire time(hours) of each weibo cookies
cookie_expire_time: 23

# true for allow download images, false otherwise
images_allow: false
# 1 for allow download images, otherwise set it to 0
images_allow: 1

# the default image path is '${user.home}/weibospider/images'
# if you want to change another directory for download image, just set the path below
images_path: ''

# In large type, you will download the large image
# In thumbnail type, you will download the thumbnail image
# the value can be large or thumbnail
# in large type, you will download the large image
# in thumbnail type, you will download the thumbnail image
image_type: large

db:
Expand Down

0 comments on commit 1828c85

Please sign in to comment.