我试图通过删除我的meteor应用程序的整个目录来查找编译时错误(请参阅meteor compilation - error output doesn't show where is the error?)。
所以我尝试删除(客户端)和(服务器)目录,以了解错误的位置:
$meteor
=> compile time mistake
$rm -rf ./client/*
$meteor
=> compile time mistake
$rm -rf ./server/*
$meteor
=> compile time mistake
$rm -rf ./api/*
$meteor
=> compile time mistake
一旦我发现api上的错误,我试图再次推销我的最后一次提交,但文件不会回来!
$ git branch
erreur
* extra_erreur
master
$ git checkout extra_erreur
D client/cb.html
D client/cb.js
D client/choix_page.html
D client/choix_page.js
D client/hello.html
D client/hello.js
D client/home.html
D client/home.js
D client/ligne_produit.html
D client/ligne_produit.js
D client/main.css
D client/main.html
D client/main.js
D client/menu.html
D client/menu.js
D client/navbar.html
D client/navbar.js
D client/restaurants.html
D client/restaurants.js
D client/subscribe.html
D client/subscribe.js
D client/templates.html
Already on 'extra_erreur'
$ cd client/
$ ls
$
我必须回到(主人),然后回到(额外的错误)让他们回来: - /
$ git checkout master
D client/choix_page.html
D client/choix_page.js
D client/hello.html
D client/hello.js
D client/home.html
D client/home.js
D client/main.css
D client/main.html
D client/templates.html
Switched to branch 'master'
Your branch is ahead of 'dorj/master' by 3 commits.
(use "git push" to publish your local commits)
$ git checkout extra_erreur
D client/choix_page.html
D client/choix_page.js
D client/hello.html
D client/hello.js
D client/home.html
D client/home.js
D client/main.css
D client/main.html
D client/templates.html
Switched to branch 'extra_erreur'
$ ls
client common imports node_modules package.json server
$ cd client/
$ ls
cb.html ligne_produit.html main.js menu.js navbar.js restaurants.js subscribe.js
cb.js ligne_produit.js menu.html navbar.html restaurants.html subscribe.html
我不明白:-( 什么是' D'意思是什么?
答案 0 :(得分:1)
git checkout -- client server api
或
git checkout -- .
所有内容
Git可能非常令人困惑,其命令的工作方式和参数可能不一致。话虽如此,我确定在帮助页面和谷歌搜索之间,我相信你可以自己想出来。