<?xml version="1.0" encoding="UTF-8"?><rss xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:atom="http://www.w3.org/2005/Atom" version="2.0" xmlns:cc="http://cyber.law.harvard.edu/rss/creativeCommonsRssModule.html">
    <channel>
        <title><![CDATA[Stories by Prij on Medium]]></title>
        <description><![CDATA[Stories by Prij on Medium]]></description>
        <link>https://medium.com/@prij10?source=rss-c2c7520319c4------2</link>
        <image>
            <url>https://cdn-images-1.medium.com/fit/c/150/150/1*dmbNkD5D-u45r44go_cf0g.png</url>
            <title>Stories by Prij on Medium</title>
            <link>https://medium.com/@prij10?source=rss-c2c7520319c4------2</link>
        </image>
        <generator>Medium</generator>
        <lastBuildDate>Sun, 22 Nov 2026 05:25:17 GMT</lastBuildDate>
        <atom:link href="https://medium.com/@prij10/feed" rel="self" type="application/rss+xml"/>
        <webMaster><![CDATA[yourfriends@medium.com]]></webMaster>
        <atom:link href="http://medium.superfeedr.com/" rel="hub"/>
        <item>
            <title><![CDATA[Issue faced in setting node js version while developing jenkins shared library.]]></title>
            <link>https://medium.com/@prij10/issue-faced-in-setting-node-js-version-while-developing-jenkins-shared-library-e6c53da6eeb8?source=rss-c2c7520319c4------2</link>
            <guid isPermaLink="false">https://medium.com/p/e6c53da6eeb8</guid>
            <dc:creator><![CDATA[Prij]]></dc:creator>
            <pubDate>Tue, 17 Jan 2023 10:20:57 GMT</pubDate>
            <atom:updated>2023-01-17T10:28:28.792Z</atom:updated>
            <content:encoded><![CDATA[<p>In jenkins shell commands starts a new shell process which means any environment variable or setting u have made in previous step will not be visible in the next step unless they are explicitly exported or passed as argument.</p><p>Each shell command run its own process and process will not have access to the variables set in previous shell.</p><p>I found a workaround initially ,</p><p>alias node=&quot;nave use 12.13.1 node&quot;<br> alias npm=&quot;nave use 12.13.1 npm&quot;</p><p>I had use above lines in each stage in order to get node 12 but it was a temp fix.</p><p>What worked was</p><p>script.env.NODEJS_HOME = script.tool(jsName)</p><p>script.env.PATH=&quot;${script.env.NODEJS_HOME}/bin:${script.env.PATH}&quot;</p><p>In my js env setup class file.</p><p>The script.env object is used to access and modify environment variables for the Jenkins pipeline script. The PATHvariable tells the operating system where to look for executables when you run a command in the terminal.<br>This line of code is appending the bin directory of the Node.js installation (NODEJS_HOME) to the PATH environment variable. This means that after this step is executed, the operating system will look for executables in the bin directory of the Node.js installation in addition to the directories that were already in the PATH.</p><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=e6c53da6eeb8" width="1" height="1" alt="">]]></content:encoded>
        </item>
    </channel>
</rss>