Just Enough Linux

sudo apt update # updates the package list from repositories (does not install) sudo apt upgrade -y # upgrades all upgradable packages (-y auto-confirms) Install utility sudo apt install open-vm-tools # installs essential VMware guest utilities sudo apt install open-vm-tools-desktop # installs GUI support for VMware tools linux boot process BIOS # Basic Input/Output System: performs hardware checks (POST), then hands off to bootloader BOOTLOADER # e.g., GRUB: loads the kernel into memory KERNEL # Core of the OS: manages hardware, memory, processes, and drivers INIT # Initializes system processes (now typically systemd) LOGIN # User authentication screen or shell prompt Check the shell you are using which $SHELL Writing script create a script file called test.bash touch test.sh And paste: echo "hello world" Run by typing zsh test.sh Or run with ./test.sh You can write any linux command echo "hello world" ls date Linux command pwd - print working directory whoami - display current username history - show all commands that have been used date - current date time man - manual (man pwd, man date) who - shows who is logged in w - same as who sudo su - login as a super user Variable NB: ensure no space between the var and equal to sign var="abayomi" echo $var mathematical operation for operations use (()) num1=8 num2=9 num3=$((num1 + num2)) echo $num3 Take input from users echo "enter first number: " read var1 echo "enter second number: " read var2 answer=$((var1 + var2)) echo $answer Shell scripting if you don write the shell to use your os will take the default #!/bin/zsh echo "hello james" to give it executabel rights chmod 755 test.sh A script to create a nodejs app #!/bin/zsh echo "

Apr 22, 2025 - 19:33
 0
Just Enough Linux
sudo apt update           # updates the package list from repositories (does not install)
sudo apt upgrade -y       # upgrades all upgradable packages (-y auto-confirms)

Install utility


sudo apt install open-vm-tools           # installs essential VMware guest utilities
sudo apt install open-vm-tools-desktop   # installs GUI support for VMware tools

linux boot process

BIOS       # Basic Input/Output System: performs hardware checks (POST), then hands off to bootloader
BOOTLOADER # e.g., GRUB: loads the kernel into memory
KERNEL     # Core of the OS: manages hardware, memory, processes, and drivers
INIT       # Initializes system processes (now typically systemd)
LOGIN      # User authentication screen or shell prompt

Check the shell you are using

which $SHELL

Writing script

create a script file called test.bash

touch test.sh

And paste:

echo "hello world"

Run by typing

zsh test.sh

Or run with

./test.sh

You can write any linux command

echo "hello world"
ls
date

Linux command

pwd - print working directory
whoami - display current username
history - show all commands that have been used 
date - current date time 
man - manual (man pwd, man date) 
who - shows who is logged in 
w - same as who
sudo su - login as a super user

Variable

NB: ensure no space between the var and equal to sign

var="abayomi"
echo $var

mathematical operation

  • for operations use (())
num1=8
num2=9
num3=$((num1 + num2))
echo $num3

Take input from users

echo "enter first number: "
read var1
echo "enter second number: "
read var2

answer=$((var1 + var2))
echo $answer

Shell scripting

if you don write the shell to use your os will take the default

#!/bin/zsh   
echo "hello james"

to give it executabel rights

chmod 755 test.sh

A script to create a nodejs app

#!/bin/zsh

echo "