I need to make a script that on every login creates folder and subfolder, I have the script written but I don't know how to add it to /etc/profile.d
I have tried to write in /etc/profile.d source /home/user1/script1.sh but don't know if this is correct.
Asked
Active
Viewed 1.2k times
2
1 Answers
4
Just drop the script in /etc/profile.d/. You can use mv: sudo mv ~/script.sh /etc/profile.d/
** Make sure the file ends with .sh
gorgo
- 258