0

I am completely new to Linux and have no idea what to do. What I am trying to do is the following: I want to install Stata 16 on Ubuntu 18.04.3 LTS 64-bit. I followed the stata installation guide and till now it worked out fine. Now I am asked to do this:

If you use bash , sh , or ksh , there is a line in your .profile (in your home directory) that looks like

PATH="/bin:/usr/bin:/usr/local/bin:$HOME/bin"

Edit the file and add /usr/local/stata to the list:

PATH="/bin:/usr/bin:/usr/local/bin:$HOME/bin:/usr/local/stata"

My problem is: There is not line in my .profile that looks like the one above. My .profile says:

if running bash if [ -n "$BASH_VERSION" ]; then

# include .bashrc if it exists
if [ -f "$HOME/.bashrc" ]; then   . "$HOME/.bashrc"
fi fi

set PATH so it includes user's private bin if it exists if [ -d "$HOME/bin" ] ; then

PATH="$HOME/bin:$PATH" fi

set PATH so it includes user's private bin if it exists if [ -d "$HOME/.local/bin" ] ; then

PATH="$HOME/.local/bin:$PATH" fi

The only files in my home directory are .bash_history, .bash_logout, .bashrc, .profile and .sudo_as_admin_successful.

What do I have to do in order to include stata into the PATH? Could someone please be so incredibly kind and walk me through the steps?

Side problem: my keyboard has some errors. It cannot write any signs that need the AltGr-key anymore.

Thank you so much in advance!

1
  • Have You already installed Stata and just want to update the PATH ? Check the file .bashrc - there should be a PATH. Sep 9, 2019 at 22:04

1 Answer 1

0

I do something similar to add my scripts to my path by adding this to my ~/.bashrc:

export PATH=$PATH:$HOME/scripts

So, to add stata to your path, add this:

export PATH=$PATH:/usr/local/stata
1
  • Thank you so much! It works!
    – ShoshK
    Sep 10, 2019 at 7:04

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .