Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Bitbucket with android :"Can't publish part of repository" error

I have recently use Android studio and I was just try to connect bitbucket with it. I don't want manually bitbucket by terminal thas why I googling it. find some links link . I have follow all the steps install plugin>shareproject>login>private>share project

and than error. I checked my bitbucket but no repositary created.

Can't publish part of repository

Invalid VCS root mapping The directory ExpandableLayout-master\TestProject is registered as a Git root, but no Git repositories

I don't know is thare error of plugins of bit bucket or my android studio

like image 611
Vishal Patel Avatar asked Nov 04 '15 07:11

Vishal Patel


People also ask

How do I clone a repository from Bitbucket to Android studio?

You can try below steps to clone a bitbucket repo: VCS -> Git -> clone -> paste bitbucket URL repo -> clone. It can clone successfully. Save this answer.


3 Answers

I have the same problem with android studio. this is my suggested solution:

go to project root folder then open a terminal in this folder:

  1. git init
  2. git add --all
  3. git commit -m "your message"

then go to bitbucket and create new repository then choose "I have an existing project" ...

Now you can use plugin to push/update

like image 99
yalive Avatar answered Oct 03 '22 06:10

yalive


After to much research... finally i got answer Actually it is bug of bit-bucket plugin. bit-bucket bug

Here is solution given by AKAMUZA in above link thanks bro.

(1)Go to project folder and delete .git folder

(2) IDEA pops up an error message about project not being under version control and an option to configure it. Press Configure and just delete the path to your project in VCS section.

(3)After this Import into version control -> Share project works like a charm.

UPDATE

I Found many developer having issue after use plugin directly from Android studio and if It not work you can download below plugin

  1. https://bitbucket.org/dmitry_cherkas/jetbrains-bitbucket-connector/downloads/jetbrains-bitbucket-connector_IC-139.224.zip
  2. Go to Setting-> Plugin-> Install plugin From disk ->above downloaded plugin -> install & resatart.
  3. You can feel Magic after restart :P
like image 27
Vishal Patel Avatar answered Oct 03 '22 07:10

Vishal Patel


This thread mentions (assuming that File > Settings > Version Control is set to "git"):

You could instead have navigated into the directory via a terminal or shell and typed 'git init'. That would have converted that directory into a git repository.

So check if ExpandableLayout-master\TestProject has or has not yet a .git subfolder in it.
If not, it means you have declared that path as a git repo, but locally, on your disk, that folder is not yet a git repo. If so, you can initialize it, add a remote pointing to an empty bitbucket repo and push.

like image 23
VonC Avatar answered Oct 03 '22 07:10

VonC