File: arguments.go

package info (click to toggle)
golang-github-docopt-docopt-go 0.6.2%2Bgit20180111.ee0de3b-1
  • links: PTS, VCS
  • area: main
  • in suites: bookworm, bullseye, forky, sid, trixie
  • size: 284 kB
  • sloc: makefile: 10
file content (29 lines) | stat: -rw-r--r-- 612 bytes parent folder | download
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
package main

import (
	"fmt"
	"github.com/docopt/docopt-go"
)

var usage = `Usage: arguments [-vqrh] [FILE] ...
       arguments (--left | --right) CORRECTION FILE

Process FILE and optionally apply correction to either left-hand side or
right-hand side.

Arguments:
  FILE        optional input file
  CORRECTION  correction angle, needs FILE, --left or --right to be present

Options:
  -h --help
  -v       verbose mode
  -q       quiet mode
  -r       make report
  --left   use left-hand side
  --right  use right-hand side`

func main() {
	arguments, _ := docopt.ParseDoc(usage)
	fmt.Println(arguments)
}