Skip to content

hngabo-lang/deploy_agent_hngabo-lang

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

3 Commits
 
 
 
 

Repository files navigation

deploy_agent_hngabo-lang

This script provides a safe and automated way to initialize an attendance tracking project. It ensures consistency, handles edge cases gracefully, and protects incomplete work through automatic archiving.

functions with specific responsibilities: a. place for validation

  • Checks required tools (e.g., Python availability)
  • Ensures the system is ready to run the project

b. fetch prog name

  • Prompts the user for a valid project name
  • Validates the input format

c. make directory structure

  • Builds the folder hierarchy
  • Prevents overwriting existing directories

d. construct application files

  • Creates required project files
  • Populates default configuration

e. adjust thresholds

  • Allows optional customization of warning/failure values
  • Validates numeric ranges

f. check structure

  • Confirms all files and directories were created successfully

Archive Trigger

When the user interrupts the script (ctrl+c) the script automatically triggers and archiving process.

  • The partially created project is compressed into a .tar.gz archive
  • The archive preserves the current work state
  • The incomplete directory is safely removed

This prevents leaving broken or inconsistent project structures on the system.

Invalid user input

  • Rejects empty or malformed project names
  • Ensures numeric values fall within allowed ranges

Existing directories

  • Prevents accidental overwriting
  • Prompts the user to choose another name

Missing dependencies

  • Detects if required software is unavailable
  • Stops execution with a clear error message

Interrupted execution

  • Automatically archives incomplete work
  • Cleans up safely using signal trapping

Usage

In terminal: cd deploy_agent_hngabo-lang ,then type: bash setup.sh (then interact with the script)

About

No description, website, or topics provided.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

 
 
 

Contributors

Languages