[Fedora-packaging] jquery bundling for new packages

T.C. Hollingsworth tchollingsworth at gmail.com
Mon Sep 23 01:50:47 UTC 2013


On Sat, Sep 21, 2013 at 2:34 AM, Christopher Meng <cickumqt at gmail.com> wrote:
> Just a question: How to deal with the incompatibility when patching all
> jquery js to the latest one?
>
> I have some web apps which don't need the latest version of jquery, how
> should I do if I want step further?

My plan is to have two parallel installable jquery packages: one for the 2.x
branch and one for the 1.x branch.  As much as I'd like to skip the latter,
older IE versions will continue to be the bane of web developers' existence for
some time to come.  We'll continue to support the 1.x series in Fedora as long
as jQuery upstream supports it.

For stuff that needs older jQuery versions, ideally we can patch them to work
with the latest version.  But for a quick fix, we can get most of them working
with 1.10 using jquery-migrate [1] with minimal effort.  (All you need is an
extra <script> tag in most cases.  :-)

For stuff that uses really old jQuery versions where even jquery-migrate isn't
an option (e.g. < 1.6), my first concern is whether upstream is alive in the
first place.  Because seriously, that stuff is OLD.  We really shouldn't be
shipping code that was deprecated three years ago!  If upstream is actively
maintained, then they really need to get with the program.

That being said, our de facto policy regarding bundling is to grandfather old
packages in, which means they can bundle those ancient versions of jQuery till
the end of days if that's what they want.  Though I might have to ask FPC if I
can add Provides: security-nightmare-waiting-to-happen to their spec files.  ;-)

Where migration is possible, I fully intend to have everything unbundled for
F21, wielding my shiny new provenpackager hammer wherever necessary.

Going forward we'll treat jQuery just like any other library in the
distribution.  When a new version comes out, ideally we'll migrate everything by
the next Fedora release, or else provide a parallel-installable backward compat
package only when absolutely necessary.

If you want to help get ready, I suggest working with your upstreams to migrate
to jQuery 1.10, using jquery-migrate where necessary.  That'll make our lives
much easier when we get ready to unbundle.

BTW, I intend to write up a couple of blog posts outlining the general plan and
a list of tips for packagers who want to get a head start within the next month.
But right now I'm busy working on some awesome tools to further automate nodejs
packaging, since we're going to need a lot of nodejs-foo packages as
BuildRequires for the various js-foo packages we want to introduce.

-T.C.

[1] https://github.com/jquery/jquery-migrate/


More information about the packaging mailing list