Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/foliageowo/get-server-last-version
方便快捷地获取 Paper Spigot Vanilla 三个 Minecraft 服务端最新构建版本及下载链接
https://github.com/foliageowo/get-server-last-version
Last synced: about 1 month ago
JSON representation
方便快捷地获取 Paper Spigot Vanilla 三个 Minecraft 服务端最新构建版本及下载链接
- Host: GitHub
- URL: https://github.com/foliageowo/get-server-last-version
- Owner: FoliageOwO
- Created: 2021-07-03T10:13:44.000Z (over 3 years ago)
- Default Branch: master
- Last Pushed: 2021-07-03T10:43:14.000Z (over 3 years ago)
- Last Synced: 2024-10-15T01:23:04.119Z (3 months ago)
- Language: Python
- Homepage:
- Size: 11.7 KB
- Stars: 1
- Watchers: 0
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
Awesome Lists containing this project
README
# get-server-last-version
方便快捷地获取 `Paper` `Spigot` `Vanilla` 三个 Minecraft 服务端最新构建版本及下载链接使用 ***BeautifulSoup*** 对网页进行快速爬取, 并且不需要 `headers` 与 `proxy` 即可获取
## 使用方法
执行 `python main.py` 可以快速查看 `Paper` `Spigot` `Vanilla` 的最新版本的 dict 字典
```python
# paper, spigot, vanilla 的用法一样from paper import get_paper
print(get_paper()) # 获取整个 dict 字典
print(get_paper()['version']) # 获取最新版本号
print(get_paper()['download_url']) # 获取下载链接
```将其添加至项目, 只需将 `custom_typing.py` 与 `util.py` 嵌入进去或修改文件名后直接导入即可
## All in one
如果你认为嵌入文件或修改导入的方法太麻烦, 那就直接使用 `get_server_last_version.py`, 使用方法如下:
```python
from get_server_last_version import get_paper # get_spigot, get_vanillaprint(get_paper()) # 获取整个 dict 字典
# ...
```这样就可以直接添加至项目, 无需多余的操作