1

I'm making a installable package via Cydia that will write com.intelliborn.intelliscreenx to this:

<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE plist PUBLIC "-//Apple//DTD PLIST 1.0//EN" "http://www.apple.com/DTDs/PropertyList-1.0.dtd">
<plist version="1.0">
<dict>
    <key>Hidden</key>
    <array>
        <string>libactivator</string>
        <string>com.aaronash.BarrelSettings</string>
        <string>com.iptm.bigboss.sbsettings</string>
    </array>
</dict>
</plist>

But I don't know how to write to postinst script to where it add's it correctly and make the postrmv script to where it removes it correctly.

The hidden.plist should look like this after installing this package:

<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE plist PUBLIC "-//Apple//DTD PLIST 1.0//EN" "http://www.apple.com/DTDs/PropertyList-1.0.dtd">
<plist version="1.0">
<dict>
    <key>Hidden</key>
    <array>
        <string>libactivator</string>
        <string>com.aaronash.BarrelSettings</string>
        <string>com.iptm.bigboss.sbsettings</string>
            <string>com.intelliborn.intelliscreenx</string>
    </array>
</dict>

Here how my postinst & postrmv scripts look:

postinst

#!/bin/bash

declare -a cydia
cydia=($CYDIA)

if [[ $1 == install ]]; then
    if [[ ${CYDIA+@} ]]; then
        eval "echo 'finish:restart' >&${cydia[0]}"
    fi
fi
echo -e "\n\<string>com.intelliborn.intelliscreenx</string>\n" >> /var/mobile/Library/LibHide/hidden.plist

exit 0

postrmv

#!/bin/bash
echo " " >> /var/mobile/Library/LibHide/
sed -i 's/<string>com.intelliborn.intelliscreenx</string>\n" >> /var/mobile/Library/LibHide/hidden.plist

declare -a cydia
cydia=($CYDIA)

if [[ $1 == install ]]; then
    if [[ ${CYDIA+@} ]]; then
        eval "echo 'finish:restart' >&${cydia[0]}"
    fi
fi

exit 0

0

You must log in to answer this question.

Browse other questions tagged .