cordova-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Filip Maj <...@adobe.com>
Subject Re: icons, splash and hooks
Date Sat, 10 Aug 2013 18:33:10 GMT
Unfortunately, Build's implementation has diverged from any standards.
They've had to, as standards have fallen behind but the Build team must
deliver functionality to its users.

The standard in use today by Cordova is the W3C Widgets spec [1].
Unfortunately again, it has been shelved as a W3C "note" - essentially
meaning it will no longer be worked on.

Looking to the future, the spec in-the-works today to solve the manifest
problem is being worked on together by the W3C SysApps and WebApps working
groups. It is a JSON-based format. The repository [2] and draft [3] are
online.

[1] http://www.w3.org/TR/widgets/
[2] https://github.com/w3c/manifest
[3] http://www.w3.org/2008/webapps/manifest/

On 8/9/13 5:26 PM, "Michael Leaney" <leahcimic@gmail.com> wrote:

>Hi Filip,
>
>ImageMagick is only required if you want cordova-cli to resize your
>images 
>automatically. If you don't have it installed, it won't stop everything
>else from
>working, it just won't do auto resize.
>
>I'm sure you can install ImageMagick on all major platforms, I've
>personally
>used it with OSX, and Linux.
>
>I'll join the discussion on the Jira issue, and try and come to a
>consensus.
>
>I had a look at [1], and I decided that it would be best to support
>Phonegap's
>manifest as it will mean a project can be built from the command line,
>and/or
>Phonegap's build service without any change.
>
>Could you point me in the right direction to the standards, so I can
>ensure that
>going forward I can work towards them?
>
>Kind regards,
>Michael Leaney
>
>On 10/08/2013, at 4:42 AM, Filip Maj <fil@adobe.com> wrote:
>
>> Hey guys,
>> 
>> Thanks for kicking this thread off. Lots of good stuff here.
>> 
>> First: there are several issues in our JIRA covering icon and splash
>> screen support. Most of the discussion has happened under the
>> <icon>-specific issue [1], and I think pretty much everything discussed
>> about <icon>s applies to <splashscreen>s. Right now: there is no good
>> support in cordova for icon and splash screens.
>> 
>> Michael: thank you for the pull request to add icon and splash screen
>> support. I have a bunch of comments:
>> 
>> 1. Adding imagemagick as a dependency is probably a bad idea. Does it
>> build fine on OSX, Linux and Windows? I have my doubts, given my prior
>> experience with this tool.
>> 2. I am not sure we want to do image processing at all to enable icon
>>and
>> splash support. Based on [1], it sounds like an explicit enumeration of
>> particular icon/splash files with particular sizes (to be adapted
>> appropriately for the varying platforms we support) is the way we are
>> going with this feature. I encourage everyone to please check out [1],
>> read through the ideas described in that JIRA issue, and continue
>> discussion on that issue. Once a general approach to the problem is
>> identified and agreed on, we can employ the same strategy for splash
>> screens.
>> 3. It seems like manifest-wise, Michael, you are following what PhoneGap
>> build has done to add support for icons. While that is nice, it is not
>>the
>> way the standards are going for application manifests (in fact, XML
>>isn't
>> the way the standards are going). Again, refer to [1] for discussion on
>> different ways to implement that.
>> 
>> Ivan, regarding your second point about hooks, I totally agree. We have
>>an
>> issue filed to enable generic parameter passing to command-line hooks
>>[2].
>> 
>> Ivan, regarding your third point, I don't think that would work out on
>> windows, will it? Shebangs or whatever you call them? Alternatively:
>>have
>> a .bat file on windows that invokes node or whatever interpreter you
>>wrote
>> your scripts in.
>> 
>> [1] https://issues.apache.org/jira/browse/CB-2606
>> [2] https://issues.apache.org/jira/browse/CB-4382
>> 
>> On 8/8/13 1:16 AM, "Ivan Baktsheev" <owner@apla.me> wrote:
>> 
>>> hello
>>> 
>>> i have some projects which i want to migrate from cordova 2.x to
>>>cordova
>>> 3.0. i'm very happy with the project format change and cordova cli, but
>>> some issues are very frustrating.
>>> 
>>> 1) icons and splash screens won't copy from res folder
>>> 
>>> i created an after_prepare hook script
>>> (https://gist.github.com/apla/6179863) and assets go to the proper
>>> folders. probably, this can be added to the cordova cli. are there any
>>> reasons not to include this functionality into cordova?
>>> 
>>> but this added other two issues:
>>> 
>>> 2) hook scripts know nothing about current command platform. for
>>>example,
>>> when i run "cordova prepare ios" i don't need assets from android
>>>copied.
>>> i propose to make a hook script reading an environment or the second
>>> command line parameter to get a current platform, would that work?
>>> 
>>> 3) hook is not running on windows, and i have to rename my hook to
>>> "something.js", windows will run this script via cscript.exe. i think,
>>> cordova could read the first line of a script file (#!/bin/env node)
>>>and
>>> launch a proper command, or interpret every hook on windows as a nodejs
>>> script; in this case we would be able to get cross-platform hooks.
>>> 
>>> thank you!
>>> 
>> 
>


Mime
View raw message