hexo-url-submission
v2.0.0
Published
Submit website url to search engines.
Downloads
98
Maintainers
Readme
Hexo-url-submission
Welcome to make valuable comments and Star
Roadmap
Documentation
Donate
Hexo-URL-Submssion is used to submit site URLs to major search engines, including Google, Bing, ShenMa and Baidu, to improve the speed and quality of sites included in search engines.
These three major search engines have occupied 98% of the global search engine market share (except Yandex Ru). Later, I will support api submission for more search engines.
As of August 2021, Google: 92.05%, Bing: 2.45%, Yahoo!: 1.5%, Baidu: 1.39%, Yandex: 1.21%, DuckDuckGo: 0.63%.
In China, Baidu, 360, Shenma (only app), Toutiao, Sogou and other search engines occupy a dominant position
Version record
- v1.0.0 feat: Support Baidu, Google, Bing url batch submission
- v1.0.1 fix(bing_deployer): local variables overwrite global variables and cause data errors
- v1.0.2 feat(shenma): Support ShenMa Search Engine
- v1.0.3 improve(dep): improve package dep
- v1.0.4 improve(dep): remove deprecated dep
- v1.0.5 optimize(deployer): optimized deployer
- v1.0.6 optimize(dep): replace
request(deprecated)
- v1.0.7 fix: Nodejs16+ DEP API & hexo 6.1 bug
- v1.0.9 optimize(google/bing): optimized google deployer 400, fixed bing deployer quote
- ⭐️v2.0.0 refactor: Added support for
ignore
parameters and wildcards, Channel parameters under independent control#7
Quick start
1. Install
npm install --save hexo-url-submission
or
yarn add hexo-url-submission
2. Edit hexo _config.yml
(1) hexo-url-submission
You can use environment variables in your local or CI/CD tools to safely store tokens
url_submission:
enable: true
type: 'latest' # latest or all( latest: modified pages; all: posts & pages)
channels: # included channels are `baidu`, `google`, `bing`, `shenma`
baidu:
token: "" # Baidu Private Token
count: 10 # Optional
bing:
token: "" # Bing Access Token
count: 10 # Optional
google:
key: "google.json" # Google key path (e.g. `google_key.json` or `data/google_key.json`)
count: 10 # Optional
shenma:
count: 10 # Optional
user: "" # Username used when registering
token: "" # ShenMa Private Key
prefix: ['/post', '/wiki'] # URL prefix
ignore: ["/post/a*", "/post/a?c"] # URL addresses that do not need to be submitted (wildcards are supported)
count: 10 # Submit limit
urls_path: 'submit_url.txt' # URL list file path
sitemap: '' # Sitemap path(e.g. the url is like this https://abnerwei.com/baidusitemap.xml, you can fill in `baidusitemap.xml`)
(2) deploy
deploy:
- type: url_submission
3. good job
Run:
hexo clean && hexo g && hexo d
enjoy it!
success response:
INFO Deploying: url_submission
WARN url_submission: (baidu) The number of submitted entries for Baidu Search is not set, and the default value will be used for submission.
WARN url_submission: (baidu) The number of entries submitted by Baidu Search has been set to 37
INFO url_submission: (baidu) Start submit urlList to baidu engine...
INFO url_submission: (baidu) Submit to baidu engine success: [success: 37, remain: 2963]
WARN url_submission: (bing) The number of submitted entries for Bing Search is not set. Continue to detect the remaining quota or the default value will be used for submission.
WARN url_submission: (bing) The number of entries submitted by Bing Search has been set to 37
INFO url_submission: (bing) Get bing engine remain, [daliy: 100, monthly: 2800]
INFO url_submission: (bing) Start submit urlList to bing engine...
INFO url_submission: (bing) Submit to bing engine success.
WARN url_submission: (google) The number of submitted entries for Google Search is not set, and the default value will be used for submission.
WARN url_submission: (google) The number of entries submitted by Google Search has been set to 37
INFO url_submission: (google) Start submit urlList to google engine...
INFO url_submission: (google) Submit to google engine success
INFO url_submission: (google) Google Sitemap Notification Received.
WARN url_submission: (shenma) The number of submitted entries for ShenMa Search is not set, and the default value will be used for submission.
WARN url_submission: (shenma) The number of entries submitted by ShenMa Search has been set to 37
INFO url_submission: (shenma) Start submit urlList to shenma engine...
INFO url_submission: (shenma) Submit to shenma engine failed: [token illegal]
INFO Deploy done: url_submission