How to make the prompt in the Command Prompt look like the Linux bash prompt
Published: 2021-06-30 20:45:00

<h1 style="text-align: left;">How to make the prompt in the Command Prompt look like the Linux bash prompt</h1>
<h2 style="text-align: left;">Example</h2>
<p style="text-align: left;">Here is an example of how the Linux bash in Ubuntu looks like:</p>
<table align="center" cellpadding="0" cellspacing="0" class="tr-caption-container" style="margin-left: auto; margin-right: auto;">
    <tbody>
        <tr>
            <td style="text-align: center;"><a href="https://i.imgur.com/1WpiRVt.png" style="margin-left: auto; margin-right: auto;"><img alt="wsl terminal" border="0" data-original-height="426" data-original-width="800" height="342" src="https://i.imgur.com/1WpiRVt.png" title="In WSL" width="640" /></a></td>
        </tr>
        <tr>
            <td class="tr-caption cc_cursor" style="text-align: center;">Ubuntu in WSL</td>
        </tr>
    </tbody>
</table>
<div class="separator cc_cursor" style="clear: both; text-align: center;"><br /></div>
<div class="separator cc_cursor" style="clear: both; text-align: center;"><br /></div><br />
<h2 style="text-align: left;">Tutorial</h2>
<p style="text-align: left;">There is a feature in Command Prompt called the </p>
<code class="bash cc_cursor">prompt</code><p></p>
<p style="text-align: left;">command. It lets you change your prompt for example I could type&nbsp;</p>
<code class="bash">prompt hello</code><p>it would change my prompt to hello:</p>
<table align="center" cellpadding="0" cellspacing="0" class="tr-caption-container" style="margin-left: auto; margin-right: auto;">
    <tbody>
        <tr>
            <td style="text-align: center;"><a href="https://i.imgur.com/phNoR2x.png" style="margin-left: auto; margin-right: auto;"><img border="0" data-original-height="426" data-original-width="800" height="341" src="https://i.imgur.com/phNoR2x.png" width="640" /></a></td>
        </tr>
        <tr>
            <td class="tr-caption cc_cursor" style="text-align: center;"></td>
        </tr>
    </tbody>
</table><br />
<p>When I type </p>
<code class="bash">prompt</code>
<p>it goes back to normal!</p><img border="0" data-original-height="426" data-original-width="800" height="341" src="https://i.imgur.com/dAAyhEq.png" width="640" />
<p>When I type </p>
<code class="bash">prompt /?</code><p>it gives me the list of the variables.</p><img border="0" data-original-height="426" data-original-width="800" height="341" src="https://i.imgur.com/nku0F98.png" width="640" />
<h2 style="text-align: left;">Here is the full solution: </h2>
<p>If you use the prompt command it will reset when you relaunch the Command Prompt so the solution is to make a registry tweak. NOTE: I am not responsible if you mess up your windows install!!! The easy way to do this is by running&nbsp;<a href="https://download937.mediafire.com/tt1gvliz92qg/t1nl50r4ajhrcl4/bash-command-prompt.reg" target="_blank">this file</a>&nbsp;it has some text in it that when double-clicked will make the registry edits for you! If you are interested in how it works here is the file contents:</p>
```
Windows Registry Editor Version 5.00 
[HKEY_CURRENT_USER\SOFTWARE\Microsoft\Command Processor]
"Autorun"="prompt $V $P $_$$$S"
```
<p>It basically works by running </p>
<code class="bash">prompt $V $P $_$$$S</code>
<p> every time you start Command Prompt. When you finish downloading the file open it and you are done!</p>