linux - Making bash profile visible for non login shell -


i have .bash_profile , have several commands in shell. have logged in user1. in terminal, su - user2.

when i'm user2, i'm not able call these commands have created in .bash_profile. how make path elements , environment variables visible user2 well? when echo $path when using user2, this:

/usr/local/bin:/usr/bin:/bin:/usr/sbin:/sbin:/usr/local/git/bin:/usr/local/go/bin

when echo $path using user1, lot more. how make additional path elements visible user1?

su <user> (without -) not read < user >'s shell initialization files. leaving previous users' settings.


Comments

Popular posts from this blog

Ansible - ERROR! the field 'hosts' is required but was not set -

customize file_field button ruby on rails -

SoapUI on windows 10 - high DPI/4K scaling issue -