Sha256: 8379b0fdc94b2d123494fc57cdf092d2a9bc025bb3f4b60d83c4017097879d04

Contents?: true

Size: 820 Bytes

Versions: 13

Compression:

Stored size: 820 Bytes

Contents

#!/bin/bash

SCRIPT_DIR="$( cd "$( dirname "$0" )/../" && pwd )"

if [ -z $GEM_NAME ]; then
  GEM_NAME="manpages"
fi
if ! $(gem list -i "$GEM_NAME") ;then
  gem install "$GEM_NAME"
fi

if [ -n "$(command -v git)" ] && \
  [ "$(basename $(git config --local remote.origin.url) 2>/dev/null)" = "manpages.git" ]; then
  DIR=$SCRIPT_DIR
else
  LIB_DIR="$(dirname "$(gem which manpages)")"
  DIR="$(readlink -f  ${LIB_DIR}/../)"
fi

if [ "$DIR" != "$(rbenv root)" ]; then
  . "${DIR}/rbenv/vars.sh"

  mkdir -p "${PREFIX_MAN}"

  mkdir -p $EXEC_HOOK_DIR
  mkdir -p $INSTALL_HOOK_DIR

  cp "${DIR}/rbenv/hooks/version-name-change-man.bash" $EXEC_HOOK_DIR/
  cp "${DIR}/rbenv/hooks/install-man.bash" $INSTALL_HOOK_DIR/

  ln -sf $PREFIX_MAN "${ROOT_MAN}"
  echo "manpages gem installed"
else
  echo "cannot find gem folder"
fi

Version data entries

13 entries across 13 versions & 3 rubygems

Version Path
ric-0.14.2 vendor/bundle/ruby/2.7.0/gems/manpages-0.6.1/rbenv/rbenv_hook_install.sh
ric-0.14.1 vendor/bundle/ruby/2.7.0/gems/manpages-0.6.1/rbenv/rbenv_hook_install.sh
ric-0.14.0 vendor/bundle/ruby/2.7.0/gems/manpages-0.6.1/rbenv/rbenv_hook_install.sh
pokedex-terminal-0.2.8 vendor/bundle/ruby/2.7.0/gems/manpages-0.6.1/rbenv/rbenv_hook_install.sh
pokedex-terminal-0.2.7 vendor/bundle/ruby/2.7.0/gems/manpages-0.6.1/rbenv/rbenv_hook_install.sh
pokedex-terminal-0.2.6 vendor/bundle/ruby/2.7.0/gems/manpages-0.6.1/rbenv/rbenv_hook_install.sh
pokedex-terminal-0.2.5 vendor/bundle/ruby/2.7.0/gems/manpages-0.6.1/rbenv/rbenv_hook_install.sh
pokedex-terminal-0.2.4 vendor/bundle/ruby/2.7.0/gems/manpages-0.6.1/rbenv/rbenv_hook_install.sh
manpages-0.6.1 rbenv/rbenv_hook_install.sh
manpages-0.6.0 rbenv/rbenv_hook_install.sh
manpages-0.5.2 rbenv/rbenv_hook_install.sh
manpages-0.5.1 rbenv/rbenv_hook_install.sh
manpages-0.5.0 rbenv/rbenv_hook_install.sh