[
https://jira.codehaus.org/browse/SCM-709?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=325248#comment-325248
]
Michael Koch commented on SCM-709:
----------------------------------
I just found out that {{URI.create}} generally does not work as intended
because it does not create a {{file:}} URL. Therefore
{{URI.create( stdout.getOutput().trim() ).relativize(
fileSet.getBasedir().toURI() )}}
does not create a relative URL and the {{git status}} command fails. You can
test this if in {{GitStatusCommandTest.testResolvePath()}} you change
{{URI path = repositoryRoot.toURI().relativize( workingDirectory.toURI() );}}
to
{{URI path =
URI.create(repositoryRoot.getAbsolutePath()).relativize(workingDirectory.toURI());}}.
> REGRESSION: git status doesn't work if repository root is not the working
> directory
> -----------------------------------------------------------------------------------
>
> Key: SCM-709
> URL: https://jira.codehaus.org/browse/SCM-709
> Project: Maven SCM
> Issue Type: Bug
> Components: maven-scm-provider-git
> Affects Versions: 1.8, 1.8.1
> Reporter: Robert Scholte
> Assignee: Robert Scholte
> Priority: Blocker
> Attachments:
> 0001-use-new-File-.toURI-to-fix-handling-of-paths-with-sp.patch
>
>
> SCM-686 introduced the {{--porcelain}} option to make the {{status}} result
> language independend.
> Without the {{--porcelain}} option files were listed relative to the working
> directory, but with {{--porcelain}} files are listed relative to the
> repository root. In most cases these are the same, but not always.
--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators
For more information on JIRA, see: http://www.atlassian.com/software/jira