Jenkinsfile Sysntax

50 views
Skip to first unread message

Atul Sharma

unread,
Dec 28, 2016, 7:43:01 AM12/28/16
to Jenkins Users
Please tell me how can i check the jenkinsfile systax , I  am new in programming please tell me best way to test the jenkins file ,




Mark Waite

unread,
Dec 28, 2016, 10:19:26 AM12/28/16
to Jenkins Users
The most reliable check is to run it in a Jenkins job.

If you want to iterate through a series of experimental changes without committing them to the source control system, you can define the Jenkinsfile in the Jenkins job, then edit it from the Jenkins job configuration web page.

If you prefer keeping the Jenkinsfile in source control, then you can use the "Replay" button on the Jenkins job user interface to allow you to edit the Jenkinsfile used for a previous run, making changes as needed, then watching them run.

Mark Waite

On Wed, Dec 28, 2016 at 5:43 AM Atul Sharma <1989atu...@gmail.com> wrote:
Please tell me how can i check the jenkinsfile systax , I  am new in programming please tell me best way to test the jenkins file ,




--
You received this message because you are subscribed to the Google Groups "Jenkins Users" group.
To unsubscribe from this group and stop receiving emails from it, send an email to jenkinsci-use...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/jenkinsci-users/ae78cf45-c3b0-4c64-944e-7c596e2687b3%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.

Atul Sharma

unread,
Dec 28, 2016, 11:00:39 AM12/28/16
to Jenkins Users
Thanks mark , Can you please also help me how to do
It once some steps , so that I can check besically I want to check syntax of my Jenkins file which is wrote in groovy and we are using git where our Jenkins file exist , so before build Jenkins job I want to check mention code in same Jenkins futile sysmtax is correct yes or not ,

So that I want to do please help me with steps ,

Mark Waite

unread,
Dec 28, 2016, 4:39:29 PM12/28/16
to jenkins...@googlegroups.com
If you're working in a repository alone, you can take the simple approach, checkin your change and watch it run in Jenkins.  For example, if you're using github and you're working on a fork of the repository, then you're "working in a repository alone".

If you're working on a repository which is shared with others, and where others expect certain branches to remain stable, then you can create a branch (a "feature branch"), create a matching Jenkins job for that feature branch, and submit your changes to the feature branch.  When you are satisfied that your changes are good enough, you merge the feature branch to the stable branch so that others can benefit from your work.

Mark Waite 

--
You received this message because you are subscribed to the Google Groups "Jenkins Users" group.
To unsubscribe from this group and stop receiving emails from it, send an email to jenkinsci-use...@googlegroups.com.

Atul Sharma

unread,
Dec 28, 2016, 11:18:30 PM12/28/16
to jenkins...@googlegroups.com
Thanks mark ,






You received this message because you are subscribed to a topic in the Google Groups "Jenkins Users" group.


To unsubscribe from this topic, visit https://groups.google.com/d/topic/jenkinsci-users/iae_UbW5Hvg/unsubscribe.


To unsubscribe from this group and all its topics, send an email to jenkinsci-use...@googlegroups.com.


To view this discussion on the web visit https://groups.google.com/d/msgid/jenkinsci-users/CAO49JtH11ncbfSO__0nTq2NTvWck%2BE%3DUisj8kWkn%2BSGoA1jUng%40mail.gmail.com.



For more options, visit https://groups.google.com/d/optout.


--
Sent from IPhone 6s+
Reply all
Reply to author
Forward
0 new messages