账号密码登录
微信安全登录
微信扫描二维码登录

登录后绑定QQ、微信即可实现信息互通

手机验证码登录
找回密码返回
邮箱找回 手机找回
注册账号返回
其他登录方式
分享
  • 收藏
    X
    hexo博客,hexo d时,需要提交密码,我输入服务器root密码不对,且服务器已做免密登陆。
    83
    0

    报错信息:

    fatal: 无法读取远程仓库。

    请确认您有正确的访问权限并且仓库存在。
    FATAL Something's wrong. Maybe you can find the solution here: https://hexo.io/docs/troubles...
    Error: Spawn failed

    at ChildProcess.<anonymous> (/Users/username/Sync/hexo/node_modules/hexo-util/lib/spawn.js:51:21)
    at ChildProcess.emit (events.js:321:20)
    at Process.ChildProcess._handle.onexit (internal/child_process.js:275:12)

    FAIL: 2

    配置信息

    deploy:
    type: 'git'
    repo: git@155.94.1xx.1xx:/data/www/hexo
    branch: master

    0
    打赏
    收藏
    点击回答
        全部回答
    • 0
    • じ☆ve谁 普通会员 1楼

      如果你的hexo博客在hexo d命令中输入的密码不对,并且你的服务器已经设置了免密登陆,那么你应该检查你的 hexo 的配置文件(例如:config.yml)并确保你的密码正确。

      如果你使用的是 Hexo 3.0 及以上版本,你可以在 hexo 3.0.13 中添加以下配置:

      yaml theme: hexo baseurl: . publicpath: /public

      这里的 publicpath 设置为 '/public',这是你的hexo博客的根目录。这样,你就可以通过在服务器上访问根目录(例如:http://localhost:4000)来访问你的hexo博客了。

      如果你使用的是 Hexo 2.9 及以下版本,你可以在 hexo 2.9.10 中添加以下配置:

      yaml theme: hexo baseurl: . publicpath: /public

      这里的 publicpath 设置为 '/public',这是你的hexo博客的根目录。这样,你就可以通过在服务器上访问根目录(例如:http://localhost:4000)来访问你的hexo博客了。

      如果你的 hexo博客没有使用 publicpath 设置,你需要在 hexo d 中使用目录模式来访问你的博客。例如,你可以使用以下命令来访问你的博客:

      bash hexo d -m "访问 hexo blog"

      这里的 -m 是指使用目录模式,它会将你的博客地址重定向到当前目录下。

    更多回答
    扫一扫访问手机版
    • 回到顶部
    • 回到顶部