Gowrish Posted September 26, 2017 Report Share Posted September 26, 2017 Hi Team, We use Plastic SCM 6.0. The major part of our code is pl/sql objects. We need to figure out if there is any validation method/scripting available in Plastic before we run the Jenkins build. Example of few scenarios: 1. If I need to have the sql script name in specific format. 2. The specific file is newly added into the branch after a certain date. Please let me know if I can contact someone from the Plastic team to understand our requirements can be fulfilled using Plastic. Thank you in advance., Link to comment Share on other sites More sharing options...
manu Posted September 26, 2017 Report Share Posted September 26, 2017 Hello @Gowrish, I think the Plastic SCM triggers will fit for you, specially the before-checkin trigger: https://www.plasticscm.com/documentation/triggers/plastic-scm-version-control-triggers-guide.shtml#Checkin You can add the logic inside the trigger body, check the names of the new objects, the timestamp etc... if it doesn't match your criteria then you can cancel the checkin operation. Link to comment Share on other sites More sharing options...
Gowrish Posted September 26, 2017 Author Report Share Posted September 26, 2017 Thank you Manu; I'll explore the triggers feature in Plastic. Link to comment Share on other sites More sharing options...
manu Posted September 27, 2017 Report Share Posted September 27, 2017 Perfect, don't hesitate to contact us if you have any questions, and feel free to publish or tweet your trigger once you finish it! Link to comment Share on other sites More sharing options...
Gowrish Posted October 2, 2017 Author Report Share Posted October 2, 2017 Hi Manu, I tried looking at the "cm find merges" section to retrieve the file names (excluding the root or sub folders) merged in a specific branch. 1. There is no such --format="{item}" to use similar to "cm find revisions". 2. Is it possible to query the merges done in last one hour duration ? These are needed as input for my script. Please advice. Thank you., Link to comment Share on other sites More sharing options...
manu Posted October 3, 2017 Report Share Posted October 3, 2017 What about this? >cm find merge where "date >= '2017/10/01'" --format="cs:{dstchangeset} ({date})" --nototal cs:8856 (10/2/2017 6:17:22 PM) cs:8858 (10/2/2017 6:29:01 PM) It will give you the merge result changeset based on the starting date. Later you can use the result changeset for a "cm diff" command and check if the item is involved in the merge. What do you think? Link to comment Share on other sites More sharing options...
Gowrish Posted October 5, 2017 Author Report Share Posted October 5, 2017 Yes; I'm working on similar queries to get the changesets. That helps; also i just checked my Jenkins job log it is using the similar format to find the difference. I have another question: Will the triggers really impact the performance of Plastic; say if I create a trigger on every check-in operation ? Thank you., Link to comment Share on other sites More sharing options...
manu Posted October 6, 2017 Report Share Posted October 6, 2017 Hello @Gowrish, triggers will affect only the operation in progress, the rest of user will not notice it. It' not an overhead for Plastic. On the other hand you'll need to carefully think what your trigger is going to do. If it's going to be something that is going to take some time then you may want to start a different process to let the Plastic SCM operation finish. If you are going to be checking a couple of strings or a few API requests then you will be fine. Link to comment Share on other sites More sharing options...
Recommended Posts
Archived
This topic is now archived and is closed to further replies.