Hi there.
I need to open a node.js script with the terminal from the start menu.
I tried this, which doesn't work:
mate-terminal -e "node /home/chris/.SMLoadr/SMLoadr.js"
Any idea how I can do this?
How do I start a terminal program from the start menu?
Forum rules
There are no such things as "stupid" questions. However if you think your question is a bit stupid, then this is the right place for you to post it. Stick to easy to-the-point questions that you feel people can answer fast. For long and complicated questions use the other forums in the support section.
Before you post read how to get help. Topics in this forum are automatically closed 6 months after creation.
There are no such things as "stupid" questions. However if you think your question is a bit stupid, then this is the right place for you to post it. Stick to easy to-the-point questions that you feel people can answer fast. For long and complicated questions use the other forums in the support section.
Before you post read how to get help. Topics in this forum are automatically closed 6 months after creation.
-
- Level 1
- Posts: 47
- Joined: Tue Aug 29, 2017 8:08 pm
How do I start a terminal program from the start menu?
Last edited by LockBot on Wed Dec 28, 2022 7:16 am, edited 1 time in total.
Reason: Topic automatically closed 6 months after creation. New replies are no longer allowed.
Reason: Topic automatically closed 6 months after creation. New replies are no longer allowed.
System: Intel© Core™ i9-10900K CPU @ 3.70GHz × 10
NVIDIA Corporation GA104M [GeForce RTX 3080]
NVIDIA Corporation GA104M [GeForce RTX 3080]
-
- Level 1
- Posts: 47
- Joined: Tue Aug 29, 2017 8:08 pm
Re: How do I start a terminal program from the start menu?
BUMP
System: Intel© Core™ i9-10900K CPU @ 3.70GHz × 10
NVIDIA Corporation GA104M [GeForce RTX 3080]
NVIDIA Corporation GA104M [GeForce RTX 3080]
Re: How do I start a terminal program from the start menu?
It sounds simple, and it should be simple, but it's a bit of a PITA.ChrisHvide wrote: ⤴Sun May 20, 2018 8:59 pmI tried this, which doesn't work:
mate-terminal -e "node /home/chris/.SMLoadr/SMLoadr.js"
Any idea how I can do this?
For instance...
File "aaa" is executable and in my PATH, and is:
Code: Select all
echo $HOME
ls -l $HOME
Code: Select all
xfce4-terminal -e="aaa"
Change aaa to
Code: Select all
echo $HOME
ls -l $HOME
read
It works if the script puts up a GUI (content of aaa = "gimp"), or waits for input...
Edit:
https://askubuntu.com/questions/484993/ ... nal-window
There's
Code: Select all
xfce4-terminal --hold -e="aaa"
So here's my free advice: make a two-line executable script in your PATH (call it "doit")
Code: Select all
node /home/chris/.SMLoadr/SMLoadr.js
read
Code: Select all
mate-terminal -e "doit"
-x sh -c "!!; bash
syntax at that link.Please edit your original post title to include [SOLVED] if/when it is solved!
Your data and OS are backed up....right?
Your data and OS are backed up....right?
-
- Level 1
- Posts: 47
- Joined: Tue Aug 29, 2017 8:08 pm
Re: How do I start a terminal program from the start menu?
Ah of course I can do it like that.
Thank you so much
Thank you so much
System: Intel© Core™ i9-10900K CPU @ 3.70GHz × 10
NVIDIA Corporation GA104M [GeForce RTX 3080]
NVIDIA Corporation GA104M [GeForce RTX 3080]
- cabbagetreemo
- Level 3
- Posts: 147
- Joined: Fri Mar 31, 2017 2:36 am
- Location: Spain
Re: How do I start a terminal program from the start menu?
Another method, which worked on Cinnamon is to create a bash file /path/to/your/bash/file which executes your terminal commands. Make it executable
and then create a file in /usr/share/application/<name>.desktop where <name> can be whatever you want
The contents of the file should look like
Code: Select all
chmod u=rwx /path/to/your/bash/file
The contents of the file should look like
Code: Select all
[Desktop Entry]
Encoding=UTF-8
Exec=/path/to/your/bash/file
Icon=/path/to/an/image #(A path to a .png file which will supply the icon in the menu)
Type=Application
Terminal=false
Comment= #I think you can put more or less anything here, something descriptive would be good
Name= #The name you want to appear in the menu
GenericName= #I don't think this matters
StartupNotify=false
Categories= #Which ever submenu is appropriate e.g. Office