美文网首页
repo init报错

repo init报错

作者: 技术笔记 | 来源:发表于2021-08-17 10:38 被阅读0次
    $ repo init -u url
    warning: Python 3 support is currently experimental. YMMV.
    Please use Python 2.6 - 2.7 instead.
    Traceback (most recent call last):
      File "/usr/bin/repo", line 886, in <module>
        main(sys.argv[1:])
      File "/usr/bin/repo", line 854, in main
        _Init(args, gitc_init=(cmd == 'gitc-init'))
      File "/usr/bin/repo", line 340, in _Init
        _CheckGitVersion()
      File "/usr/bin/repo", line 394, in _CheckGitVersion
        ver_act = ParseGitVersion(ver_str)
      File "/usr/bin/repo", line 364, in ParseGitVersion
        if not ver_str.startswith('git version '):
    TypeError: startswith first arg must be bytes or a tuple of bytes, not str
    

    修改repo文件就可以:
    $ sudo vi /usr/bin/repo
    修改
    #!/usr/bin/python#!/usr/bin/python2即可。

    相关文章

      网友评论

          本文标题:repo init报错

          本文链接:https://www.haomeiwen.com/subject/xmbbbltx.html