From eab97c79a71898ac7a61d6ebe076bb8f1901f734 Mon Sep 17 00:00:00 2001 From: saicharankandukuri Date: Tue, 11 Apr 2023 11:06:33 +0530 Subject: [PATCH] feat: add support to execute scripts run_shell_script() --- plugins/envsetup | 11 +++++++++++ 1 file changed, 11 insertions(+) diff --git a/plugins/envsetup b/plugins/envsetup index a497359..2f1c195 100755 --- a/plugins/envsetup +++ b/plugins/envsetup @@ -442,6 +442,17 @@ run_cmd() { do_chroot_ae "$chroot_dir" "$command" } +run_shell_script() { + lshout "Running script: $1" + echo + echo + local script=$1 + cp -v "$script" "$chroot_dir" + chmod +x "$chroot_dir/$(basename $script)" + do_chroot_ae "$chroot_dir" /bin/bash "/$script" + echo "Done running script: $1" +} + install_pkg() { pkg_name="$*"