ondreduty9759 ondreduty9759
  • 03-12-2020
  • Computers and Technology
contestada

How would you change your prompt to have it display the current time (hour and minute) and the full path of the current directory?

Respuesta :

tgalligan92 tgalligan92
  • 03-12-2020

Answer:I tried using following command:

Code:

export PS1="$(date +%k:%M:%S) $ "

but it gave me a fixed time in prompt whereas my objective is to get the current time everytime.

Code:

$ export PS1="$(date +%k:%M:%S) $ "

17:42:42 $

17:42:42 $ date

Tue Oct  2 17:42:54 PDT 2012

17:42:42 $

Explanation:

Answer Link

Otras preguntas

By using sound waves, _______ signals allow oceanographers to determine ocean depth.
Plato believed that a. individuals should live in a just and rational state b.an ideal government should be ruled by dictators c democracy was the best form of
In this organelle, carbon dioxide and water are converted to _________ and oxygen.
6x+(x-2)=180 solve this and explain
The perimeter of a rectangular field is 354 yards. If the width of the field is 82 yards, what is its length
is 25 to 16 proportional to 5 to 4
is 0.4 less than, greatest than, or equal to 44%? explain
How can you use a single parallel sentence to combine the sense in these two sentences? I regularly drudge five days a week. I habitually sleep through the week
Why did Thomas Jefferson order an embargo against Great Britain in 1807?
Which literary device is used in line 11 of wingspaninson’s poem? “…the Fields of Gazing Grain—“ irony alliteration simile metonymy metaphor