The first line of the Jenkinsfile should be "!#/usr/bin/env groovy", is that correct?

1,225 views
Skip to first unread message

dandeliondodgeball

unread,
Oct 11, 2017, 11:39:35 AM10/11/17
to Jenkins Users
I just noticed this comment in the Jenkins User Handbook [https://jenkins.io/user-handbook.pdf].

Mark Waite

unread,
Oct 11, 2017, 11:48:46 AM10/11/17
to Jenkins Users
I suspect you meant (and I've confirmed that the handbook has it correct).:

#! /usr/bin/env groovy

rather than

!# /usr/bin/env groovy

That can be helpful as the first line, as described in the handbook.  It helps some editors and viewer recognize portions of the file more readily.

Mark Waite

On Wed, Oct 11, 2017 at 9:39 AM dandeliondodgeball <chris...@3derm.com> wrote:
I just noticed this comment in the Jenkins User Handbook [https://jenkins.io/user-handbook.pdf].

--
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/028dfcb0-72ad-4483-b4b8-5c4a35c00406%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.

dandeliondodgeball

unread,
Oct 11, 2017, 11:55:08 AM10/11/17
to Jenkins Users
My life is full of typos, so yes 

#! /usr/bin/env groovy

Oh, it is only to make my IDE life a better place.  I understand now.  Thanks.

Mark Waite

unread,
Oct 11, 2017, 11:58:39 AM10/11/17
to Jenkins Users
Yes, it helps the editors.  It won't allow you to run a Jenkins Pipeline script from the Linux command line.

--
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.
Reply all
Reply to author
Forward
0 new messages