The following one liner should display root's home directory: grep -w ^root /etc/passwd | cut -d: -f6
Which finds the line beginning with the word root, and returns the sixth entry (the home directory of that entry). On 5/13/19, 8:39 AM, "CentOS on behalf of Nux!" <centos-boun...@centos.org on behalf of n...@li.nux.ro> wrote: Hi, The $home of root is /root, just copy it there. -- Sent from the Delta quadrant using Borg technology! Nux! https://urldefense.proofpoint.com/v2/url?u=http-3A__www.nux.ro&d=DwIGaQ&c=Ftw_YSVcGmqQBvrGwAZugGylNRkk-uER0-5bY94tjsc&r=Tou2GfskafF_UnC0yPjAjEzLDhbALx-0EDoLp3_iSss&m=BtGUZ97pcKOFG7bhNzhabJQysuxxWgjVQIWf3J07Wj8&s=ugp8dpIHA9dciXeJwCp2QajbDnF239ydtrHUdQtebNU&e= ----- Original Message ----- > From: "Bee.Lists" <bee.li...@gmail.com> > To: "CentOS mailing list" <centos@centos.org> > Sent: Monday, 13 May, 2019 13:28:24 > Subject: [CentOS] root .bash_profile? > Hi folks. Just wondering how I can implement an automatic .bash_profile for > root. I have to load my user .bash_profile every time I get into root, and I > would like a better solution. There is no /home/ for root, so I’m a bit > confused if this is even allowed. > > Any insight appreciated. > > > Cheers, Bee > > > > > _______________________________________________ > CentOS mailing list > CentOS@centos.org > https://urldefense.proofpoint.com/v2/url?u=https-3A__lists.centos.org_mailman_listinfo_centos&d=DwIGaQ&c=Ftw_YSVcGmqQBvrGwAZugGylNRkk-uER0-5bY94tjsc&r=Tou2GfskafF_UnC0yPjAjEzLDhbALx-0EDoLp3_iSss&m=BtGUZ97pcKOFG7bhNzhabJQysuxxWgjVQIWf3J07Wj8&s=B82ZL5g_jIXQH525NCuZ0IsQGQiu9LlNIVHR8yg_0-g&e= _______________________________________________ CentOS mailing list CentOS@centos.org https://urldefense.proofpoint.com/v2/url?u=https-3A__lists.centos.org_mailman_listinfo_centos&d=DwIGaQ&c=Ftw_YSVcGmqQBvrGwAZugGylNRkk-uER0-5bY94tjsc&r=Tou2GfskafF_UnC0yPjAjEzLDhbALx-0EDoLp3_iSss&m=BtGUZ97pcKOFG7bhNzhabJQysuxxWgjVQIWf3J07Wj8&s=B82ZL5g_jIXQH525NCuZ0IsQGQiu9LlNIVHR8yg_0-g&e= This message contains information which may be confidential and privileged. Unless you are the intended recipient (or authorized to receive this message for the intended recipient), you may not use, copy, disseminate or disclose to anyone the message or any information contained in the message. If you have received the message in error, please advise the sender by reply e-mail, and delete the message. Thank you very much. _______________________________________________ CentOS mailing list CentOS@centos.org https://lists.centos.org/mailman/listinfo/centos