When I import project to Android Studio, I found this errors:
Error:No resource found that matches the given name (at ‘label’ with value ‘@string/filter_title_awesomeChat’).
Error:No resource found that matches the given name (at ‘label’ with value ‘@string/filter_title_awesomeChat’).
Error:Execution failed for task ‘:app:processFreeReleaseResources’.
com.android.ide.common.process.ProcessException: Failed to execute aaptInvalid VCS root mapping
The directory C:UsersalfayedDesktopawesome-chat is registered as a Git root, but no Git repositories were found there.
Screenshot of errors
halfer
19.8k17 gold badges98 silver badges185 bronze badges
asked Sep 20, 2017 at 0:50
For the Invalid VCS root mapping error you can fix it by deleting the vcs.xml
file located in the .idea
folder of your project and then rebuild your project.
AlexV
22.6k17 gold badges84 silver badges122 bronze badges
answered Apr 7, 2019 at 14:45
daisymber18daisymber18
1,1412 gold badges7 silver badges3 bronze badges
3
For the Invalid VCS root mapping
error, you can fix it by deleting the vcs.xml
file located in the .idea
folder of your project and then Reopen your IDE.
answered Nov 25, 2019 at 5:11
ManideepManideep
3553 silver badges13 bronze badges
Make sure the project was cloned and not downloaded as a zip into the directory you are using (there should be C:UserspaulaGitOpenTripPlanner.git directory on your disk).
and make sure your gpath to git executable is indicating the correct path.
answered Mar 30, 2018 at 21:00
Sergio GuerjikSergio Guerjik
4761 gold badge4 silver badges12 bronze badges
0
The three Gradle Build errors seems separate from the invalid VCS root mapping error.
-
For the invalid VCS root mapping error, you can go to the root of the project
C:UsersalfayedDesktopawesome-chat
, and create a git repo bygit init
. -
For the three Gradle Build errors, you can debug the details with the source code.
answered Sep 20, 2017 at 1:24
Marina LiuMarina Liu
36.5k4 gold badges61 silver badges74 bronze badges
1
all you need is to delete the vcs.xml file inside an .idea folder this works!
answered Mar 31, 2020 at 0:36
When you clone your project from git make sure you do:
git clone --recursive YOUR-GIT-URL
or if you have already cloned then to fix it:
git submodule init
git submodule update
answered Sep 17, 2020 at 20:17
DenisDenis
11.7k15 gold badges86 silver badges150 bronze badges
For resolving «Invalid VCS root mapping«
Make sure the project was cloned and not downloaded as a zip into the directory you are using (there should be C:UsersalfayedDesktopawesome-chat.git directory on your disk).
answered Aug 5, 2019 at 7:01
For the Invalid VCS root mapping error, deleting the .idea folder of your project and then rebuild your project.
answered Feb 11, 2020 at 5:20
altin banaaltin bana
1011 silver badge12 bronze badges
Remove Existing Directory Mapping by following File -> Setting -> Version Control -> Directory Mappings and then click «-«.
Make Project
answered Apr 19 at 5:52
taran mahaltaran mahal
1,05812 silver badges11 bronze badges
Загрузка…
testomat.io управление авто тестами
- Python
- Реклама
- Работа
- Консультации
- Обучение
This tutorial guides you on how to fix Invalid VCS root mapping android studio project error that you are facing while opening ionic project in android studio.
Basically, I just downloaded an healthcare.zip project and wanted to run the application in android studio (android device).
I had setup nodejs and ionic to run the application in browser. After setting up and running the application in browser wanted to try to run the app in android studio.
To run the application in android studio, I had followed the below steps.
> npm i > ionic build > npx cap add android > npx cap sync android > npx cap open android
The last npx command npx cap open android will open the android studio software with current running project. Running that command opened the android studio software with current project, but it resulted in following error “Invalid VCS root mapping… registered as a Git root, but no Git repositories were found there” as shown below.
Invalid VCS root mapping The directory C:Users…entssneppetshealthcare is registered as a Git root, but no Git repositories were found there.
Fix Invalid VCS root mapping error
For my scenario, I did not clone the project from Git instead downloaded the project zip and trying to run the app.
If Git is installed in your machine and if you had cloned the project repo from Github, then the project directory will have .git repositories. Therefore the Git repositories were missing since it is not cloned from Git.
To fix Invalid VCS root mapping error, try to locate file called vcs.xml. You could find that file in the following path.
<PROJECT_DIRECTORY>/android/.idea/vcs.xml
If you check that vcs.xml file, it contains some info/ path related to Git which was not found on your machine.
Therefore, first I closed the android studio and tried renaming that file to vcss.xml and ran the command npx cap open android again. This workaround worked for me and I did not see the error again.
Note, I did not delete any folder or file, I just renamed the vcs.xml. But there are other recommendations to delete vcs.xml file or .idea folder itself. But I would recommend to take backup before you try any of these.
That’s it. Hope it helped 🙂
- How to Set Windows PowerShell Environment Variables
- Visual Studio Code install location and Path issues from Terminal
- npm ERR! enoent – This is related to npm not being able to find a file
- spawn git ENOENT npm error
- Git – How to compare files in two different branches
- GitHub unable to access HTTPS and SSL routines error
- ‘ionic’ is not recognized as an internal or external command
- Unable to connect to the server: dial tcp i/o timeout
References:
- nodejs
- npm docs
- developer android
“VCS root mapping” refers to the way a Version Control System (VCS) like Git, Subversion, or Mercurial maps files in a repository to a local directory structure on a developer’s machine.
An “invalid VCS root mapping” error typically occurs when the mapping between the repository and the local directory structure is incorrect or missing.
Here are some possible causes and solutions:
- Incorrect VCS root mapping: Check that the VCS root mapping in your IDE or build system matches the directory structure of your repository. If you have moved or renamed files or directories, update the mapping accordingly.
- Missing VCS root mapping: If you’re setting up a new project, make sure to configure the VCS root mapping correctly in your IDE or build system.
- Incorrect version control system: Make sure you’re using the correct VCS for your repository. For example, if your repository is using Git, make sure your IDE or build system is also using Git.
- Access issues: Ensure that you have proper access to the repository, and that you have permission to read and write files.
We are developing an SDK which will be rolled out to our clients, as well as several apps which will use the SDK. In order to develop the SDK, its easiest to have a master project — such as a test app which has the SDK included as a module. This allows it the source to be available during debugging and is much easier to make bug fixes to the SDK.
My expectation was that when using Android Studio to create a «New Project from Version Control» (file menu) that the submodules specified in .gitmodules
would be cloned also, however this is not the default behavior. When performing this action on a repo with .gitmodules
, and the settings.gradle
has an include
statement for the module (makes sense right?), AS displays an error of a VCS root with no source. «Is registered as git root, but no git repositories were found there»
- Is there a reason why it shouldn’t be the default behavior? Is this a git thing?
- If I want to update this behavior, is this a git alias thing (suggested here) or is there an Android Studio config to make it use something like
git clone --recursive
?
My goal is to reduce friction for new developers on my team. I am considering just using SourceTree (which automatically clones submodules) or writing the git commands required as a reference, however I prefer when things work as expected via the IDE.
The environment is Android Studio 1.5.1 & git 1.9.X — both windows 7 and OSX.