GreaysFork 增強WebHook同步設定

GreaysFork 快速輸入腳本同步資訊,並批量增加多個國家的語言代碼,而不用逐個點擊選擇框再去對應的網址。

目前為 2024-09-04 提交的版本,檢視 最新版本

作者
人民的勤务员
評價
0 0 0
版本
1.0
建立日期
2024-09-04
更新日期
2024-09-04
尺寸
27.0 KB
相容性
相容於 Firefox 相容於 Chrome 相容於 Opera 相容於 Safari 相容於 Edge
授權條款
MIT
腳本執行於

GreasyFork - Enhanced WebHook Synchronization Settings

When setting up synchronization information on GreasyFork, you might often find that after submitting, the sync information hasn't been successfully saved, requiring you to re-enter it. This is one of the small issues with the website. To solve this problem, this script helps you quickly input script synchronization information and batch-add multiple country language codes without having to click on each checkbox and then go to the corresponding URL.

Features

  • Quick Input of Synchronization Information: No need to manually repeat input, allowing you to quickly set and sync information.
  • Batch Add Language Codes: Supports batch addition of multiple country/region language codes without the need to select each one individually.
  • Supports Multiple Formats: You can choose different URL formats for setup based on your needs.

Instructions (For more details, refer to the images below or the video above)

  • Script Management Page: On the script management page, an additional button is added at the bottom. After clicking it, you can manage the current script.
  • Website Top Navigation Bar: Adds an option to the navigation bar that, when clicked, automatically retrieves the WebHook synchronized scripts for multiple management.

Supported Formats

Currently, the following three formats are supported:

  1. Get Country Language from Markdown File: Only supports README_xxx.md. https://www.xxx.com/path/to/your/README_xxxxx.md
  2. Directly Set Corresponding Country Language (Simple Format): Supports other format files. https://www.xxx.com/path/to/your/filename.md##ko
  3. Directly Set Corresponding Country Language (Detailed Format): Supports other format files. https://www.xxx.com/path/to/your/filename.md##简体中文 (zh-CN)

Example code: If you have more options, you can extend it. let localeKey = url.includes('##') ? url.match(/##.*\((.*?)\)$/) || url.match(/##(.*?)$/) : url.match(/README_(.*?)\.md/)

Attention:

  • When submitting localized country information, there must be a header declaration such as//@ name: zh CN in the code, otherwise even if the submission is successful, it will still fail!
  • The script must exist! Otherwise, synchronization will fail,

Project and Feedback

sync.png nav.png