How To Start A Program With Its Name
.everyoneloves__top-leaderboard:empty,.everyoneloves__mid-leaderboard:empty,.everyoneloves__bot-mid-leaderboard:empty{ margin-bottom:0;
}
I've installed Matlab on my Ubuntu 18.04. Every time I want to open it I need to call it.
/usr/local/MATLAB/R2017a/bin/matlab
I think it is too long and waste of a little time. There has to be an easier way to open it. How can I open it simply by writing its name or is there any easier way?
filesystem installed-programs
add a comment |
I've installed Matlab on my Ubuntu 18.04. Every time I want to open it I need to call it.
/usr/local/MATLAB/R2017a/bin/matlab
I think it is too long and waste of a little time. There has to be an easier way to open it. How can I open it simply by writing its name or is there any easier way?
filesystem installed-programs
1
You can add it to "path", or create an alias.
– Pilot6
Mar 16 at 9:09
add a comment |
I've installed Matlab on my Ubuntu 18.04. Every time I want to open it I need to call it.
/usr/local/MATLAB/R2017a/bin/matlab
I think it is too long and waste of a little time. There has to be an easier way to open it. How can I open it simply by writing its name or is there any easier way?
filesystem installed-programs
I've installed Matlab on my Ubuntu 18.04. Every time I want to open it I need to call it.
/usr/local/MATLAB/R2017a/bin/matlab
I think it is too long and waste of a little time. There has to be an easier way to open it. How can I open it simply by writing its name or is there any easier way?
filesystem installed-programs
filesystem installed-programs
asked Mar 16 at 9:08
sarpsarp
4828
4828
1
You can add it to "path", or create an alias.
– Pilot6
Mar 16 at 9:09
add a comment |
1
You can add it to "path", or create an alias.
– Pilot6
Mar 16 at 9:09
1
1
You can add it to "path", or create an alias.
– Pilot6
Mar 16 at 9:09
You can add it to "path", or create an alias.
– Pilot6
Mar 16 at 9:09
add a comment |
2 Answers
2
active
oldest
votes
Add this to your ~/.bashrc
file
export PATH=/usr/local/MATLAB/R2017a/bin:$PATH
3
It didn't work at first, but a little research on the net solved it. It should be without "matlab" at the end. Like this: export PATH=/usr/local/MATLAB/R2017a/bin:$PATH
– sarp
Mar 16 at 9:27
add a comment |
You can either add /usr/local/MATLAB/R2017a/bin/
to your PATH or create another script in a proper directory of executables in your home.
To do the second one follow the steps below.
- Create a folder named
bin
in your home directory. (Note: This assumes the directory~/bin/
is included in your PATH. If it isn't, you need to add it to your path first.) - Create a text file named
matlab
(the command you want to use) in the the aforementioned crated folder (i.e. in~/bin/
).
Add the following lines to the
matlab
file
#!/bin/bash
/usr/local/MATLAB/R2017a/bin/matlab
- Save the
matlab
file and make it executable.
add a comment |
Your Answer
StackExchange.ready(function() {
var channelOptions = {
tags: "".split(" "),
id: "89"
};
initTagRenderer("".split(" "), "".split(" "), channelOptions);
StackExchange.using("externalEditor", function() {
// Have to fire editor after snippets, if snippets enabled
if (StackExchange.settings.snippets.snippetsEnabled) {
StackExchange.using("snippets", function() {
createEditor();
});
}
else {
createEditor();
}
});
function createEditor() {
StackExchange.prepareEditor({
heartbeatType: 'answer',
autoActivateHeartbeat: false,
convertImagesToLinks: true,
noModals: true,
showLowRepImageUploadWarning: true,
reputationToPostImages: 10,
bindNavPrevention: true,
postfix: "",
imageUploader: {
brandingHtml: "Powered by u003ca class="icon-imgur-white" href="https://imgur.com/"u003eu003c/au003e",
contentPolicyHtml: "User contributions licensed under u003ca href="https://creativecommons.org/licenses/by-sa/3.0/"u003ecc by-sa 3.0 with attribution requiredu003c/au003e u003ca href="https://stackoverflow.com/legal/content-policy"u003e(content policy)u003c/au003e",
allowUrls: true
},
onDemand: true,
discardSelector: ".discard-answer"
,immediatelyShowMarkdownHelp:true
});
}
});
Sign up or log in
StackExchange.ready(function () {
StackExchange.helpers.onClickDraftSave('#login-link');
});
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Required, but never shown
StackExchange.ready(
function () {
StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2faskubuntu.com%2fquestions%2f1126129%2fhow-to-start-a-program-with-its-name%23new-answer', 'question_page');
}
);
Post as a guest
Required, but never shown
2 Answers
2
active
oldest
votes
2 Answers
2
active
oldest
votes
active
oldest
votes
active
oldest
votes
Add this to your ~/.bashrc
file
export PATH=/usr/local/MATLAB/R2017a/bin:$PATH
3
It didn't work at first, but a little research on the net solved it. It should be without "matlab" at the end. Like this: export PATH=/usr/local/MATLAB/R2017a/bin:$PATH
– sarp
Mar 16 at 9:27
add a comment |
Add this to your ~/.bashrc
file
export PATH=/usr/local/MATLAB/R2017a/bin:$PATH
3
It didn't work at first, but a little research on the net solved it. It should be without "matlab" at the end. Like this: export PATH=/usr/local/MATLAB/R2017a/bin:$PATH
– sarp
Mar 16 at 9:27
add a comment |
Add this to your ~/.bashrc
file
export PATH=/usr/local/MATLAB/R2017a/bin:$PATH
Add this to your ~/.bashrc
file
export PATH=/usr/local/MATLAB/R2017a/bin:$PATH
edited Mar 16 at 12:31
pomsky
33.6k11105137
33.6k11105137
answered Mar 16 at 9:13
matcheekmatcheek
1436
1436
3
It didn't work at first, but a little research on the net solved it. It should be without "matlab" at the end. Like this: export PATH=/usr/local/MATLAB/R2017a/bin:$PATH
– sarp
Mar 16 at 9:27
add a comment |
3
It didn't work at first, but a little research on the net solved it. It should be without "matlab" at the end. Like this: export PATH=/usr/local/MATLAB/R2017a/bin:$PATH
– sarp
Mar 16 at 9:27
3
3
It didn't work at first, but a little research on the net solved it. It should be without "matlab" at the end. Like this: export PATH=/usr/local/MATLAB/R2017a/bin:$PATH
– sarp
Mar 16 at 9:27
It didn't work at first, but a little research on the net solved it. It should be without "matlab" at the end. Like this: export PATH=/usr/local/MATLAB/R2017a/bin:$PATH
– sarp
Mar 16 at 9:27
add a comment |
You can either add /usr/local/MATLAB/R2017a/bin/
to your PATH or create another script in a proper directory of executables in your home.
To do the second one follow the steps below.
- Create a folder named
bin
in your home directory. (Note: This assumes the directory~/bin/
is included in your PATH. If it isn't, you need to add it to your path first.) - Create a text file named
matlab
(the command you want to use) in the the aforementioned crated folder (i.e. in~/bin/
).
Add the following lines to the
matlab
file
#!/bin/bash
/usr/local/MATLAB/R2017a/bin/matlab
- Save the
matlab
file and make it executable.
add a comment |
You can either add /usr/local/MATLAB/R2017a/bin/
to your PATH or create another script in a proper directory of executables in your home.
To do the second one follow the steps below.
- Create a folder named
bin
in your home directory. (Note: This assumes the directory~/bin/
is included in your PATH. If it isn't, you need to add it to your path first.) - Create a text file named
matlab
(the command you want to use) in the the aforementioned crated folder (i.e. in~/bin/
).
Add the following lines to the
matlab
file
#!/bin/bash
/usr/local/MATLAB/R2017a/bin/matlab
- Save the
matlab
file and make it executable.
add a comment |
You can either add /usr/local/MATLAB/R2017a/bin/
to your PATH or create another script in a proper directory of executables in your home.
To do the second one follow the steps below.
- Create a folder named
bin
in your home directory. (Note: This assumes the directory~/bin/
is included in your PATH. If it isn't, you need to add it to your path first.) - Create a text file named
matlab
(the command you want to use) in the the aforementioned crated folder (i.e. in~/bin/
).
Add the following lines to the
matlab
file
#!/bin/bash
/usr/local/MATLAB/R2017a/bin/matlab
- Save the
matlab
file and make it executable.
You can either add /usr/local/MATLAB/R2017a/bin/
to your PATH or create another script in a proper directory of executables in your home.
To do the second one follow the steps below.
- Create a folder named
bin
in your home directory. (Note: This assumes the directory~/bin/
is included in your PATH. If it isn't, you need to add it to your path first.) - Create a text file named
matlab
(the command you want to use) in the the aforementioned crated folder (i.e. in~/bin/
).
Add the following lines to the
matlab
file
#!/bin/bash
/usr/local/MATLAB/R2017a/bin/matlab
- Save the
matlab
file and make it executable.
edited Mar 19 at 10:14
answered Feb 15 at 11:46
pomskypomsky
33.6k11105137
33.6k11105137
add a comment |
add a comment |
Thanks for contributing an answer to Ask Ubuntu!
- Please be sure to answer the question. Provide details and share your research!
But avoid …
- Asking for help, clarification, or responding to other answers.
- Making statements based on opinion; back them up with references or personal experience.
To learn more, see our tips on writing great answers.
Sign up or log in
StackExchange.ready(function () {
StackExchange.helpers.onClickDraftSave('#login-link');
});
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Required, but never shown
StackExchange.ready(
function () {
StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2faskubuntu.com%2fquestions%2f1126129%2fhow-to-start-a-program-with-its-name%23new-answer', 'question_page');
}
);
Post as a guest
Required, but never shown
Sign up or log in
StackExchange.ready(function () {
StackExchange.helpers.onClickDraftSave('#login-link');
});
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Required, but never shown
Sign up or log in
StackExchange.ready(function () {
StackExchange.helpers.onClickDraftSave('#login-link');
});
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Required, but never shown
Sign up or log in
StackExchange.ready(function () {
StackExchange.helpers.onClickDraftSave('#login-link');
});
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
1
You can add it to "path", or create an alias.
– Pilot6
Mar 16 at 9:09