Christian Forums

This is a sample guest message. Register a free account today to become a member! Once signed in, you'll be able to participate on this site by adding your own topics and posts, as well as connect with other members through your own private inbox!

Learning to use the "Bash" command line

Vince

Member
Folks, "bash" is a command-line program in Linux. In early August, it will be introduced to Windows 10. I am struggling to learn how to use it, although (being a geek) it is interesting.

If you don't know what I'm talking about, in your Linux program, find "Terminal." That will get you to the bash command line.

Since no one has written "Bash for Dummies," elementary suggestions are appreciated.
 
Whatever else you do Vince, teach the kids how to play with the Command Line and also learn how to write BASH commands and teach them that. I am terrible at it with the MS disconnecting me and with the BASH Commands the world can be conquered. If I want to auto function anything, these days, I must go online and use examples before I succeed.

Also, in teaching BASH Program writing, expect blowback from the hard Left Wing Teachers because the truly despise a free thinking mind, they see us as very dangerous. In reality, we are only a danger to their narrow-minded World Control Agenda but they find that as possibly devastating.

God bless and may He bless you as you work with the youngsters.
 
I feel ridiculous, teaching readers how to use Bash when I don't understand it myself (yet). But let's give it a go.

Find "Terminal" in your Linux system and open it. It will give you the bash command line. Make sure that the line ends in a $. That means that none of your commands can change your system. If your command line ends in #, you need to get out. Something is wrong, and you have the ability to really foul yourself up.

Here are some harmless commands for getting information. Remember that these commands are case-sensitive:

pwd Print working directory

ls List files and directories

cd Change directory

ls -l List the files in the working directory in long format

ls /bin List the files in the bin directory, or in any other directory specified

less --help opens a list of possible less commands

cd /home takes you to the home file. The user is allowed to use this file.

cat /etc/shells opens a list of shells available on your system..Huh? Bash is a "shell." If you have bash, then you also have a simpler shell called "sh." You probably have other shells as well.
 
Last edited:
The attached file is pdf in nature and is a very handy cheat sheet. If any of you ever learn how to operate the Operating Systems in your computers you will never again be trapped using the GUI (guey or Graphic User Interface when it fails to appear). The BASH Commands are for DRDOS but except that DRDOS has many more useful switches than does the operating system of windoze, MSDOS, the system was stolen from Unix but seriously lacking in development.
 
Oh, another thought to calm nerves, if you own a Cell Phone or a Tablet that does not run windoze, Android, Kindle and all the others run on the Linux Kernel. There might be something not running on a Linux Kernel and DRDOS but not much. MSDOS is not only underdeveloped but MS is also lawsuit stupid, limiting it's development.
 
Bill, your cheat sheet is very good! I've been fooling around with it.
With my MS, it is critical for me because I am stubborn and refuse to give up my IT endeavors. I'm trying to get a man to deliver two of his XP machines right now so I can install Mint on them and end his User Issues with virus protection issues.

Thus I still need DOS.
 
What, you haven't been able to find the terminal? Right-click any empty spot on your desktop and select "Open Terminal."
 
Okay, I need some help.

Typing vim :syntax enable onto the bash command line opens a word processor. It gives me a list of options:

The program 'vim' can be found in the following packages:
* vim
* vim-gnome
* vim-tiny
* vim-athena
* vim-athena-py2
* vim-gnome-py2
* vim-gtk
* vim-gtk-py2
* vim-gtk3
* vim-gtk3-py2
* vim-nox
* vim-nox-py2
Try: sudo apt install <selected package>

If I understand correctly, I only want one of these packages. If so, which one?
 
Okay, I need some help.

Typing vim :syntax enable onto the bash command line opens a word processor. It gives me a list of options:

The program 'vim' can be found in the following packages:
* vim
* vim-gnome
* vim-tiny
* vim-athena
* vim-athena-py2
* vim-gnome-py2
* vim-gtk
* vim-gtk-py2
* vim-gtk3
* vim-gtk3-py2
* vim-nox
* vim-nox-py2
Try: sudo apt install <selected package>

If I understand correctly, I only want one of these packages. If so, which one?
I suspect any version will do the work for you. I use Gedit. I also know most prefer Vim.
 
Arrgh, it won't work Bill! they want my password. I deliberately set up Linux without a password to avoid problems.
 
"Bash on Fire" is one of several harmless Bash programs that don't accomplish anything useful. They don't work on every computer. But this harmless program makes multi-colored symbols scroll across your terminal.

Open a terminal and cut and paste this into it, then press Enter. Let me know if it works on your rig. I've tried three others that don't work on mine.

#!/bin/bash
X=`tput cols` Y=`tput lines` e=echo M=`eval $e {1..$[X*Y]}` P=`eval $e {1..$X}`;
B=(' ' '\E[0;31m.' '\E[0;31m:' '\E[1;31m+' '\E[0;33m+' '\E[1;33mU' '\E[1;33mW');
$e -e "\E[2J\E[?25l" ; while true; do p=''; for j in $P; do p=$p$[$RANDOM%2*9];
done;O=${C:0:$[X*(Y-1)]}$p;C='' S='';for p in $M;do # _-=[ BruXy.RegNet.CZ ]=-_
read a b c d <<< "${O:$[p+X-1]:1} ${O:$[p+X]:1} ${O:$[p+X+1]:1} ${O:$[p+X+X]:1}"
v=$[(a+b+c+d)/4] C=$C$v S=$S${B[$v]}; done; printf "\E[1;1f$S"; done # (c) 2012
 
Back
Top