Third step learn as a habit…
During a lock down and after a mind block, I decided to still try to introduce smart habits, like learning new small skills.
My personal operating system is a LTS, probably Lubuntu or something like that. I’m not updating since years. At work I use Windows 10. Because of that and because of being lazy, I told to myself:
“You don’t have time to learn bash scripting, you don’t need to learn bash scripting” – That was the demon on my left side.
The angel’s voice was: “Take it easy, take small baby steps every time you have a chance to. Avoid using the GUI if there is a command line.”
So I decided to listen only one of the two voices. I followed the angel.
Use case description:
I had to install the chrome driver somewhere in a Python folder on my work laptop and it was required to update the environment variables. Of course I could use the friendly GUI option, but I made the effort to play around with Windows Bash Commands.
Solution:
- Run as administrator the Command Prompt. You have to remember your admin password. Good luck with that!
- (before) Check current environment variables. Just in case you don’t need to update anything. The command is super easy echo %path%
- Add a new path to the environment variables. The command is setx path “%path%;C:\Users\yourPath” Watch out at the backslash instead of slash in the path.
- (after) Check current environment variables
- Take a screenshot as a souvenir. In case in a month or in a year you’ll have something else to add to the environment variables, you’ll save yourself a search on Google.
exit