Creating your own installation script with Custom Theme
Permalink 1 user found helpfulMainly Scrapbook-items, Custom Theme
Can anyone point me towards some useful code to do this?

So in theory I could export my db and use the sample data schema to then import it(as long as I copy the relevant files folders across).
Although I again assume this will only be good until the next update?
But this would give me the option to run the reset script or install from fresh and have it installed with my sample data/attributes/single pages already installed.
Thanks for the tip
But for future projects something like this could work the problem I currently have with Packages is refreshing them I never seem to be able to alter the schema of a package by refreshing it like I can with a block.
But I assume you can edit themes from a Package, and I know you can create single pages, page/user attributes.
So I think this may be a longer to implement, to get it working correctly but could be a better solution in the long run and with future upgrades of the core easier to edit at a later date.
If you have a db.xml file for the package itself, it will get refreshed when you click the "Refresh Databases" button in Dashboard -> Sitewide Settings -> Debug.
Mnkras points out the core file location and I think this will be my immediate solution,
but I will be looking to create a package.
I am not sure how the Karma, works but I will assign to Mnkras first and then adjust to Jordanlev in the hope you both get some Karma.
Thanks again for your help as always its really appreciated.
If I remember correctly, it was pretty simple.
// install all currently not installed packages foreach(Package::getAvailablePackages() as $pkg) { $pkg->install(); } //install all currently not installed themes foreach(PageTheme::getAvailableThemes() as $theme) { PageTheme::add($theme->ptHandle); }