Ubuntu: How to save newly created commands in the terminal



Question:

is there anyway to save newly created commands in the terminal? Every time, I exit the terminal, all of the commands I created are lost.

Thank you.


Solution:1

  1. Use the â†' key
  2. Use the reverse search integrated in the terminal by pressing ctrl and r
  3. Use a bin file
    • open gedit by typing gedit in the dash
    • enter #/bin/bash in the first row
    • now enter each command in a new line
    • save it in /home/[username]/bin/ without an ending (gedit does it automatically right)
    • go into nautilus (the data explorer) and right click the file
    • go on properties and check the box "allow executing file" under properties
    • now just click doubled
    • a window saying run in terminal,display,cancel,run
    • just click run in terminal or run
    • now you're script must run...

an example for the file:

#/bin/bash  gnome-system-settings  

The first one is easier to use with one command, but the second one is better for running multiple ones after each other.


Note:If u also have question or solution just comment us below or mail us on toontricks1994@gmail.com
Previous
Next Post »