自己建的图床服务器线路总是出问题,也没有什么别的免费图床来用,于是使用PicGo将Github作为免费图床
相关链接
PicGo文档:https://picgo.github.io/PicGo-Doc/
PicGo下载:https://github.com/Molunerfinn/picgo/releases
配置Github仓库
前往Github,创建一个new repository:https://github.com/new
给新仓库起个名字,然后将公开性设置为Public,最后创建仓库
获取Token
进入Settings
- Developer Settings
- Personal Access Tokens
- Tokens(classic)
- Generate new token
- Generate new token(classic)
设定好Token的备注,Expiration设置为NO Expiration
,Select scopes勾选Repo
及其子项内容
翻到页面最底部,点击Generate token
生成token
复制生成的Token并妥善保存,这个Token只会显示一次
配置PicGo
前往下载PicGo
PicGo下载:https://github.com/Molunerfinn/picgo/releases
安装后运行,打开图床设置
- Github图床
完成以下配置:
-
图床配置名:自己取个名字
-
设定仓库名:
你的github昵称/你的仓库名
-
设定分支名:
main
-
设定Token:粘贴你的Token
-
设定存储路径:
img/
-
自定义域名(这里使用CDN):
https://cdn.jsdelivr.net/gh/你的github昵称/你的仓库名@master
完成后确定,返回上传区,选择你创建的配置即可开始上传