LetTTGACO / elog

Markdown 批量导出工具、开放式跨平台博客解决方案,随意组合写作平台(语雀/Notion/FlowUs/飞书/我来Wolai)和博客平台(Hexo/Vitepress/Halo/Confluence/WordPress等)
https://elog.1874.cool
MIT License
1.22k stars 59 forks source link

github图床问题 #63

Closed xinkeji closed 5 months ago

xinkeji commented 5 months ago

你当前使用的Elog版本

0.13.1

Elog配置文件

上传失败:a4e6d6bb79f6f4f5af7e31d115f6144b.jpeg 请检查图床配置
请求失败  unable to verify the first certificate, PUT https://api.github.com/repos/xinkeji/hexo/contents/71c3ca0f6d6211c
          b427f50ae354471a0.jpeg -1 (connected: true, keepalive socket: false, socketHandledRequests: 1, socketHandledRe
          sponses: 0)
          headers: {}

发生了什么?

已经配置好github变量之后还是上传不了,怎么办呀

Elog错误日志

module.exports = {
  write: {
    platform: 'yuque-pwd',
    "yuque-pwd": {
      username: process.env.YUQUE_USERNAME,
      password: process.env.YUQUE_PWD,
      host: '',
      login: process.env.YUQUE_LOGIN,
      repo: process.env.YUQUE_REPO,
      linebreak: false
    }
  },
  deploy: {
    platform: "local",
    local: {
      outputDir: "./source/_posts/语雀/",
      filename: "title",
      format: "matter-markdown",
      catalog: true,
      formatExt: "",
    }
  },
  image: {
  enable: true,
  platform: 'github',
  github: {
    user: process.env.LGH_USER,
    token: process.env.GITHUB_TOKEN,
    repo: process.env.LGH_REPO,
    prefixKey: '',
    host: 'cdn.jsdelivr.net'

    }
  },
}

附加信息

1

LetTTGACO commented 5 months ago

看起来确实是 Github 配置错误,也许是 Token 权限问题、Token 配置错误、或者是其他配置错误

需要检查LGH_USER GITHUB_TOKEN LGH_REPO.elog.env是否配置正确

Github 配置信息获取文档:https://elog.1874.cool/notion/gvnxobqogetukays#github

LetTTGACO commented 5 months ago

可以提供更详细的运行日志么?我需要从头排查

LetTTGACO commented 5 months ago

.elog.env 设置DEBUG=true会打印更详细的日志,可以看下具体的错误

LetTTGACO commented 5 months ago

https://zhuanlan.zhihu.com/p/653288802

可能和 GFW 软件有关,请关闭代理试试

xinkeji commented 5 months ago

我草我感觉是我没开代理的原因…我无法直接访问github

