<h3 dir="auto">Is there an existing issue for this?</h3>
<ul class="contains-task-list">
<li class="task-list-item"><input type="checkbox" id="" disabled="" class="task-list-item-checkbox" checked=""> I have searched the existing issues</li>
</ul>
<h3 dir="auto">This issue exists in the latest npm version</h3>
<ul class="contains-task-list">
<li class="task-list-item"><input type="checkbox" id="" disabled="" class="task-list-item-checkbox" checked=""> I am using the latest npm</li>
</ul>
<h3 dir="auto">Current Behavior</h3>
<p dir="auto">Running <code class="notranslate">npm config set</code> expands all environment variables in <code class="notranslate">.npmrc</code>, permanently.</p>
<p dir="auto"><a href="https://docs.npmjs.com/cli/v8/configuring-npm/npmrc" rel="nofollow">The documentation</a> says you can do this:</p>
<blockquote>
<p dir="auto">All npm config files are an ini-formatted list of key = value parameters. Environment variables can be replaced using ${VARIABLE_NAME}. For example:</p>
<div class="snippet-clipboard-content notranslate position-relative overflow-auto" data-snippet-clipboard-copy-content="prefix = ${HOME}/.npm-packages"><pre class="notranslate"><code class="notranslate">prefix = ${HOME}/.npm-packages
</code></pre></div>
</blockquote>
<p dir="auto">However if you do this, it gets expanded permanently the first time you run <code class="notranslate">npm config</code>:</p>
<div class="snippet-clipboard-content notranslate position-relative overflow-auto" data-snippet-clipboard-copy-content="$ cat .npmrc
prefix = ${HOME}/.npm-packages
$ npm config set dummy=true --location=project
$ cat .npmrc
prefix = /home/example/.npm-packages
dummy=true"><pre class="notranslate"><code class="notranslate">$ cat .npmrc
prefix = ${HOME}/.npm-packages
$ npm config set dummy=true --location=project
$ cat .npmrc
prefix = /home/example/.npm-packages
dummy=true
</code></pre></div>
<h3 dir="auto">Expected Behavior</h3>
<p dir="auto">Environment variables in <code class="notranslate">.npmrc</code> should be left alone.  They are often placeholders for things like authentication tokens for private repositories, so replacing them with the current value is undesirable and breaks functionality.</p>
<h3 dir="auto">Steps To Reproduce</h3>
<ol dir="auto">
<li><code class="notranslate">echo 'prefix = ${HOME}/.npm-packages' &gt;&gt; .npmrc</code></li>
<li><code class="notranslate">cat .npmrc</code></li>
<li>Confirm <code class="notranslate">${HOME}</code> is contained in the file</li>
<li><code class="notranslate">npm config set dummy=true --location=project</code></li>
<li><code class="notranslate">cat .npmrc</code></li>
<li>Observe <code class="notranslate">${HOME}</code> has been replaced with the current user's actual home directory.</li>
</ol>
<h3 dir="auto">Environment</h3>
<ul dir="auto">
<li>npm: 8.18.0</li>
<li>Node.js: 18.4.0</li>
<li>OS Name: Arch Linux</li>
</ul>
<h3 dir="auto">Is there an existing issue for this?</h3>
<ul class="contains-task-list">
<li class="task-list-item"><input type="checkbox" id="" disabled="" class="task-list-item-checkbox" checked=""> I have searched the existing issues</li>
</ul>
<h3 dir="auto">This issue exists in the latest npm version</h3>
<ul class="contains-task-list">
<li class="task-list-item"><input type="checkbox" id="" disabled="" class="task-list-item-checkbox" checked=""> I am using the latest npm</li>
</ul>
<h3 dir="auto">Current Behavior</h3>
<p dir="auto">I found that <code class="notranslate">npm create &lt;initializer&gt;</code> behaves the same way as <code class="notranslate">npm init &lt;initializer&gt;</code>, but there seems to be no mention of it in the documentation</p>
<h3 dir="auto">Expected Behavior</h3>
<p dir="auto">To have Documentation</p>
<h3 dir="auto">Steps To Reproduce</h3>
<ol dir="auto">
<li>npm v8.3.0</li>
<li>Run <code class="notranslate">npm create vue</code></li>
<li>It works fine. <code class="notranslate">create-vue</code></li>
</ol>
<h3 dir="auto">Environment</h3>
<ul dir="auto">
<li>npm:</li>
</ul>