Jump to content

Mikael Kalms

Members
  • Content Count

    96
  • Joined

  • Last visited

  • Days Won

    10

Mikael Kalms last won the day on March 17 2017

Mikael Kalms had the most liked content!

Community Reputation

1 Neutral

About Mikael Kalms

  • Rank
    Advanced Member

Recent Profile Visitors

The recent visitors block is disabled and is not being shown to other users.

  1. I am using Jenkins v2.152, Plastic plugin v2.20. I'll let you know if I find a repro case sometime in the future.
  2. I have attempted to create a minimal repro case, but there I was able to use PLASTICSCM_CHANGESET_ID from the start.
  3. I was able to trigger this error several times in succession. Apparently the problem went away if I waited a few minutes and triggered the same build again. It has something to do with how that 'cm find changeset' operation uses a particular time interval to know which changes are of interest.
  4. Repro steps: 1. Create a new, empty repository. 2. Add the following file to the repository with the name Jenkinsfile, and check it in: pipeline { agent any stages { stage ('Fetch PLASTICSCM_CHANGESET_ID') { steps { echo "Change set ID: ${PLASTICSCM_CHANGESET_ID}" } } } } 3. Create a new Pipeline job in Jenkins. Set it to be of type "Pipeline script from SCM". Point it to your repository. 4. Tell Jenkins to build the job once. This is the resulting error message: Started by user admin Obtained Jenkinsfile from repository "ChangeSetIdTest@local" path "/" smartbranch "/main" Running in Durability level: MAX_SURVIVABILITY [Pipeline] node Running on Jenkins in C:\Program Files (x86)\Jenkins\workspace\ChangeSetIdTest [Pipeline] { [Pipeline] stage [Pipeline] { (Declarative: Checkout SCM) [Pipeline] checkout [ChangeSetIdTest] $ cm find changeset where date between '2019-02-17T17:07:01' and '2019-02-17T17:08:46' and branch='/main' on repositories 'ChangeSetIdTest@local' --xml --dateformat=yyyy'-'MM'-'dd'T'HH':'mm':'ss <?xml version="1.0" encoding="utf-8" ?> <PLASTICQUERY> <CHANGESET> <ID>6</ID> <CHANGESETID>0</CHANGESETID> <COMMENT>Root dir</COMMENT> <DATE>2019-02-17T17:08:07</DATE> <OWNER>[redacted]</OWNER> <REPOSITORY>ChangeSetIdTest</REPOSITORY> <REPNAME>ChangeSetIdTest</REPNAME> <REPSERVER>local</REPSERVER> <BRANCH>/main</BRANCH> <PARENT>-1</PARENT> <GUID>0497ef04-4c81-4090-8458-649885400c84</GUID> </CHANGESET> <CHANGESET> <ID>16</ID> <CHANGESETID>1</CHANGESETID> <COMMENT>Added jenkinsfile</COMMENT> <DATE>2019-02-17T17:08:40</DATE> <OWNER>[redacted]</OWNER> <REPOSITORY>ChangeSetIdTest</REPOSITORY> <REPNAME>ChangeSetIdTest</REPNAME> <REPSERVER>local</REPSERVER> <BRANCH>/main</BRANCH> <PARENT>0</PARENT> <GUID>f96514d9-4b05-49e5-98c8-5b2fd5751202</GUID> </CHANGESET> </PLASTICQUERY> [ChangeSetIdTest] $ cm gwp "C:\Program Files (x86)\Jenkins\workspace\ChangeSetIdTest" --format={1} C:\Program Files (x86)\Jenkins\workspace\ChangeSetIdTest is not in a workspace. [ChangeSetIdTest] $ cm diff cs:0@ChangeSetIdTest@local --format={path}#@_sep_@#{revid}#@_sep_@#{parentrevid}#@_sep_@#{status} --repositorypaths Can't diff cset cs:0@ChangeSetIdTest@local because it doesn't have a parent. [ChangeSetIdTest] $ cm diff cs:0@ChangeSetIdTest@local --format={path}#@_sep_@#{revid}#@_sep_@#{parentrevid}#@_sep_@#{status} --repositorypaths Can't diff cset cs:0@ChangeSetIdTest@local because it doesn't have a parent. [ChangeSetIdTest] $ cm diff cs:0@ChangeSetIdTest@local --format={path}#@_sep_@#{revid}#@_sep_@#{parentrevid}#@_sep_@#{status} --repositorypaths Can't diff cset cs:0@ChangeSetIdTest@local because it doesn't have a parent. FATAL: The cm command 'cm diff cs:0@ChangeSetIdTest@local --format={path}#@_sep_@#{revid}#@_sep_@#{parentrevid}#@_sep_@#{status} --repositorypaths' failed after 3 retries [Pipeline] } [Pipeline] // stage [Pipeline] } [Pipeline] // node [Pipeline] End of Pipeline ERROR: The cm command 'cm diff cs:0@ChangeSetIdTest@local --format={path}#@_sep_@#{revid}#@_sep_@#{parentrevid}#@_sep_@#{status} --repositorypaths' failed after 3 retries Finished: FAILURE I'm not sure why, but I think that the Jenkins plugin is attempting to find ancestors starting from cset 0, and this operation fails.
  5. I introduced a workaround into my build script, which is a first step that looks like this... First some helper logic: /////////////////////////////////////////////////////////////////////////////////////////////// def scmChangeSetId = null /////////////////////////////////////////////////////////////////////////////////////////////// // Return a string on the format "1234" with latest changeset ID def getSCMChangeSetId() { def cmResult = bat script: "cm status --nochanges ${SOURCE_DIR}", returnStdout: true // Result will be a multiline string like this: // // <blank line> // C:\Jenkins\workspace\PongSP-Windows>cm status --nochanges C:\Jenkins\workspace\PongSP-Windows/PongSP // cs:67@rep:PongSP@repserver:FallDamage@Cloud // Extract the number '67' from the above multiline string def cmResultLines = cmResult.split('\n') assert 3 == cmResultLines.size() echo "cmResult[2]: " + cmResultLines[2] def changeSetId = cmResultLines[2].tokenize(':@')[1] return changeSetId } ... and then a build step, before the others: stage('RetrieveSCMInfo') { steps { timeout(time: "${DEFAULT_STAGE_TIMEOUT_MINUTES}" as int, unit: 'MINUTES') { script { scmChangeSetId = getSCMChangeSetId() } echo "Changeset ID: ${scmChangeSetId}" } } } ... and then I change any remaining build steps to refer to scmChangeSetId instead of PLASTICSCM_CHANGESET_ID. I trigger a build, and 5 minutes later the build progress display looks like this - which means it's good and it's doing what it is supposed to:
  6. Hi, I have recently created two new Jenkins build jobs based off of an existing build job. The existing build job has been working fine for some time, but the two new build jobs fail. What I find is that with the new build jobs, I get the following error: groovy.lang.MissingPropertyException: No such property: PLASTICSCM_CHANGESET_ID for class: groovy.lang.Binding This is strange, and it is causing trouble when we are about to make a major release. I have a workaround, which I will use for the time being -- directly calling `cm status` and using that result instead of he PLASTICSCM_CHANGESET_ID variable. Still, it would be nice if you could find a solution for this long term. The entire project exists in a Plastic repo. The Jenkins build job is a Declarative Pipeline job. The Jenkinsfile is configured to be fetched as "Pipeline script from SCM", with a selector like this: repository "Freedom@FallDamage@Cloud" path "/" smartbranch "/main" (Use update is enabled, Lightweight checkout is enabled) I am not performing any extra checkouts, just relying on what Jenkins automatically does. Now, the step that fails looks like this: // Build 64-bit Windows Standalone player, with Steam activated // Source project location: ${SOURCE_DIR} // Target build location: ${SOURCE_DIR}/SteamBuild/input // Target executable name: ${PROJECT_NAME}.exe stage('Build') { steps { timeout(time: "${BUILD_STAGE_TIMEOUT_MINUTES}" as int, unit: 'MINUTES') { script { failedStage = STAGE_NAME try { bat "if exist ${WORKSPACE}\\UnityEditor.log del ${WORKSPACE}\\UnityEditor.log" bat "START /WAIT \"Unity\" \"${UNITY_INSTALLATION_DIR}/Editor/Unity.exe\"" + " -quit" + " -batchmode" + " -executeMethod CustomBuild.GenerateBuild_CommandLine" + " -BuildInfo.SourceControl.RepositoryServer \"<org>@Cloud\"" + " -BuildInfo.SourceControl.Repository \"${SCM_REPOSITORY_NAME}\"" + " -BuildInfo.SourceControl.ChangeSetId \"${PLASTICSCM_CHANGESET_ID}\"" + " -BuildInfo.BuildJob.Name \"${JOB_NAME}\"" + " -BuildInfo.BuildJob.Id \"#${BUILD_ID}\"" + " -BuildInfo.Configuration \"${CONFIGURATION}\"" + " -BuildInfo.BuildTimeStamp \"${BUILD_TIMESTAMP}\"" + " -CustomBuild.OnlineVersion \"${JOB_NAME}.${PLASTICSCM_CHANGESET_ID}\"" + " -CustomBuild.Configuration \"${CONFIGURATION}\"" + " -CustomBuild.TargetExecutable \"${SOURCE_DIR}/SteamBuild/input/${PROJECT_NAME}.exe\"" + " -projectPath \"${SOURCE_DIR}\"" + " -logFile \"${WORKSPACE}/UnityEditor.log\"" + " && IF ERRORLEVEL 1 EXIT /B 1" } finally { bat "type \"${WORKSPACE}\\UnityEditor.log\"" } } } } } It is the ${PLASTICSCM_CHANGESET_ID} variable reference which Jenkins claims is unassigned. Now, again -- I am using the same exact script, but with 4 environment variables changed, for another build job that is working well. This is what the Stage view looks like. I triggered the build job twice. The first time, the checkout took a long time since it had to pull down the entire repository. The second time, there were no changes to the repo, so checkout was quick. My wild guess: The PlasticSCM plugin does not publish changes or set some environment variables to Jenkins for a particular build job, until that job has run successfully at least once. Let me know if you want a support ticket with more detailed logs, build scripts & screenshots.
  7. Mikael Kalms

    Jenkins Shared Libraries in Plastic SCM

    Correct, I am declaring a Global Shared Library in the settings. Here are the settings that I use (see screenshot, sorry for low resolution, taken on phone). You should be able to repro this by setting up an empty Plastic repo as your Global Shared Library, and another Plastic repo containing a single-line Jenkinsfile: @Library('JenkinsBuildScripts@latest') _ Then you would set up two Jenkins jobs referencing the latter repo. The first to build will be succrssful in downloading the global shared library, the second will not. Let me know if you want a tested example from me. As for 'why not Xlinks' - the global shared libs are more than just sub-repos, there is also a set of Initialization rules associated with loading a library. The Jenkins security boundary is also different between the library and the code using the boundary. For the time being I'll work around these problems by putting the Global Shared Library code into a Git repo.
  8. Mikael Kalms

    Jenkins Shared Libraries in Plastic SCM

    Hi, I am revisiting the shared library situation. The ability to not use multiple workspaces helps (thanks!), but I have run into another blocker: Shared libraries can only be used from one Jenkins project at a time. I haven't dug through the Plastic plugin Java code yet, but I suspect that it is a Plastic plugin <-> Jenkins incompatibility. My guess: 1. Jenkins wants to check out the shared library once for each job that uses it (to folders with names like "<job>@libs/<sharedlibrary>") 2. The Plastic plugin will create a workspace when checking out a repository, regardless of whether it's a job or a shared library that needs to be checked out. 3. The Plastic plugin will use a workspace name on the form "<job>#<node>" or "<sharedlibrary>#<node>" 1+2+3 => If the same shared library is used by two jobs, the Plastic plugin will attempt to use the same workspace name for two different workspaces on the same node. This will not work. I'm not sure how to solve this. If you have enough context in the plugin to know when Jenkins attempts to check out a shared library as part of running a job, you might be able to generate workspace names like "<job>#<sharedlibrary>#<node>". Otherwise, perhaps the answer is to move to encoding a larger part of the raw path into the workspace name? Mikael ------------------------ Repro case: Let's say I have one project with the Shared Library code in. That project is called JenkinsBuildScripts. I have two other projects which will use the Shared Library code. These projects are called JenkinsBuildScripts-Example and JenkinsBuildScripts-Example2. This is the entire Jenkinsfile for each of the example projects: @Library("JenkinsBuildScripts") _ pipeline { agent { label 'master' } stages { stage('Example stage') { steps { echo "Stage is running" } } } } So far, nothing strange. Now, when I run the job for JenkinsBuildScripts-Example I get the output below. Plastic will locate the JenkinsBuildScripts workspace (creating a new one if it does not exist), refresh that, then proceed to building stuff, and all is good: Started by timer Obtained Jenkinsfile.groovy from repository "JenkinsBuildScripts-Example@<organization redacted>@cloud" path "/" smartbranch "/main" Running in Durability level: MAX_SURVIVABILITY Loading library JenkinsBuildScripts@latest [JenkinsBuildScripts] $ cm find changeset where date between '2018-12-23T14:03:00' and '2018-12-23T14:05:00' and branch='/main' on repositories 'JenkinsBuildScripts@<organization redacted>@Cloud' --xml --dateformat=yyyy'-'MM'-'dd'T'HH':'mm':'ss <?xml version="1.0" encoding="utf-8" ?> <PLASTICQUERY> </PLASTICQUERY> [JenkinsBuildScripts] $ cm gwp /var/lib/jenkins/workspace/JenkinsBuildScripts-Example@libs/JenkinsBuildScripts --format={1} /var/lib/jenkins/workspace/JenkinsBuildScripts-Example@libs/JenkinsBuildScripts [JenkinsBuildScripts] $ cm lwk --format={0}#{1}#{2} ... JenkinsBuildScripts#master#/var/lib/jenkins/workspace/JenkinsBuildScripts-Example@libs/JenkinsBuildScripts JenkinsBuildScripts-Example#master#/var/lib/jenkins/workspace/JenkinsBuildScripts-Example ... [JenkinsBuildScripts] $ cm unco --all /var/lib/jenkins/workspace/JenkinsBuildScripts-Example@libs/JenkinsBuildScripts [JenkinsBuildScripts] $ cm ss wk:JenkinsBuildScripts Selector for workspace JenkinsBuildScripts: repository "JenkinsBuildScripts@<organization redacted>@Cloud" path "/" smartbranch "/main" [JenkinsBuildScripts] $ cm update /var/lib/jenkins/workspace/JenkinsBuildScripts-Example@libs/JenkinsBuildScripts The workspace /var/lib/jenkins/workspace/JenkinsBuildScripts-Example@libs/JenkinsBuildScripts is up-to-date (cset:43@JenkinsBuildScripts@<organization redacted>@Cloud) [Pipeline] node Running on Jenkins in /var/lib/jenkins/workspace/JenkinsBuildScripts-Example [Pipeline] { [Pipeline] stage [Pipeline] { (Declarative: Checkout SCM) [Pipeline] checkout [JenkinsBuildScripts-Example] $ cm find changeset where date between '2018-12-23T14:03:00' and '2018-12-23T14:05:00' and branch='/main' on repositories 'JenkinsBuildScripts-Example@<organization redacted>@cloud' --xml --dateformat=yyyy'-'MM'-'dd'T'HH':'mm':'ss <?xml version="1.0" encoding="utf-8" ?> <PLASTICQUERY> </PLASTICQUERY> [JenkinsBuildScripts-Example] $ cm gwp /var/lib/jenkins/workspace/JenkinsBuildScripts-Example --format={1} /var/lib/jenkins/workspace/JenkinsBuildScripts-Example [JenkinsBuildScripts-Example] $ cm lwk --format={0}#{1}#{2} ... JenkinsBuildScripts#master#/var/lib/jenkins/workspace/JenkinsBuildScripts-Example@libs/JenkinsBuildScripts JenkinsBuildScripts-Example#master#/var/lib/jenkins/workspace/JenkinsBuildScripts-Example ... [JenkinsBuildScripts-Example] $ cm unco --all /var/lib/jenkins/workspace/JenkinsBuildScripts-Example [JenkinsBuildScripts-Example] $ cm ss wk:JenkinsBuildScripts-Example Selector for workspace JenkinsBuildScripts-Example: repository "JenkinsBuildScripts-Example@<organization redacted>@cloud" path "/" smartbranch "/main" [JenkinsBuildScripts-Example] $ cm update /var/lib/jenkins/workspace/JenkinsBuildScripts-Example The workspace /var/lib/jenkins/workspace/JenkinsBuildScripts-Example is up-to-date (cset:2@JenkinsBuildScripts-Example@<organization redacted>@cloud) [Pipeline] } [Pipeline] // stage [Pipeline] stage [Pipeline] { (Example stage) [Pipeline] echo Stage has begun [Pipeline] script [Pipeline] { [Pipeline] } [Pipeline] // script [Pipeline] } [Pipeline] // stage [Pipeline] } [Pipeline] // node [Pipeline] End of Pipeline ... However, when I run the job for JenkinsBuildScripts-Example2, I get the output below. Plastic will check whether or not there is a workspace for JenkinsBuildScripts under the JenkinsBuildScripts-Example2@libs folder, find no workspace there, then skip creation of a new workspace, then attempt to revert any changes in the not-yet-created workspace, and this will fail: Obtained Jenkinsfile.groovy from repository "JenkinsBuildScripts-Example@<organization redacted>@Cloud" path "/" smartbranch "/main" Running in Durability level: MAX_SURVIVABILITY Loading library JenkinsBuildScripts@latest [JenkinsBuildScripts] $ cm find changeset where date between '2018-12-23T13:57:05' and '2018-12-23T14:11:18' and branch='/main' on repositories 'JenkinsBuildScripts@<organization redacted>@Cloud' --xml --dateformat=yyyy'-'MM'-'dd'T'HH':'mm':'ss <?xml version="1.0" encoding="utf-8" ?> <PLASTICQUERY> </PLASTICQUERY> [JenkinsBuildScripts] $ cm gwp /var/lib/jenkins/workspace/JenkinsBuildScripts-Example2@libs/JenkinsBuildScripts --format={1} /var/lib/jenkins/workspace/JenkinsBuildScripts-Example2@libs/JenkinsBuildScripts is not in a workspace. [JenkinsBuildScripts] $ cm lwk --format={0}#{1}#{2} ... JenkinsBuildScripts#master#/var/lib/jenkins/workspace/JenkinsBuildScripts-Example@libs/JenkinsBuildScripts JenkinsBuildScripts-Example#master#/var/lib/jenkins/workspace/JenkinsBuildScripts-Example ... [JenkinsBuildScripts] $ cm unco --all /var/lib/jenkins/workspace/JenkinsBuildScripts-Example2@libs/JenkinsBuildScripts /var/lib/jenkins/workspace/JenkinsBuildScripts-Example2@libs/JenkinsBuildScripts is not in a workspace. [JenkinsBuildScripts] $ cm unco --all /var/lib/jenkins/workspace/JenkinsBuildScripts-Example2@libs/JenkinsBuildScripts /var/lib/jenkins/workspace/JenkinsBuildScripts-Example2@libs/JenkinsBuildScripts is not in a workspace. [JenkinsBuildScripts] $ cm unco --all /var/lib/jenkins/workspace/JenkinsBuildScripts-Example2@libs/JenkinsBuildScripts /var/lib/jenkins/workspace/JenkinsBuildScripts-Example2@libs/JenkinsBuildScripts is not in a workspace. FATAL: The cm command 'cm unco --all /var/lib/jenkins/workspace/JenkinsBuildScripts-Example2@libs/JenkinsBuildScripts' failed after 3 retries FATAL: The cm command 'cm unco --all /var/lib/jenkins/workspace/JenkinsBuildScripts-Example2@libs/JenkinsBuildScripts' failed after 3 retries ERROR: Maximum checkout retry attempts reached, aborting org.codehaus.groovy.control.MultipleCompilationErrorsException: startup failed: WorkflowScript: Loading libraries failed 1 error at org.codehaus.groovy.control.ErrorCollector.failIfErrors(ErrorCollector.java:310) at org.codehaus.groovy.control.CompilationUnit.applyToPrimaryClassNodes(CompilationUnit.java:1085) at org.codehaus.groovy.control.CompilationUnit.doPhaseOperation(CompilationUnit.java:603) at org.codehaus.groovy.control.CompilationUnit.processPhaseOperations(CompilationUnit.java:581) at org.codehaus.groovy.control.CompilationUnit.compile(CompilationUnit.java:558) at groovy.lang.GroovyClassLoader.doParseClass(GroovyClassLoader.java:298) at groovy.lang.GroovyClassLoader.parseClass(GroovyClassLoader.java:268) at groovy.lang.GroovyShell.parseClass(GroovyShell.java:688) at groovy.lang.GroovyShell.parse(GroovyShell.java:700) at org.jenkinsci.plugins.workflow.cps.CpsGroovyShell.doParse(CpsGroovyShell.java:131) at org.jenkinsci.plugins.workflow.cps.CpsGroovyShell.reparse(CpsGroovyShell.java:125) at org.jenkinsci.plugins.workflow.cps.CpsFlowExecution.parseScript(CpsFlowExecution.java:560) at org.jenkinsci.plugins.workflow.cps.CpsFlowExecution.start(CpsFlowExecution.java:521) at org.jenkinsci.plugins.workflow.job.WorkflowRun.run(WorkflowRun.java:319) at hudson.model.ResourceController.execute(ResourceController.java:97) at hudson.model.Executor.run(Executor.java:429) Finished: FAILURE
  9. Hi Matt, I'm going to take the opportunity to pimp Plastic Cloud a bit, because I think it's awesome We are building this game with Unity and Plastic Cloud: https://playbatalj.com/ We are 15 developers in one office location. 1GBit connection to the Internet, wiring in the office happens to be 100MBit ethernet though. A main branch checkout (ie, just the workspace - not the metadata and older file revisions) is approx 7GB and 29000 files. We use Plastic Cloud instead of Plastic because we don't like to deal with backups and we are happy with the performance that we get. I used to have local repos on my machine and push/pull between my machine and Plastic Cloud, but stopped doing that a couple of months ago because 1) I didn't want repo history to eat my SSD space, 2) I didn't know how to use the "nodata replica" thing effectively from the GUI at that time and 3) I never noticed a significant speed difference anyway The biggest things we miss with Plastic Cloud compared to Plastic Server are lack of webhooks and lack of web client. We get by OK without them however, less ops work is worth it to us. Our CI system is a Jenkins deployment in Google Cloud. The most frequent builds pull Plastic Cloud for changes every 2 minutes. Since these builds are incremental, the incremental checkout is typically <30 secs. We have trained our entire team - bar 1 person - to work with task based branches using the full GUI client. Over all we are happy with this aspect of it. I often work with 2 workspaces for the same repo, 1 for regular dev, 1 for jumping around when helping others / hotfixes / merging between branches.
  10. This yields a list of the individual files that are different between the two changesets: However, going backwards from there to the changesets involved is cumbersome and I'm not sure this is a viable approach.
  11. Hi, I think I'm looking at a situation similar to JanReimer. I am looking for tooling that helps me answer "which changes have been done to the project between the previous release and the current one?" In our case, things work like this: * We do most development on task branches. People merge results back to main at the end of each task. Sometimes people do development directly on the main branch. * We create a new child branch for each release. A couple of merges, a couple of cherry-picks from main to the release branch - then we are done. Occasionally, a fix gets re-implemented on the release branch, when it is too difficult to cherry-pick it (this is most common with binary data changes). All in all, the simplest way for us to identify a release is to talk about its changeset ID. This will typically refer to the last changeset ID on the release branch. Sometimes we might decide to release a build made off another changeset on the release branch (because the last change was bad in some way). Now, the question I think would like to ask of the Plastic client is: I do not care about the few changes which are in <changeset ID A>'s history but not in <changeset ID B>'s history. I think one way to solve this would be to algorithmically start from <changeset ID A> and flatten the graph; follow merge/cherrypicks recursively. Then do the same, from <changeset ID B>. This will produce two lists of changesets. I can then remove all entries in <list B> which also appear in <list A>. Subtractive merges/cherrypicks complicate things a bit, haven't thought much about that yet. I think another way would be to find the last full merge that leads from /main to <changeset ID A>. Then work backward from <changeset ID B>, collect changesets, until that particular merge is encountered. Special cases required for cherrypicks etc afterward. So, er. What's the status on something like this? Do I need to build my own tooling for it? Does something exist already?
  12. Mikael Kalms

    Partial workspace update with Windows Batch command

    Are you relying on Jenkins directly-or-indirectly running those lines of code? If so, the Jenkins agent runs as SYSTEM ... but your Remote Desktop session runs as Fleer. When Jenkins runs Plastic, Plastic will fetch files and create these files with owner SYSTEM. Later on, when you attempt to touch the same workspace via Plastic via the Remote Desktop session, Plastic complains that it can't touch any of the files in the workspace because of ownership/permissions problems. In order to get away from this, either make Jenkins use the same user as yourself (so you can use Plastic via Remote Desktop against the same workspace), or make Jenkins run the cleanup commands. What I have done is, I'm letting the Plastic plugin perform full checkout of the repo (so no explicit "cm partial ..." commands), and as a post step in the (declarative) pipeline I run the following: cm unco --all ${WORKSPACE} This undoes all actions that Unity may have caused except for one thing: it will not remove newly added files. If you want to delete those, you need to write more logic of your own to find & delete those.
  13. Eh, I just realized that item #2 is a duplicate of this forum question: I cannot vote on the UserVoice option since it is has already been declined.
  14. Hi, I'm looking into automation of Plastic SCM client installation on Windows. Others would find this useful for workstations; I'm doing this particularly for Jenkins build slaves. What I would like to see is that I can write a PowerShell script that downloads & installs a Plastic SCM client. Probably the latest-available version. Probably the Cloud edition. Does any of the following exist? 1. A REST API which can be used to discover download URLs for installers. For example, https://www.plasticscm.com/restapi/downloadinstaller/7.0.16.2562/plasticscm/windows/cloud-edition -> returns the URL https://www.plasticscm.com/download/downloadinstaller/7.0.16.2562/plasticscm/windows/cloudedition which, when accessed, will redirect to the real download URL https://www.plasticscm.com/restapi/downloadinstaller/lastest/plasticscm/windows/cloud-edition -> returns the download URL for the latest version 2. A Chocolatey package for Plastic SCM; the package index could either live in in Chocolatey's public index, or on a machine run by Codice Software (sort of like you do with the Linux packages). The Chocolatey index would serve the same purpose as the above REST API. Either of these, or some equivalent solution, would enable me to write a couple of lines of PowerShell which download + install the latest version of the Plastic SCM client. As it is now, I believe the best course of action for me is to split my installation scripts into two parts; one is an list of URLs which I scrape from the plasticscm.com website manually and add to the script (and update every month or so), and the second is the actual download/installation script (which remains unchanged).
  15. Hi, I just noticed that if I run the installer like so: PlasticSCM-7.0.16.2562-windows-cloud-installer.exe --mode unattended ... then the PlasticSCM5\Client & PlasticSCM5\Server folders are not added to the system PATH. These are added when I run the installer in normal ("win32") mode. Is this intended behaviour?
×