Skip to content
This repository was archived by the owner on Jul 6, 2025. It is now read-only.

IMS-coding-projects/M122-2

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

2 Commits
 
 
 
 
 
 

Repository files navigation

B-Backup

Project Status

B-Backup is a Bash tool designed to simplify the process of backing up files and directories. It offers a range of features to ensure seamless backup and recovery of data, making it a reliable and user-friendly solution for managing backups.


Features

B-Backup provides the following features:

  • Backup: Back up files and directories to a hidden location on the user's system.
  • Encryption: Encrypt backups using PKZIP encryption.
  • Compression: Compress backups using DEFLATE compression.
  • Deletion: Optionally delete original files after backup.
  • Restore: Restore backups to the original or a custom location.
  • Export: Export backups to a custom location.
  • Logging: Log all actions for future reference.
  • List Backups: View all backups created by B-Backup.
  • Delete Backups: Remove individual backups.
  • Search Files: Search for specific files within backups.
  • Error Handling: Gracefully handle errors with helpful messages.
  • Help Menu: Access detailed help directly from the script.

Minimum Requirements

  • Operating System: Tested on Ubuntu 20.04 and Kali Linux 2024.1.
  • Bash Version: Minimum tested version is 5.1.16.
  • Dependencies:
    • zip, unzip, mv, rm, ls, grep, echo, read, date, cat, printf (all standard tools available on most Linux distributions).

Note: B-Backup cannot run with root privileges. Running the script as root will result in an error message and termination.


Installation

  1. Clone the repository:
    git clone https://github.com/IMS-coding-projects/M122-2.git
  2. Navigate to the project directory:
    cd M122-2
  3. Make the script executable:
    chmod +x B-Backup.sh

Usage

Run the script using the following command:

B-Backup.sh

Main Menu Options:

  1. Manage Backups: Create, restore, delete, or search backups.
  2. Help: Access detailed documentation.
  3. Display Logs: View the log file.
  4. Export All Backups: Export all backups to a specified location.
  5. Uninstall: Remove all backups and logs.
  6. Exit: Exit the script.

Testing

The script has been rigorously tested on various Linux distributions and scenarios. Below are some key test cases:

Test Number Description Expected Outcome Result
1 Start the script for the first time. Creates necessary folders and files. ✅ Pass
2 Create a backup with encryption and compression. Backup is created successfully. ✅ Pass
3 Restore a backup to the original location. Backup is restored successfully. ✅ Pass
4 Search for a specific file in a backup. File is found and can be extracted. ✅ Pass
5 Run the script with root privileges. Script exits with an error message. ✅ Pass

For a full list of tests, refer to the Documentation.


Screenshots

Main Menu

Main Menu

Backup Management

Backup Management


License

This project is licensed under the MIT License. See the LICENSE file for details.

About

Source Code Repository of M122 Part 2

Topics

Resources

Stars

Watchers

Forks

Languages