Issue editing skin.xml

Special forum to share and discuss skins for Pano2VR and Object2VR
Post Reply
User avatar
jobes
Posts: 87
Joined: Fri Mar 07, 2008 2:34 am
Contact:

Hi

I'm working on a big project with a fairly complex series of skins for different levels. I've created one 'master' version, and now need to change some variable prefix in the other complimentary skins. It's a bit of a faff to do manually, would be hundreds of manual tweaks so I wanted to automate this :)

However I ran into an issue, so have had to do it manually this time…

My filenaming is pretty good, so in theory I thought I could just do a 'find and replace' for the skin.xml inside the ggsk file in a text editor, and change one prefix for another. So I changed the file sffix from .ggsk to .zip and unzipped the GGSK file, and edited the skin.xml as planned. Then I saved it, and tried to use it. However on output I got this error
Error: unexpected end of file
Line 1, Column 1
Same if I try to open it in the skin editor. I was under the impression the skin is just a directory (which can be externalised if needed) so I though I could just edit the XML. It's odd there's an error, so I was wondering is there some kind of doctype or permission issue which could be causing this? Has anyone else experienced a simliar issue?

Thanks in advance

(Using Pano2VR 4b2 Pro, Mac OX 10.7.5, and TextWrangler to edit the XML.)
User avatar
Hopki
Gnome
Posts: 13005
Joined: Thu Jan 10, 2008 3:16 pm
Location: Layer de la Haye, Essex UK
Contact:

Hi
As far as I know this should work, what exactly are you doing?
Regards,
Hopki
Garden Gnome Support
If you send an e-mail to support please send a link to the forum post for reference.
support@ggnome.com
https://ggnome.com/wiki/documentation/
HMS Beagle
Posts: 104
Joined: Fri Mar 06, 2009 10:40 pm

I get the same error on mac os 10.8.2. As I have done this many times on os 10.4 and 10.5 I think its an os problem, I have not had a chance to try it with a compressor other than the built in yet.
Beagle
HMS Beagle
Posts: 104
Joined: Fri Mar 06, 2009 10:40 pm

As I thought, it's an error with the built in compressor. I just tried it with yemuzip and it works just fine. Tried the same file with the built in and got the same error.
ymmv
Beagle
ps, had yemuzip output as a pc zip format.
User avatar
jobes
Posts: 87
Joined: Fri Mar 07, 2008 2:34 am
Contact:

I was going to say I've since upgraded to 10.8.x and the final release of P2VR4 Pro so I'd need to test it again.

However I've just seen HMS Beagle's useful reply, confirming its the OSlevel compression… thanks for clarifying that. Future batch editing will make my life much easier again!
User avatar
jobes
Posts: 87
Joined: Fri Mar 07, 2008 2:34 am
Contact:

Wanted to resurrect this as I've had the same issue again.
  • Duplicated skin to new location
    Changed file suffix from .ggsk to .zip
    Unzipped (using the default OS Archive Utility; also tried iZip and The Unarchiver
    Edited skin.xml in text editor (used TextWrangler, also tried TextEdit)
    saved skin.xml with changes
    Zipped the folder back up (using YemuZip this time)
    Changed file suffix on Zip archive back to .ggsk
Tried opening the skin in Pano2VR's skin editor and I still get the same error message.
Error: unexpected end of file
Line 1, Column 1


This is terribly frustrating and I can't understand what the issue might be. Am I missing something, or in the steps above is something being done wrong? It'd be a huge help to find/replace large numbers of items in a text editor so I'd be very grateful if a Mac user could outline exactly what they do in order to make this process work. Thanks in advance!

Now running Pano2VR 4.1 / Mac OS X 10.8.3
User avatar
Hopki
Gnome
Posts: 13005
Joined: Thu Jan 10, 2008 3:16 pm
Location: Layer de la Haye, Essex UK
Contact:

Hi,
If you want to just edit the xml and not change around images then the best way is to open the skin editor, drag and highlight all the elements in the skin window and then copy and paste in a text editor.
Make your changes and then copy and paste back in the skin.

If you want to use a Zip program, I am using keka on the Mac.
1) Copy your ggsk file
2) Either add .zip to the end or replace .ggsk with .zip
3) Unzip open and edit
4) Select all the files and add to a new zip archive
5) Change the file extension to .ggsk and rename the file name as required

The trick is to make a new zip archive.
If your still getting problems, let me know.
Regards,
Hopki
Garden Gnome Support
If you send an e-mail to support please send a link to the forum post for reference.
support@ggnome.com
https://ggnome.com/wiki/documentation/
User avatar
jobes
Posts: 87
Joined: Fri Mar 07, 2008 2:34 am
Contact:

Thanks Hopki, appreciate the quick response.

OK, I've tried this again using Keko (cool app, didn't know it so thanks for making me aware of it) and have followed your steps.

Once I unzipped the original skin using Keko, I renamed the folder to something else. Then I edited the skin.xml, saved it, and zipped it using Keko (set to exclude mac resource forks), then changed the suffix from .zip to .ggsk.

Once again it's the same problem: it shows as a skin in the Finder, but doesn't open in the skin editor (still the same error message as before)

There doesn't seem to be a problem with my process… could there be an issue with the xml description at the head of the XML document? I always get the same warning, on multiple computers and across different OSs (10.7.x & 10.8.3) and iterations of P2VR.

Code: Select all

<?xml version='1.0' encoding='utf-8'?>
User avatar
Hopki
Gnome
Posts: 13005
Joined: Thu Jan 10, 2008 3:16 pm
Location: Layer de la Haye, Essex UK
Contact:

Hi,
jobes wrote:Once I unzipped the original skin using Keko, I renamed the folder to something else. Then I edited the skin.xml, saved it, and zipped it using Keko (set to exclude mac resource forks), then changed the suffix from .zip to .ggsk.
No, when you have your folder, open and edit the XML then highlight all the files in the folder and drop them on the Keko dock icon.
This will make a new archive in your folder. Move the new archive/zip out of the folder and trash the folder.
Now rename the new zip to xxxxx.ggsk

Trying to avoid making the zip from the folder, your making it directly with all the highlighted files.
Regards,
Hopki
Garden Gnome Support
If you send an e-mail to support please send a link to the forum post for reference.
support@ggnome.com
https://ggnome.com/wiki/documentation/
User avatar
jobes
Posts: 87
Joined: Fri Mar 07, 2008 2:34 am
Contact:

Result, that's done it! Thanks Hopki… seems the issue was zipping up the enclosing folder. Dragging the contents of the folder works a treat…

I'll be buying you a beer in Selfoss for sure, thanks again! :D
Post Reply