Coder Social home page Coder Social logo

simple-bash-scripts's Introduction

A collection of simple Bash scripts.

Getting Started

  1. Hello.sh: get a simple output
  2. Process.sh: execute more than one command in a script
  3. Interactive.sh: a simple but very much interactive script
  4. Special-Pattern.sh: draw a diamond pattern with dots(.)
  5. While-Read.sh: read lines from a file using while loop
  6. Read-Menu.sh: display a menu for system information
  7. While-Menu.sh: a repeated menu for system information
  8. Affect.sh: print a spinner loader
  9. Colorful.sh: provide you with the output of several colours
  10. Convertlowercase.sh: convert data either from the file or standard input to lowercase
  11. up.sh: move up a directory in shell script
  12. List-dir.sh: list files in a directory
  13. Count-lines.sh: print out the line number of each file in current directory
  14. Randomfile.sh: create unique file/folder automatically with date and time stamp
  15. Random-emoji.sh: print ramdom emojis
  16. pomodoro.sh: a simple pomodoro app written in bash

Programming

  1. VersionCompare.sh: compare two version number

Utility

  1. Encrypt.sh: encrypt a file/folder with password
  2. Archive-and-encrypt.sh: archive a path into a file and encrypt the file
  3. weather.sh: check the weather in a specified location or using the geolocation of the ip address by default.
  4. WhereIP.sh: Get location of an IP address.

System Administration

  1. DirectorySize.sh: output a specified directory's size
  2. Test-File.sh: evaluate the status of a file/directory
  3. Server-Health.sh: report server related information
  4. CPU.sh: report if CPU usage exceeds the threshold
  5. Disk-Space.sh: check if the disk space crosses the limit
  6. CollectNetworkInfo.sh: gather information related to server
  7. RemoteBackup.sh: backup a local file into a remote server
  8. HardwareInfo.sh: show hardware information for systems Linux
  9. Get-Temperature.sh: show CPU temperature

Math

  1. Addition.sh: perform addition of two numbers
  2. Subtraction.sh: perform subtraction of two numbers
  3. Multiplication.sh: perform multiplication of two numbers
  4. Division.sh: perform division of two numbers
  5. Simplecacl.sh: a simple calculator
  6. Table.sh: print table of any number
  7. EvenOdd.sh: check if a number input from standard input is odd or even
  8. Factorial.sh: generate the factorial of a number
  9. Armstrong.sh: check if a provided number is Armstrong or not
  10. Prime.sh: check if a number is prime or not
  11. Fibonacci.sh: test if a number being entered is a Fibonacci or not
  12. Decimal2Binary.sh: convert Decimal Number to Binary
  13. Binary2Decimal.sh: convert Binary Number back to decimal
  14. Decimal2Hex.sh: convert Decimal Number to Hex
  15. Hex2Decimal: convert Hex number back to Decimal

Image manipulation

  1. thumbnail.sh: create 400px thumbnails from images in a folder

License

MIT

simple-bash-scripts's People

Contributors

akki-akshat avatar amaurybsouza avatar b-kay avatar code-blooded-human avatar eepykate avatar iamcco avatar kiailandi avatar mendel5 avatar nyxyn avatar playfloor avatar robatipoor avatar rohit-rannavre avatar ruanyf avatar starandtina avatar williamspaulm avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

simple-bash-scripts's Issues

Contribution

I want to contribute in your repository, please help me in this regard. I am a new github user

Create github action to test the shell scripts

Lets create a github action scripts to check if the shell scripts work and if a newly added one work as well.

Creating for all shell scripts can be hard, so if you guys feel its a good idea, we can divide the work and create issue and PR for each shell script in this.

How to run text menu script automatically on every reboot

This script has an output, which shows a text menu with few options 1,2,3..

What I want to do!!!

I want to run this script automatically and automatically selects option 2 on every start/reboot of Linux system.

I need some one to help me

#!/bin/bash

Bash Menu Script Example

PS3='Please enter your choice: '
options=("Option 1" "Option 2" "Option 3" "Quit")
select opt in "${options[@]}"
do
case $opt in
"Option 1")
echo "you chose choice 1"
;;
"Option 2")
echo "you chose choice 2"
;;
"Option 3")
echo "you chose choice 3"
;;
"Quit")
break
;;
*) echo invalid option;;
esac
done

Output is as follows:
"Choose your option:"

  1. Option 1
  2. Option 2
  3. Option 3
  4. Quit

I also know that to run it automatically on every reboot, I need to give the complete path in /etc/rc.local file

But how to run this automatically on every reboot with automatic selection of option 2

License ?

Hello, under what license are these example scripts released under ? I would like to learn bash scripting from them. Thank-you.

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.