aboutsummaryrefslogtreecommitdiffstatshomepage
path: root/src/scripts
diff options
context:
space:
mode:
authorDavid M. Syzdek <david@syzdek.net>2018-01-27 14:35:28 -0900
committerDavid M. Syzdek <david@syzdek.net>2018-01-27 14:35:28 -0900
commit5160cb15d246c29f14dc25dd40219b9e71e96bdc (patch)
tree8ba3ea9c92b9d4491db1abfb7eda650307374be5 /src/scripts
parentfd127a93cca0d7684de02dd4bf63bbae9e6c5a03 (diff)
downloadiperd-5160cb15d246c29f14dc25dd40219b9e71e96bdc.tar.gz
iperd-5160cb15d246c29f14dc25dd40219b9e71e96bdc.tar.bz2
iperd-5160cb15d246c29f14dc25dd40219b9e71e96bdc.tar.xz
iperd-5160cb15d246c29f14dc25dd40219b9e71e96bdc.zip
extractiso.sh: removing unused script
Diffstat (limited to 'src/scripts')
-rwxr-xr-xsrc/scripts/download.sh1
-rw-r--r--src/scripts/extractiso.sh80
2 files changed, 0 insertions, 81 deletions
diff --git a/src/scripts/download.sh b/src/scripts/download.sh
index c16d356..2ed5d12 100755
--- a/src/scripts/download.sh
+++ b/src/scripts/download.sh
@@ -205,7 +205,6 @@ if test ! -z "${HASH_FILE}";then
205fi 205fi
206if test ! -z "${EXTRACTDIR}";then 206if test ! -z "${EXTRACTDIR}";then
207 case "${FILE}" in 207 case "${FILE}" in
208 #*.iso) EXTRACT_CMD="sudo $(dirname "${0}")/extractiso.sh ${FILE} ${EXTRACTDIR}";;
209 *.iso) EXTRACT_CMD="extactiso";; 208 *.iso) EXTRACT_CMD="extactiso";;
210 *.tar.gz) EXTRACT_CMD="gzip -cd '${FILE}' |tar -xf - -C '${EXTRACTDIR}'";; 209 *.tar.gz) EXTRACT_CMD="gzip -cd '${FILE}' |tar -xf - -C '${EXTRACTDIR}'";;
211 *.tgz) EXTRACT_CMD="gzip -cd '${FILE}' |tar -xf - -C '${EXTRACTDIR}'";; 210 *.tgz) EXTRACT_CMD="gzip -cd '${FILE}' |tar -xf - -C '${EXTRACTDIR}'";;
diff --git a/src/scripts/extractiso.sh b/src/scripts/extractiso.sh
deleted file mode 100644
index bef8017..0000000
--- a/src/scripts/extractiso.sh
+++ /dev/null
@@ -1,80 +0,0 @@
1#!/bin/bash
2#
3# IP Engineering Rescue Disk
4# Copyright (C) 2017 David M. Syzdek <david@syzdek.net>.
5#
6# @SYZDEK_BSD_LICENSE_START@
7#
8# Redistribution and use in source and binary forms, with or without
9# modification, are permitted provided that the following conditions are
10# met:
11#
12# * Redistributions of source code must retain the above copyright
13# notice, this list of conditions and the following disclaimer.
14# * Redistributions in binary form must reproduce the above copyright
15# notice, this list of conditions and the following disclaimer in the
16# documentation and/or other materials provided with the distribution.
17# * Neither the name of David M. Syzdek nor the
18# names of its contributors may be used to endorse or promote products
19# derived from this software without specific prior written permission.
20#
21# THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS
22# IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO,
23# THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR
24# PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL DAVID M. SYZDEK BE LIABLE FOR
25# ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
26# DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR
27# SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER
28# CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT
29# LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY
30# OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
31# SUCH DAMAGE.
32#
33# @SYZDEK_BSD_LICENSE_END@
34#
35
36PROG_NAME="$(basename "${0}")"
37if test "x${1}" == "x";then
38 echo "Usage: ${PROG_NAME} <image> [ <output> ]"
39 exit 1
40fi
41IMAGE="${1}"
42OUTPUT="${2:-$(dirname "${IMAGE,,}")/$(basename "${IMAGE,,}" .iso)}"
43
44
45mkdir -p "${OUTPUT}" || exit 1
46
47
48unset MKTEMP
49
50
51cleanup()
52{
53 if test ! -z "${MKTEMP}";then
54 sudo umount -f "${MKTEMP}"
55 rm -Rf "${MKTEMP}"
56 fi
57};
58trap cleanup EXIT
59
60
61# create mount point
62MKTEMP="$(mktemp -d -p "tmp/" "$(basename "${OUTPUT}").XXXXXX")"
63if test -z "${MKTEMP}";then
64 exit 1
65fi
66
67
68# mount ISO
69sudo mount -o ro "${IMAGE}" "${MKTEMP}" || exit 1
70
71
72# copy files
73rsync -ra "${MKTEMP}/" "${OUTPUT}" || exit 1
74
75
76# make files user writeable
77chmod -R u+rw "${OUTPUT}" || exit 1
78
79
80# end of script