source cant use variables (p1)
This commit is contained in:
40
src/proj/debian
Normal file
40
src/proj/debian
Normal file
@ -0,0 +1,40 @@
|
||||
#!/bin/bash
|
||||
#remaster lib
|
||||
[ -d "$LIBDIR"] || export LIBDIR="/usr/lib/remaster/"
|
||||
[ -d "$LIBDIR"] || { echo "LIBDIR not exist"; exit 1; }
|
||||
####################################
|
||||
##### Base Template D E B I A N ####
|
||||
####################################
|
||||
# .
|
||||
|
||||
|
||||
#tools_add [chroot_dir] [tools_list]
|
||||
function tools_add() {
|
||||
echo "add tools ... "
|
||||
#$1 = chroot directory
|
||||
chroot_dir="$1"
|
||||
tools_list="$2"
|
||||
|
||||
chroot "$chroot_dir" /bin/bash -c "apt-get update" > /dev/null
|
||||
[ "$?" == "0" ] && echo "apt-get update: success"
|
||||
chroot "$chroot_dir" /bin/bash -c "apt-get install -y $tools_list" | grep -v "wird eingerichtet ..." | grep -v "Vormals nicht ausgewähltes Paket" | grep -v "Entpacken von" | grep -v "Holen: " | grep -v "Trigger für" | grep -v "update-alternatives:"
|
||||
echo "done"
|
||||
}
|
||||
|
||||
#os_update [chroot_dir]
|
||||
function os_update() {
|
||||
echo "updating os ... "
|
||||
#$1 = chroot directory
|
||||
|
||||
chroot_dir="$1"
|
||||
|
||||
chroot "$chroot_dir" /bin/bash -c "apt-get update" > /dev/null
|
||||
[ "$?" == "0" ] && echo "apt-get update: success"
|
||||
chroot "$chroot_dir" /bin/bash -c "apt-get dist-upgrade -y" | grep -v "wird eingerichtet ..." | grep -v "Vormals nicht ausgewähltes Paket" | grep -v "Entpacken von" | grep -v "Holen: " | grep -v "Trigger für" | grep -v "update-alternatives:"
|
||||
chroot "$chroot_dir" /bin/bash -c "apt-get clean"
|
||||
|
||||
echo "done"
|
||||
}
|
||||
|
||||
TEST="ja"
|
||||
TEST2="ja"
|
10
src/proj/desinfect.17
Normal file
10
src/proj/desinfect.17
Normal file
@ -0,0 +1,10 @@
|
||||
#!/bin/bash
|
||||
#remaster lib
|
||||
[ -d "$LIBDIR"] || export LIBDIR="/usr/lib/remaster/"
|
||||
[ -d "$LIBDIR"] || { echo "LIBDIR not exist"; exit 1; }
|
||||
|
||||
#desinfect.17
|
||||
# . -Y ubuntu.16.04 -> ubuntu -> debian
|
||||
source $LIBDIR/proj/ubuntu.16.04
|
||||
|
||||
TEST2="na"
|
12
src/proj/ubuntu
Normal file
12
src/proj/ubuntu
Normal file
@ -0,0 +1,12 @@
|
||||
#!/bin/bash
|
||||
#remaster lib
|
||||
[ -d "$LIBDIR"] || export LIBDIR="/usr/lib/remaster/"
|
||||
[ -d "$LIBDIR"] || { echo "LIBDIR not exist"; exit 1; }
|
||||
|
||||
####################################
|
||||
##### Base Template U B U N T U ####
|
||||
####################################
|
||||
# . -> debian
|
||||
source $LIBDIR/proj/debian
|
||||
|
||||
TEST2="jaUb"
|
@ -0,0 +1,10 @@
|
||||
#!/bin/bash
|
||||
#remaster lib
|
||||
[ -d "$LIBDIR"] || export LIBDIR="/usr/lib/remaster/"
|
||||
[ -d "$LIBDIR"] || { echo "LIBDIR not exist"; exit 1; }
|
||||
|
||||
#ubuntu.16.04
|
||||
# . -> ubuntu -> debian
|
||||
source $LIBDIR/proj/ubuntu
|
||||
|
||||
TEST2="jaUBU"
|
||||
|
Reference in New Issue
Block a user