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

If y varies directly with x and y = 6 and x = -3, find y when x = 4.
What can you conclude about parallel lines drawn in the coordinate plane?
Answer these 2 questions
If the mean is greater than the median, then the longer tail of the distribution is on the _________.
(x^7/8) (x^1/4) Simplify the expression using the properties of exponents
Which perspective focuses on free will and self-actualization?
When you add 34 by 822 and then once once you answer that, give a real world example of the equation.
Which of the following do abiotic and biotic factors not have in common? both are needed for survival both are found in ecosystems both are used for economic ga
1) What part of 20 is 5? 2) What part of 20 is 12?
A point in the figure is selected at random. Find probability that the point will be in the shaded region