GV

GeezerVison

The World Wide Web, restored to 800 pixels of glory.

Home|About|Gaming cabinet|Archives|How it works|Starter sites

On this site

  • Sign in
  • ActionsCI/CD and automation
  • CodespacesCloud development environments
  • All Features
  • Documentation
  • Training
  • Certifications
  • Build with Copilot
  • Customize Copilot
  • Integrations
  • Trending repos
  • GitHub Sponsors
  • Developer articles
  • Enterprises

This view

  • Original page
  • New address

GeezerVison is showing github.com — slib/README.md at master · virtualmin/slib

Expand file tree

/

README.md

Copy path
More file actions
More file actions

Latest commit

 

History

History
History
29 lines (19 loc) · 1.28 KB
/

README.md

Copy path

File metadata and controls

29 lines (19 loc) · 1.28 KB
Raw
Copy raw file
Download raw file
Outline
Edit and raw actions

Build Status

slib

Library of POSIX shell functions used by Virtualmin install scripts.

This is a bundle of a bunch of functions used by virtualmin-install (and probably other installers in the future). Some of the bigger, more complex, functions have their own repo (spinner, slog, and run_ok, specifically), and are merged in here periodically. Unless you're building something very similar to the Virtualmin install script, you make want to pick and choose.

It is tested regularly on bash and dash. Other POSIX-y shells may or may not work.

Usage

Source the library, and use its functions.

    . ./slib.sh

    # Log an error and output something about it to the user in red
    log_error "Oh no!"

    # Print a message, run a command, wait with a spinner, and print a status indicator,
    # in color and with Unicode fun.
    run_ok "touch somefile" "touching a file"

    # Use whatever package manager is available and install the named package
    # wait with a spinner, and print a status indicator in color.
    any_install "gcc"

Full docs will be written soon.

You are visitor 01402792 — GeezerVison does not store the pages you look up.
Best viewed with Netscape Navigator 4.7 or Internet Explorer 6 at 800×600. No cookies required.