• Home
  • Line#
  • Scopes#
  • Navigate#
  • Raw
  • Download
1#!/bin/bash
2
3rst2man=$1
4input=$2
5output=$3
6
7out_dir=$(dirname "${output}")
8in_file=$(basename "${input}")
9
10# rst2man doesn't handle multiple source directories well, and since defs.rst is
11# generated we first need to move it all into the build dir
12cp "$input" "$out_dir"
13
14${rst2man} "$out_dir/$in_file" "${output%.gz}"
15
16rm -f "${output}"
17gzip "${output%.gz}"
18