问题
I've setup a new Repo for Android source code, and after executing the repo sync, there are no files in the repo directory. Did I miss something?
I used:
repo init -u git://android.git.kernel.org/platform/manifest.git
repo initialized in /home/tarandeep/code/Android
repo sync
... It downloaded GBs of data (I can confirm via network monitor) and then nothing appeared in the Android directory.
回答1:
It's a git repo in a hidden directory, .git
. "Hidden" just means it starts with a period.
When in doubt, you can use ls -a
or ls -al
(vertical) to see hidden directories.
However, you will generally interact with the repository using git
commands, repo
commands wrapping git
, or a GUI equivalent.
回答2:
I experienced this. Somehow I had configured repo incorrectly and it was depositing the source into my home directory rather than my working directory. I blew away all the .repo* directories/files in my home directory, then re-ran repo init
and repo sync
in the working directory. All was well after that.
回答3:
You should select a branch using the -b
option to repo init
, rather than just syncing everything. Then you will see the files show up properly.
For example:
repo init -u https://android.googlesource.com/platform/manifest -b android-4.0.1_r1
回答4:
Just go to /home/tarandeep/code/Android (that is where you downloaded the repo) and hit CTRL+H. You will now find a folder named ".repo". This is your downloaded data.
回答5:
I meet the same problem. As far as I know, unless repo sync
download all files success, the git will not check out projects. In my case, repo sync
failed due to some reason. So I got nothing except a hided .repo
directory after running repo sync
.
Here are some known issues. https://source.android.com/source/known-issues.html
Hope it helps you.
来源:https://stackoverflow.com/questions/4506024/after-repo-sync-there-are-no-files-in-the-directory