Welcome!

Welcome to the official BlackBerry Support Community Forums.

This is your resource to discuss support topics with your peers, and learn from each other.

inside custom component

Web and WebWorks Development

Reply
New Developer
naomipunkclan
Posts: 26
Registered: ‎04-25-2010
My Device: none
Accepted Solution

webworks compile sketchPad example - stuck!

hi

 

trying to get started with the example sketchPadStandard.zip

 

On Mac OS X this is entered:

 

 

./bbwp /path/to/sketchPadStandard.zip

 

 

and this result :

 

 

[INFO]       Parsing command line options

[INFO]       Parsing bbwp.properties

[INFO]       Validating WebWorks archive

[ERROR]     Invalid WebWorks archive - failed to find config.xml

But the archive is as downloaded, and has a valid config.xml file in there.
Any ideas ?

 

New Developer
naomipunkclan
Posts: 26
Registered: ‎04-25-2010
My Device: none

Re: webworks compile sketchPad example - stuck!

still getting nowhere fast...

 

tried uncompress the zip, then re-archive and get this

 

 

 

./bbwp /Users/blackberrydev/Desktop/sketch.zip
[INFO]      		Parsing command line options
[INFO]      		Parsing bbwp.properties
[INFO]      		Validating WebWorks archive
[ERROR]     		Invalid WebWorks archive - resource name is not valid(sketchPadStandard/.DS_Store)

 

 

 

Which shows that the compiler is intolerant of the hidden Mac OS X files. I get the idea that the problem is that I am using a Mac and there are still many problems to be ironed out with the tool. Any Mac users getting any better luck ? Please share.

New Contributor
Andy_Schlosser
Posts: 5
Registered: ‎01-18-2011
My Device: Not Specified

Re: webworks compile sketchPad example - stuck!

Right now I am having the same issue as well.  I can't make it work for the life of me, I tried going in through Terminal and deleting all of the hidden files and such and it didn't work.  So if you find an answer, please post too!  I bet there are many of us with this issue :smileywink:

Contributor
rizer
Posts: 10
Registered: ‎01-18-2011
My Device: iPhone

Re: webworks compile sketchPad example - stuck!

OK, I had this issue too. The difference (which isn't obvious at all on a Mac) is that you need to zip the individual files, rather than a folder containing the files. So, from within the project directory, do something like:

 

 

zip -r ../ProductName *

 

If you've got .DS_Store issues, simply do the following:
find . -name '*.DS_Store' -type f -delete

 It's a bit of a pain, I know. Also doesn't help that the instruction are so Windows-centric, but I guess it's early days. 

 

New Contributor
Andy_Schlosser
Posts: 5
Registered: ‎01-18-2011
My Device: Not Specified

Re: webworks compile sketchPad example - stuck!

Major kudos, worked like a charm.  Thanks a ton!

New Contributor
avikaza123
Posts: 2
Registered: ‎01-19-2011
My Device: Not Specified

Re: webworks compile sketchPad example - stuck!

Thank you Rizer, that was very helpful

 

Avinash

Contributor
rizer
Posts: 10
Registered: ‎01-18-2011
My Device: iPhone

Re: webworks compile sketchPad example - stuck!

Glad I could help :smileyhappy:

 

– Luke

New Developer
naomipunkclan
Posts: 26
Registered: ‎04-25-2010
My Device: none

Re: webworks compile sketchPad example - stuck!

Thanks Rizer - works perfectly

Retired
astanley
Posts: 1,382
Registered: ‎07-02-2009
My Device: BlackBerry Bold 9900
My Carrier: Bell

Re: webworks compile sketchPad example - stuck!

Hi folks,

 

This seems like it has become a common issue.  Would clarification in the sample code notes or online documentation have helped in this case?

 

As I understand it, Mac users download the sample file, un-package the file contents to their system, and then re-compress it.  It is at this point that confusion is occuring over whether the ZIP should contain just the files, or a folder containing the files?

 

I can add a note the to KB to help future developers avoid this problem.

 

Adam

Follow me on Twitter: @n_adam_stanley
-------------------------------------------------------------------------------------------------------------------------
Your app doesn't work? Use BlackBerry remote web inspector to find out why.
New Developer
naomipunkclan
Posts: 26
Registered: ‎04-25-2010
My Device: none

Re: webworks compile sketchPad example - stuck!

hi,

 

My first expectation is that the zip file as given would work. However, this if corrected might just elude Mac users as to how to prepare the zip files anyway. It would be better if the zip file was generally the same across platforms. Failing that, explicit instruction would certainly help.

 

For me as a Mac user, I normally do as much as possible in the GUI so automatically expect to right click on a folder, save as archive - > gives a zip file. That is a compressed unit that when decompressed will reproduce the original. Perhaps the solution should be to allow this method by updating the compiler to be flexible enough - especially since it will be built for Mac OS :- just have it accept the usual method of creating zip archives as the source (as well as support the current type, and also support the zip file sent from a Windows user). So eliminate the command line solution (which was very helpfully provided here) as the only method of getting the result.

 

Hope this makes sense.

 

But meanwhile, updating the sample notes to include the command line step would solve it immediately for many users, and get things moving for them

 

i.e. to really support Mac users make the software meet their usual intuitive method; but meanwhile, by all means provide detailed documentation where required to avoid holding up early adopters

 

If the process of development and testing is too finicky, it will discourage development, yet solving the problem here is only a few extra lines of code in the complier tool

 

Going further, I would want to have a drag and drop version of the compiler - e.g. just drop your work onto a window to get it installed in the Emulator. I guess that this is provided in Flash Builder IDE with build and run. But my experience was that FB 4.5 first of all facilitates Actionscript rather than HTML5 based. Secondly, it just launched a native Mac Window for testing which is great, but you want to see it in the Emulator, having gone to the trouble of buying VMWare Fusion and getting the emulator installed there...

 

For HTML5 development, maybe just a drag and drop Icon to zip the folder, launch the compiler, then install in the emulator would be great. Possibly doable just using the Automator tools in Mac OS X. Then it would enable user choice of IDE or text editor - possibly with two items in the Services Menu - one to install in the emulator,( and one for the device when available. )