How to make shortcut for frequently used terminal commands in ubuntu

ilies ouldmenouer :

I have this command :

$ anbox session-manager --single-window --window-size=400,650

and i need to run it frequently, is there any way to avoid rewriting it every time I need it ?

ehsan ahmadi :

For permanently use

  1. run this

    echo 'alias customcommand="anbox session-manager --single-window --window-size=400,650"' >> /home/$(USER)/.bashrc
    
  2. open new terminal

  3. now you can run customcommand and get that response

Collected from the Internet

Please contact [email protected] to delete if infringement.

edited at
0

Comments

0 comments
Login to comment

Related

Store frequently used terminal commands in a file

How can I make a list with most used commands in terminal?

how to create a "shortcut" in Microsoft Word for frequently used actions

How to make Ubuntu update the kernel less frequently?

How to save a frequently used SSH host for access via terminal?

How to make a shortcut to set title in gnome-terminal tab (ubuntu 13.10)?

How to make bash keep most frequently used history entries for ever?

Opening frequently used software using terminal with user assigned short names in Ubuntu 20.04

Define commands for frequently used text in knitr

How can I make a Windows shortcut that launches Bash and runs commands?

How do I make a keyboard shortcut for Terminal in CentOS 7

Using Terminal commands in Ubuntu

Ubuntu terminal commands and usage

How to exit all terminal instances (keyboard shortcut) Ubuntu 16.04?

How to create shortcut on ubuntu to open a terminal with some folder?

Ubuntu Terminal "Shortcut-Key"

How to unbind a shortcut in a terminal

Keyboard shortcut to jump between terminal commands

Shortcut to open Terminal and run some commands

how to make a file that opens the terminal and runs some commands

Terminal appears with much delay when shortcut is used

How to add shortcut letters or words in Android Studio's Terminal for frequent commands?

How to give ubuntu terminal commands from a program in GO language?

How can I use terminal commands to access Ubuntu menu items?

Static IP in Ubuntu 13.10 & How to loop/run terminal commands at startup

Best way to gain quick access to frequently used directory in linux terminal

Issue multiple commands in ubuntu terminal

How to send terminal commands

How to create terminal shortcut to desktop?