V2EX = way to explore
V2EX 是一个关于分享和探索的地方
现在注册
已注册用户请  登录
V2EX 提问指南
xjtlujoe
V2EX  ›  问与答

hexo d 的问题。。。折磨好几天了。。

  •  
  •   xjtlujoe · 2016-07-01 14:35:55 +08:00 · 17833 次点击
    这是一个创建于 2849 天前的主题,其中的信息可能已经有所发展或是发生改变。

    按照官网的 deployment 的流程,走到 hexo d 的时候死活不行。。。网上查了很多资料,还是不行。

    win 的环境,配置了_config.yml 文件之后, hexo g, hexo d..

    delete mode 100644 placeholder
    warning: LF will be replaced by CRLF in js/script.js.
    The file will have its original line endings in your working directory.
    bash: /dev/tty: No such device or address
    error: failed to execute prompt script (exit code 1)
    fatal: could not read Username for 'https://github.com': Invalid argument
    FATAL Something's wrong. Maybe you can find the solution here: http://hexo.io/do                                                        cs/troubleshooting.html
    Error: bash: /dev/tty: No such device or address
    error: failed to execute prompt script (exit code 1)
    fatal: could not read Username for 'https://github.com': Invalid argument
    
    
    17 条回复    2018-12-21 14:56:06 +08:00
    DoraJDJ
        1
    DoraJDJ  
       2016-07-01 14:37:45 +08:00
    ```
    fatal: could not read Username for 'https://github.com': Invalid argument
    ```

    确定 GitHub 的用户名设定正确了吗
    sophymax
        2
    sophymax  
       2016-07-01 14:41:29 +08:00
    配置不好就直接把那个目录 git 提交就可以了 , 没必要花时间在它上边
    xjtlujoe
        3
    xjtlujoe  
    OP
       2016-07-01 14:44:10 +08:00
    @sophymax 就想知道 hexo d 的问题。。
    kokutou
        4
    kokutou  
       2016-07-01 14:51:31 +08:00
    _config.yml 为啥不贴出来。
    xjtlujoe
        5
    xjtlujoe  
    OP
       2016-07-01 15:04:14 +08:00
    DoraJDJ
        6
    DoraJDJ  
       2016-07-01 15:09:41 +08:00
    @xjtlujoe 应该是没设置用户名,所以提交不上去。
    popu111
        7
    popu111  
       2016-07-01 15:14:35 +08:00
    可以试试 [email protected] ,以及我记得我用 cygwin 就会出错,用 cmd 就啥事没有
    dixyes
        8
    dixyes  
       2016-07-01 15:22:54 +08:00 via Android   ❤️ 1
    或许你该试试到.deploy_git 目录手动 push 下试试 看看 git 提示啥错误
    dixyes
        9
    dixyes  
       2016-07-01 15:24:20 +08:00 via Android
    顺便 你该提及下你的 shell 是啥 bash 一直找不到 tty
    xjtlujoe
        10
    xjtlujoe  
    OP
       2016-07-01 15:39:37 +08:00
    @dixyes git bash ,貌似就是 cygwin 的问题。。还是不搞 win 下的了。。。麻烦。。
    dixyes
        11
    dixyes  
       2016-07-01 15:45:23 +08:00 via Android
    @xjtlujoe 还是 msys2 好 我的 hexo 没碰到啥问题(用的自己架的服务器 sshgit
    helloit
        12
    helloit  
       2016-07-01 17:57:53 +08:00
    要这样写:
    ------------------------------------------------------------------------
    deploy:
    type: git
    repo: [email protected]:username/username.github.io.git
    ------------------------------------------------------------------------
    Eugene1024
        13
    Eugene1024  
       2016-09-10 09:44:42 +08:00
    遇到相同的问题,还是没有解决 、、、
    xjtlujoe
        14
    xjtlujoe  
    OP
       2016-09-10 15:26:59 +08:00
    @Eugene1024 把用户名和邮箱都写在 deploy 就行了, win 下我是这么弄的
    springsummer
        15
    springsummer  
       2017-03-11 02:20:53 +08:00   ❤️ 1
    type : git
    repo : xxx
    冒号后面一定要两个空格!!!!
    ByteChen
        16
    ByteChen  
       2018-03-25 11:19:58 +08:00
    @springsummer 老哥,稳!完美解决问题!
    EdisonR
        17
    EdisonR  
       2018-12-21 14:56:06 +08:00
    @springsummer 老哥!稳
    关于   ·   帮助文档   ·   博客   ·   API   ·   FAQ   ·   我们的愿景   ·   实用小工具   ·   3115 人在线   最高记录 6543   ·     Select Language
    创意工作者们的社区
    World is powered by solitude
    VERSION: 3.9.8.5 · 34ms · UTC 10:56 · PVG 18:56 · LAX 03:56 · JFK 06:56
    Developed with CodeLauncher
    ♥ Do have faith in what you're doing.