Комментарии:
hi
ОтветитьWhat you created is essentially a shell script (those files usually have ".sh" at the end to distinguish between regular commands, which are really just ELF executables - programs - and text based scripts). If you want to create a new command, you could create a shell script like that (by default it will assume the default or running shell, which in majority of Linux distros is going to be Bash, you can change that or specify with something called "shebang", which is essentially a special comment at the top that starts with #! and immediately after - no space in between - you type in the path to the shell you want to use, and even supply arguments), and if you don't want to use the ".sh" part, you eighter create the file without it in the name, or you could create an alias that would map a command to a script file. Easily done.
Ответитьthanks
Ответитьyou've explained well, keep it up. Thankyou
ОтветитьThanks, buddy that's what I was looking for...
ОтветитьI'm glad I found this video, I definitely prefer it over creating an alias in my .bashrc
ОтветитьMy boy what is that background
Ответитьyou've explained it well, thanks
Ответитьi been trying to compile a schript (sh) to make an executable binary for linux but it didnt work any way to make this work?> theres no error?
ОтветитьSuggestions! How to Make command line/syntax like When I type help it show the info and When I type firewall it show me option to Enable or disable.
ОтветитьThere's an even easier way.
Open the file ".bashrc" (located in your home directory, it's a hidden folder)
Type:
alias helloworld="echo \"hello world\""
Save the document
Type in the terminal:
source .bashrc (this updates the changes on your system)
now you can use helloworld as a command.
Write a utility utility called junk that satisfies satisfies the following following
specification:
• Utility: junk [-l] [-p] { fileName }* p] { fileName }*
– junk is a replacement for the rm utility.
– R h at er than removing files, it moves them into the
subdirectory ".junk" in your home directory.
– If " junk" ".junk" doesn't doesn't exist, it is automatically automatically created created.
– The ‐l option lists the current contents of the ".junk"
directory, and
– the ‐p option purges ".junk".
if u could please help me solve this
hello how i can contact u?
Ответитьgood
Ответитьaint unix so awsome lmao
ОтветитьHey would you please name you icon theme😅
I do just love that icons🤩
Which linux distro is this?
ОтветитьNone of these commands are working for me.
ОтветитьYou are amazing.
Ответитьeasier way; sudo apt install gedit: enter password and download: type: gedit .bash_aliases: when file open type: alias YOURWORD='COMMAND' : go back to terminal and type source .bash_aliases : if you don't write this after saving then it won't work ps since it is .bash_aliases the . means that its hidden witch is for if anyone finds it in your file manager they can't make it to whatever they want, for example, they can make echo do rm -rf
PS if your do rm - rf in terminal it will mess up your computer so you can't blame me for mentioning it
By taking this advice and putting it in my terminal (name of person) will not hold YZ inventions accountable if this doesn't work