当前位置:   article > 正文

git错误pathspec did not match any file(s) known to git及相关操作_error: pathspec 'update' did not match any file(s)

error: pathspec 'update' did not match any file(s) known to git

git error: pathspec  did not match any file(s) known to git

本地文件与远程无对应:我这里的情况是在执行./update_nrp update --all

  1. git pull
  2. Already up to date.
  3. git fetch
  4. git branch -a
  5. * master
  6. remotes/origin/HEAD -> origin/development
  7. remotes/origin/IBA1
  8. remotes/origin/NRPJP-11
  9. remotes/origin/NRRPLT-6627_single_activity_log_file
  10. remotes/origin/NRRPLT-6751-2
  11. remotes/origin/NRRPLT-6823
  12. remotes/origin/NRRPLT-6828_fine-tune
  13. remotes/origin/NRRPLT-6948-update-nest-to-2.16
  14. remotes/origin/NRRPLT-6970-update-gzbridge-18
  15. remotes/origin/NRRPLT-7082-spinnaker-install-script
  16. remotes/origin/NRRPLT-7082-spinnaker-install-userscript
  17. remotes/origin/NRRPLT-7290
  18. remotes/origin/NRRPLT-7440
  19. remotes/origin/NRRPLT-7492
  20. remotes/origin/NRRPLT-7911-refactor-parsing-and-process
  21. remotes/origin/NRRPLT-7968
  22. remotes/origin/debug
  23. remotes/origin/dev_nrp4
  24. remotes/origin/development
  25. remotes/origin/fix-generatelowrespbr
  26. remotes/origin/gazebo_ros_pkgs_fix
  27. remotes/origin/master

git fetch

git branch -a 可以查看远程所有的分支

git branch 可以查看本地所有的分支

* (HEAD detached at origin/master)
  development
  master

git branch -d master 可以删除本地分支

git checkout -b master 创建新分支

git pull

Please specify which branch you want to merge with.
See git-pull(1) for details.

    git pull <remote> <branch>

If you wish to set tracking information for this branch you can do so with:

    git branch --set-upstream-to=origin/<branch> master2

 git branch -u origin/master master创建远程分支到本地分支的连接

声明:本文内容由网友自发贡献,版权归原作者所有,本站不承担相应法律责任。如您发现有侵权的内容,请联系我们。转载请注明出处:【wpsshop博客】
推荐阅读
相关标签
  

闽ICP备14008679号