shdoc

command module
v0.9.1 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Apr 1, 2024 License: Apache-2.0 Imports: 2 Imported by: 0

README

GitHub Actions CI Status GoReportCard codebeat badge GitHub Actions CodeQL Status Coverage Status

Usage DemoInstallationUsageTest & Coverage StatusContributingLicense


shdoc is a tool for viewing and exporting documentation for shell scripts.

Usage Demo

demo

Installation

From source

Make sure you have a working Go 1.18+ workspace (instructions), then:

go install github.com/essentialkaos/shdoc@latest

Prebuilt binaries

You can download prebuilt binaries for Linux and macOS from EK Apps Repository.

To install the latest prebuilt version of bibop, do:

bash <(curl -fsSL https://apps.kaos.st/get) shdoc

Command-line completion

You can generate completion for bash, zsh or fish shell.

Bash:

sudo shdoc --completion=bash 1> /etc/bash_completion.d/shdoc

ZSH:

sudo shdoc --completion=zsh 1> /usr/share/zsh/site-functions/shdoc

Fish:

sudo shdoc --completion=fish 1> /usr/share/fish/vendor_completions.d/shdoc.fish

Usage

Usage: shdoc {options} script

Options

  --output, -o file      Path to output file
  --template, -t name    Name of template
  --name, -n name        Overwrite default name
  --no-color, -nc        Disable colors in output
  --help, -h             Show this help message
  --version, -v          Show version

Examples

  shdoc script.sh
  Parse shell script and show documentation in console

  shdoc script.sh -t markdown -o my_script.md
  Parse shell script and render documentation to markdown file

  shdoc script.sh -t /path/to/template.tpl -o my_script.ext
  Parse shell script and render documentation with given template

  shdoc script.sh myFunction
  Parse shell script and show documentation for some constant, variable or method

Test & Coverage Status

Branch CI Coveralls
master CI Coverage Status
develop CI Coverage Status

Contributing

Before contributing to this project please read our Contributing Guidelines.

License

Apache License, Version 2.0

Documentation

The Go Gopher

There is no documentation for this package.

Directories

Path Synopsis
render

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL