From d3652e046f5ca969918d94d82fba12d3cd6de6b7 Mon Sep 17 00:00:00 2001 From: Leo Date: Thu, 11 Jul 2024 01:29:18 +0800 Subject: [PATCH] scrapy: add Chinese translation (#13243) Co-authored-by: Jack Lin --- pages.zh/common/scrapy.md | 32 ++++++++++++++++++++++++++++++++ 1 file changed, 32 insertions(+) create mode 100644 pages.zh/common/scrapy.md diff --git a/pages.zh/common/scrapy.md b/pages.zh/common/scrapy.md new file mode 100644 index 0000000000..481ca1830a --- /dev/null +++ b/pages.zh/common/scrapy.md @@ -0,0 +1,32 @@ +# scrapy + +> Web 爬取框架。 +> 更多信息:. + +- 创建一个项目: + +`scrapy startproject {{项目名}}` + +- 创建一个爬虫(在项目目录下): + +`scrapy genspider {{爬虫名}} {{站点域名}}` + +- 编辑爬虫(在项目目录下): + +`scrapy edit {{爬虫名}}` + +- 运行爬虫(在项目目录下): + +`scrapy crawl {{爬虫名}}` + +- 抓取一个网页并将它的网页源码打印至标准输出: + +`scrapy fetch {{url}}` + +- 使用默认浏览器打开给定的 URL 来确认是否符合期望(为确保准确会禁用 JavaScript): + +`scrapy view {{url}}` + +- 通过给定的 URL 打开交互窗口,除此之外还支持 UNIX 风格的本地文件路径: + +`scrapy shell {{url}}`