aboutsummaryrefslogtreecommitdiffstats
path: root/textproc/pootle/pkg-install
blob: a97c389f4c56f418c0d16950bdb9bbc699532814 (plain) (blame)
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
30
#! /bin/sh
# $FreeBSD#

PATH=/bin:/usr/bin:/usr/sbin

case $2 in

POST-INSTALL)
    DIR=/var/log/pootle
    if [ -d ${DIR} ]; then
      echo "===> Skipping ${DIR} - already exists"
    else
      echo "===> Creating directory ${DIR}"
      mkdir -p ${DIR}
      echo "===> Changing ownership of ${DIR}"
      chown -R nobody:nobody ${DIR}
      echo "===> Changing permissions of ${DIR}"
      chmod -R 770 ${DIR}
    fi
    DIR="/var/db/pootle"
    if [ -d ${DIR} ]; then
      echo "===> Skipping ${DIR} - already exists"
    else
      echo "===> Changing ownership of ${DIR}"
      chown -R nobody:nobody ${DIR}
      echo "===> Changing permissions of ${DIR}"
      chmod -R 770 ${DIR}
    fi
    ;;
esac