[
https://issues.apache.org/jira/browse/SCM-422?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=17964601#comment-17964601
]
Olivier Lamy commented on SCM-422:
----------------------------------
This project has moved from Jira to GitHub Issues. This issue was migrated to
[apache/maven-scm#639|https://github.com/apache/maven-scm/issues/639].
> Error editing a Starteam file
> -----------------------------
>
> Key: SCM-422
> URL: https://issues.apache.org/jira/browse/SCM-422
> Project: Maven SCM (Moved to GitHub Issues)
> Issue Type: Bug
> Components: maven-scm-provider-starteam
> Affects Versions: 1.1
> Environment: Maven 2.0.9, Windows XP, jre 1.5, Borland Starteam 2008
> Reporter: Ausiàs Armesto
> Priority: Major
> Attachments: starteam-edit-patch.txt, starteam-edit-patch2.txt
>
>
> Hello,
> I am trying to use the maven-release-plugin against the Borland Starteam SCM
> provider and during the execution of release:prepare the goal throws an
> errror because it maven-release-plugin has no access to edit pom file. Here I
> show you the message error.
> [INFO] [release:prepare]
> [INFO] Resuming release from phase 'rewrite-poms-for-release'
> [INFO] Transforming 'Project Example'...
> [INFO] Working directory:
> C:\StarteamServer\StarteamProject\StarteamView\ProjectExample
> [INFO] Command line: stcmd lck -x -nologo -stop -p
> user@StarteamServer:StarteamPort/StarteamProject/StarteamProject/ProjectExample
> -fp C:\StarteamServer\StarteamProject\StarteamView\ProjectExample -l pom.xml
> [WARNING] Unknown edit ouput: Folder: SRRU (working directory:
> C:\StarteamServer\StarteamProject\StarteamView\ProjectExample)
> [WARNING] Unknown edit ouput: pom.xml: Locked
> [INFO]
> ------------------------------------------------------------------------
> [ERROR] BUILD ERROR
> [INFO]
> ------------------------------------------------------------------------
> [INFO] Error writing POM: C:\IS\ISEJEMPLO\DYC\ispob\SRRU\pom.xml (Acces
> denied)
> [INFO]
> ------------------------------------------------------------------------
> [INFO] For more information, run Maven with the -e switch
> [INFO]
> ------------------------------------------------------------------------
> [INFO] Total time: 11 seconds
> [INFO] Finished at: Mon Oct 20 13:50:30 CEST 2008
> [INFO] Final Memory: 7M/14M
> [INFO]
> ------------------------------------------------------------------------
> I have realized that the maven-release-plugin uses the following starteam
> command:
> stcmd lck -x -nologo -stop -p
> user:password@StarteamServer:StarteamPort/StarteamProject/StarteamProject/ProjectExample
> -fp C:\StarteamServer\StarteamProject\StarteamView\ProjectExample -l pom.xml
> This command doesn't work if the Starteam project has checked the policy :
> "Mark unlocked working files read-only". This policy makes any file checked
> out as a read-only file in the working directory. An when a lock operation is
> performed changes the flag to allow writing to it. When a unlock operation is
> perform changes again the flag to restrict the read-only access.
> The correction to the command is just add to the end the argument "-rw" as is
> shown below:
> stcmd lck -x -nologo -stop -p
> user:password@StarteamServer:StarteamPort/StarteamProject/StarteamProject/ProjectExample
> -fp C:\StarteamServer\StarteamProject\StarteamView\ProjectExample -l -rw
> pom.xml
> Here I provide the patch for the StarteamEditCommand.java and the fix for the
> test case
> Do you want me to provide also the patch for the StarteamUnEditCommand.java?
--
This message was sent by Atlassian Jira
(v8.20.10#820010)