---原始邮件--- 发件人: @.> 发送时间: 2024年1月22日(周一) 晚上11:30 收件人: @.>; 抄送: @.**@.>; 主题: Re: [LetTTGACO/elog] github图床问题 (Issue #63)

https://zhuanlan.zhihu.com/p/653288802

可能和 GFW 软件有关,请关闭代理试试

— Reply to this email directly, view it on GitHub, or unsubscribe. You are receiving this because you authored the thread.Message ID: @.***>

xinkeji commented 5 months ago

1705937879241 好像不行

xinkeji commented 5 months ago

Deploy Elog-Hexo Public To Pages

LetTTGACO commented 5 months ago

我发现一个问题:你的 Github 图片仓库和 hexo 博客仓库怎么是一样的? 如果你想直接把图片上传到hexo 博客仓库仓库,那就选本地存放图片就行,到时候一起 commit 上去

xinkeji commented 5 months ago

😂如果不能自动图库,那用语雀就没有意义了.,事实上就目前感觉没有自动部署而已我感觉语雀,还不如直接用github手机版写呢

---原始邮件--- 发件人: @.> 发送时间: 2024年1月23日(周二) 凌晨0:02 收件人: @.>; 抄送: @.**@.>; 主题: Re: [LetTTGACO/elog] github图床问题 (Issue #63)

我发现一个问题:你的 Github 图片仓库和 hexo 博客仓库怎么是一样的? 如果你想直接把图片上传到hexo 博客仓库仓库,那就选本地存放图片就行,到时候一起 commit 上去

— Reply to this email directly, view it on GitHub, or unsubscribe. You are receiving this because you authored the thread.Message ID: @.***>

xinkeji commented 5 months ago

主要写别的他也没法用

---原始邮件--- 发件人: @.> 发送时间: 2024年1月23日(周二) 凌晨0:02 收件人: @.>; 抄送: @.**@.>; 主题: Re: [LetTTGACO/elog] github图床问题 (Issue #63)

我发现一个问题:你的 Github 图片仓库和 hexo 博客仓库怎么是一样的? 如果你想直接把图片上传到hexo 博客仓库仓库,那就选本地存放图片就行,到时候一起 commit 上去

— Reply to this email directly, view it on GitHub, or unsubscribe. You are receiving this because you authored the thread.Message ID: @.***>

LetTTGACO commented 5 months ago

不是 你就直接写本地就行啊,流水线自动 commit 就行

xinkeji commented 5 months ago

阿可以吗

---原始邮件--- 发件人: @.> 发送时间: 2024年1月23日(周二) 凌晨0:06 收件人: @.>; 抄送: @.**@.>; 主题: Re: [LetTTGACO/elog] github图床问题 (Issue #63)

不是 你就直接写本地就行啊,流水线自动 commit 就行

— Reply to this email directly, view it on GitHub, or unsubscribe. You are receiving this because you authored the thread.Message ID: @.***>

LetTTGACO commented 5 months ago

主要写别的他也没法用? 我的就可以啊,在 A 仓库运行流水线,将图片存放在 B 仓库 这是我的 Github 图床,统一用来存图片的,https://github.com/LetTTGACO/image

创建 Github 图床应该有教程,要开启一些配置才行,我有点忘了你可以搜一下

而且你这有点伪需求

如果你的目的是将图片和本地 doc 都放在 Github,那么就直接下载图片到仓库指定目录,然后流水线上 commit 自动提交 如果你和我一样,将图片统一存在在 B 仓库,那就去网上搜一下 Github 图床创建,然后在 elog.config.js中配置仓库 B 的信息就行

xinkeji commented 5 months ago

好的谢谢我试试

---原始邮件--- 发件人: @.> 发送时间: 2024年1月23日(周二) 凌晨0:10 收件人: @.>; 抄送: @.**@.>; 主题: Re: [LetTTGACO/elog] github图床问题 (Issue #63)

主要写别的他也没法用? 我的就可以啊,在 A 仓库运行流水线,将图片存放在 B 仓库 这是我的 Github 图床,统一用来存图片的,https://github.com/LetTTGACO/image

创建 Github 图床应该有教程,要开启一些配置才行,我有点忘了你可以搜一下

而且你这有点伪需求

如果你的目的是将图片和本地 doc 都放在 Github,那么就直接下载图片到仓库指定目录,然后流水线上 commit 自动提交 如果你和我一样,将图片统一存在在 B 仓库,那就去网上搜一下 Github 图床创建,然后在 elog.config.js中配置仓库 B 的信息就行

— Reply to this email directly, view it on GitHub, or unsubscribe. You are receiving this because you authored the thread.Message ID: @.***>

xinkeji commented 5 months ago

全是PicGo

---原始邮件--- 发件人: @.> 发送时间: 2024年1月23日(周二) 凌晨0:10 收件人: @.>; 抄送: @.**@.>; 主题: Re: [LetTTGACO/elog] github图床问题 (Issue #63)

主要写别的他也没法用? 我的就可以啊,在 A 仓库运行流水线,将图片存放在 B 仓库 这是我的 Github 图床,统一用来存图片的,https://github.com/LetTTGACO/image

创建 Github 图床应该有教程,要开启一些配置才行,我有点忘了你可以搜一下

而且你这有点伪需求

如果你的目的是将图片和本地 doc 都放在 Github,那么就直接下载图片到仓库指定目录,然后流水线上 commit 自动提交 如果你和我一样,将图片统一存在在 B 仓库,那就去网上搜一下 Github 图床创建,然后在 elog.config.js中配置仓库 B 的信息就行

— Reply to this email directly, view it on GitHub, or unsubscribe. You are receiving this because you authored the thread.Message ID: @.***>

LetTTGACO commented 5 months ago

对 picgo 是可以上传图片到 Github 图床的,你先在 picgo 上测试 Github 图床成功了再试试同步文档

xinkeji commented 5 months ago

嗷嗷好的谢谢

---原始邮件--- 发件人: @.> 发送时间: 2024年1月23日(周二) 凌晨0:15 收件人: @.>; 抄送: @.**@.>; 主题: Re: [LetTTGACO/elog] github图床问题 (Issue #63)

对 picgo 是可以上传图片到 Github 图床的,你先在 picgo 上测试 Github 图床成功了再试试同步文档

— Reply to this email directly, view it on GitHub, or unsubscribe. You are receiving this because you authored the thread.Message ID: @.***>

xinkeji commented 5 months ago

我试试

---原始邮件--- 发件人: @.> 发送时间: 2024年1月23日(周二) 凌晨0:15 收件人: @.>; 抄送: @.**@.>; 主题: Re: [LetTTGACO/elog] github图床问题 (Issue #63)

对 picgo 是可以上传图片到 Github 图床的,你先在 picgo 上测试 Github 图床成功了再试试同步文档

— Reply to this email directly, view it on GitHub, or unsubscribe. You are receiving this because you authored the thread.Message ID: @.***>

LetTTGACO commented 5 months ago

问题解决了吗?如果已解决麻烦关一下此 issue