summaryrefslogtreecommitdiffstats
path: root/installworld
blob: fd15562243545ca21fc19508f3496e9d4a7ea320 (plain)
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
#!/bin/bash

if [ "$1" = "" ]; then
  echo "usage: $0 <pkg_directory>"
  echo ""
  echo "call this while in the root of the install tree and"
  echo "pass it the path of the directory containing packages"
  echo "to be installed"
  echo ""
  exit
fi

echo "Initializing pacman database..."
mkdir -p var/lib/pacman && touch var/lib/pacman/pacman.db

for pkg in `find $1/*`; do
  echo "==> $pkg" >>install.log
  echo "==> $pkg"
  pacman -A -r . $pkg 2>&1 >>install.log
done

echo "Syncing..."
sync

echo "Done."