File: chroot.sh

package info (click to toggle)
fakechroot 2.9-1.1%2Bsqueeze1
  • links: PTS, VCS
  • area: main
  • in suites: squeeze
  • size: 2,316 kB
  • ctags: 408
  • sloc: sh: 10,537; ansic: 2,223; perl: 126; makefile: 40
file content (14 lines) | stat: -rwxr-xr-x 207 bytes parent folder | download
1
2
3
4
5
6
7
8
9
10
11
12
13
14
#!/bin/sh

if [ $# -gt 0 ]; then
    destdir=$1
    shift
else
    destdir=testtree
fi

if [ $# -gt 0 ]; then
    HOME=/root chroot `pwd`/$destdir "$@"
else
    HOME=/root chroot `pwd`/$destdir /bin/bash
fi