Hacker News
new
|
past
|
comments
|
ask
|
show
|
jobs
|
submit
login
throwmemoney
on June 24, 2021
|
parent
|
context
|
favorite
| on:
Bash PS1 Generator
What is the best way to have the long directory line above the prompt? Using PS2 or PS3?
geraldcombs
on June 24, 2021
|
next
[–]
I'm not a fan of multiline prompts but I do like knowing where I am, so I trim the path and prepend a "…" character.
nine_k
on June 24, 2021
|
prev
[–]
Something like "\w\n\$ " should work; mine is more complex by the idea holds, you can have a \n in your PS1 just fine.
Guidelines
|
FAQ
|
Lists
|
API
|
Security
|
Legal
|
Apply to YC
|
Contact
Search: