Giter Club home page Giter Club logo

slib's Introduction

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.

slib's People

Contributors

swelljoe avatar iliajie avatar

Watchers

 avatar

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.