#!/bin/sh -e

if [ "$1" = "configure" -a -d /usr/doc ]; then
  if [ ! -e /usr/doc/junior-doc -a -d /usr/share/doc/junior-doc ]; then
    ln -sf ../share/doc/junior-doc /usr/doc/junior-doc
  fi
  if [ ! -e /usr/doc/junior-doc -a -d /usr/share/doc/junior-doc ]; then
    ln -sf ../share/doc/junior-doc /usr/doc/junior-doc
  fi
fi

if command -v install-docs >/dev/null 2>&1; then
  install-docs -i /usr/share/doc-base/junior-quickguide
fi
