The example is for TazPup but I also discuss the modifications for a standard puppy.
The use case is that something isn't working correctly with your current save file and you want to fix it by adding missing packages.
What you do is you open a clean instance of puppy, install the package and then copy the missing package over. The script handles the latter part.
Now assuming that you are running puppy from an instance with the missing package installed, simply go to any directory withing the save folder, and then run the script. For instance, say I'm in the path
Code: Select all
.../tazsave/var/lib/tazpkg/installed
Code: Select all
bash CpyPkg icu
and watch the magic happen.
Code: Select all
#!/bin/bash
THIS_DIR=$PWD
cd $THIS_DIR
PACKAGE=$1
ROOT="${THIS_DIR%%/tazpupsave/*}/tazpupsave"
while read line; do
DIR=$(dirname "$line")
mkdir -p "$ROOT$DIR"
cp -a -u "$line" "$ROOT$line"
done <$PACKAGE/files.list
Code: Select all
done <$PACKAGE/files.list
Code: Select all
done <$PACKAGE
so if one was installing the package icu into the non mounted folder the command would look something like this on tarpup.
Code: Select all
bash CpyPkg .../tahrsave/root/.packages/icu
As a final note that the script only copies over the files in the package. The list of files to copy must first be manually copied to the save folder.