I have set

export PATH=$PATH:/home/user/android-sdk-linux/platform-tools

and execute the above line in command line and later if I type echo $PATH, I could see the path added. But after restarting the system I couldn't see it any more. But putting the system to sleep and then starting again, I could still see it. How to resolve the issue?

有帮助吗?

解决方案

Adding it using export on command line would just set it for the current session.To set it permanently you need to add it to .bashrc or /etc/profile.

Your question is similar to: How to permanently export a variable in Linux?

许可以下: CC-BY-SA归因
不隶属于 StackOverflow
scroll top