aboutsummaryrefslogtreecommitdiff
path: root/articles/2025/Bash-prompt-without-scripts.html
blob: cf6c42cfa39c4f28019e0706844f2dce3fd5bab6 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
<!doctype html>
<html lang="EN">
  <head>
    <meta charset="utf-8">
    <meta name="viewport" content="width=device-width, initial-scale=1">
    <link rel="stylesheet" href="/style.css">
    <title>Bash prompt without scripts</title>
  </head>
  <body>
    <header>
      <h1>Bloggings</h1>
      <a href="/index.php">Back</a>
      
    </header>
    
<main>
<article>
<h2>Bash prompt without scripts</h2>
<h3>2025-05-06</h3>
<h4>A pretty prompt in one line of my .bashrc</h4>
<p>I tried several bash prompt scripts but returned to just having a single line in my .bashrc</p>
<pre>
export PS1='\[\e[30;102m\] \A \[\e[92;103m\]\[\e[30m\] \u@\h \[\e[93;107m\]\[\e[30m\] \w \[\e[0;97m\]\n\[\e[0m\]\$ '
</pre>
<p><a href="https://bash-prompt-generator.org/">This site is a great generator</a></p>
<p>I used the base 16 colour palette so that it ends up displayed using the Pywal16 terminal palette.</p>
<p><img src="/images/blog/bash-prompt-pywal.png"></p>
</article>
</main>
<footer>

<p>&nbsp;</p>

<p>§</p>
  </footer>
</body>
</html>