PepMiniiso/PepDev32/pepscripts/copy-files-to-chroot.sh

33 lines
1.1 KiB
Bash
Executable File

#!/bin/bash
# SPDX-License-Identifier: GPL-3.0-or-later
#
# SPDX-FileCopyrightText: 2023 PeppemrintOS Team (peppermintosteam@proton.me)
# This script copies a file to the chroot and runs commands during the Debian installation process.
# Copy files to the chroot directory
echo "Copying files to chroot..."
cp /preseed/grub /target/etc/default
cp /preseed/multimedia.list /target/etc/apt/sources.list.d
cp /preseed/peppermint.list /target/etc/apt/sources.list.d
cp /preseed/sources.list /target/etc/apt
cp /preseed/deb-multimedia-keyring.gpg /target/etc/apt/trusted.gpg.d
cp /preseed/peppermint-keyring.gpg /target/etc/apt/trusted.gpg.d
cp /preseed/deb-multimedia-keyring.gpg /target/usr/share/keyrings
cp /preseed/peppermint-keyring.gpg /target/usr/share/keyrings
cp -r /preseed/themes /target/boot/grub
# Run a commands in the chroot
chroot /target update-initramfs -u
chroot /target update-grub
cd /target//usr/share/python-apt/templates/
ln -s Devuan.info Peppermint.info
ln -s Devuan.mirrors Peppermint.mirrors
cd /target/usr/share/distro-info/
ln -s devuan.csv peppermint.csv
exit