GitHub repo clone empty - android

I tried to clone a private repo from GitHub to Android Studio using "Check out Project from Version Control" The cloning works. However, after cloning, the Android directory is empty. I couldn't find any Java files in the Project directory either:

This is a known problem with the IDE.
How to fix it?
Close the project.
Delete the .idea folder
Open the studio again
Create new project from existing source - your project path
And thats it :-)

Related

invalid root mapping github project

invalid root mapping androd
i have download a project from github and open it in Android Studio it showing following error see image..
Check weather in the folder there is an hidden folder named .git that is supposed to contain the git information. If it's not there that is the problem.
Anyway other then that you could probably try to save as backup the current directory and clone it again in a new folder so that you can check if everything is the same.
If you have git in your shell (and I suppose you do since you are on linux) it's really easy, just try something like:
git clone repo_url
Says that the project android studio go configurations are incompatible. Either try to use the project with the git clone option, or delete the hidden .git extension.
The error happens because Android Studio found a remnant of git (something like .gitignore) in the project directory but not found any .git folder in the project. So it complaining that the project is supposed having a .git and giving an optional to create and set the root directory as a project with git. Other then that, you can work with the project without any problems.
When you downloading the project from the github via clone or download -> download ZIP, you will losing all the git files of the project. So you losing all the history of the project which is in the git. Instead download ZIP, you can clone the project with:
git clone remote_project_file
When you clone your project from git make sure you do (forgetting the recursive flag usually causes the vcs root mapping problem):
git clone --recursive YOUR-GIT-URL
or if you have already cloned then to fix it:
git submodule init
git submodule update

Trash pushed by git in Android Studio

I'd like to know what is that trash that was pushed by Android Studio to bitbucket. Those files and directories don't even exist in a project directory. What are they and how can I get rid of them. BitBucketScreenshot
.gitignore? If so, why again project directory doesn't contain any of these?
Greetings.
Problem is solved. By accident I have setup IDE settings remote repo the same as project one.

cloning project from Git in Android Studio

I'm using Android Studio 2, after migrating from Eclipse I pushed the project to a new repository. Now when I try to clone it ,it doesn't work.
After cloning it asks me :
Would you like to create a Studio project for the sources you have checked out to ?
I hit 'yes' and then "Import project from external model".
I can see then the project but I can't run it. I can't even sync with gradle files. This option is not existent.
Here is the official documentation to migrate an Eclipse project to an Android Studio: Migrating from Eclipse ADT. You should follow the step if you want your project to be usable under Android Studio since the project structure is a bit different betwwen the two environment.
You have to mantein this structure, with .idea and app directories directly in the root folder of your project, without any other wrapping folder.

Android Studio and Github missing .iml files

I'm using Android Studio version 1.5.1 and we have a problem when cloning and working with Github.
In my gitignore file I got a text saying *.iml, as I understand this means that all my iml files are ignored by git and not uploaded. When my project collaborators are cloning my project, they get a error message telling them that there is 2 missing iml files. They are asked to either keep or remove them. It doesn't matter which they do beacuse it still gives the same problem. They cannot code or build anything.
As I understand the iml files should not be uploaded to github but instead Android Studio should automaticly generate them when it is building or importing a project.
What have we done wrong?
After cloning the repo, you should re-open the project with
File -> Open
and select your project you've just clone and android studio will re-build, re-index and re-create the .iml file :)

Can't run or debug SVN android project

I'm having some beginner problems to start using version control on my project. My app is already working, I've installed subversive and did the following:
1- Checked out my project to server - OK.
2- At another pc, added new repository location - OK.
I can see the project tree in SVN Repositories perspective, with all files, but when I try to run it, what appears in the emulator is the local version of the project, and not the SVN one.
I've tried Run > Run Configurations > New Launch Configurations, but the SVN repository doesn't appears in Basic settings > Browse Project...
In repository I can see, but not edit, .classpath and .project files.
Any idea of what's happening? Thanks.
You should be downloading your project from SVN into a folder somewhere on your PC. You need to add that project to Eclipse, or refresh if you downloaded it to an existing project folder, and then rebuild the project in Eclipse.

Categories

Resources