[openspending-dev] openspending and openspendingjs as separate repositories

Vitor Baptista vitor at vitorbaptista.com
Tue Aug 7 19:03:31 UTC 2012


Hi Nick,

2012/8/7 Nick Stenning <nickstenning at gmail.com>

> a) Having JS as a separate repository encourages you to loosely couple the
> JS and the OpenSpending backend. This is a good thing. Modular client
> applications on top of well designed REST APIs is the way the web is going.
>

That's a very good point. This is valid for the widgets in openspendingjs,
but there's still glue code, and code that's not worthy to be separated
(like search). At least this part should be in the openspending repository.

This would make more sense if the entire openspending.org app would simply
use the backend through an API, but to separate it is a huge effort, that
probably isn't worthy now.

b) it's also helpful for people like Gregor, who might know their stuff
> when it comes to JS, but don't want to be faced with the full complexity of
> the OS codebase.
>

I understand that, for this use case, it's better to have a separate
repository. But, even if both are in only one repo, if you don't want to be
bothered by the backend, you can go to javascript's folder and develop
there.


> So. I'm in favour of keeping the the repo separate, but I recognise the
> concerns:
>
> 1) that concrete versions of OSJS are no longer tied to concrete versions
> of OS
>
> 2) that developing across two repositories is a pain
>
> And guess what, there's a solution that addresses both of these issues and
> isn't git submodules!
>
> Git subtree is now distributed with mainline git (in the contrib
> directory) and allows you to include one repo within another as if it were
> just another checkout. See the okfn wordpress repository for an example of
> how it's used to pull in the okfn theme from another repo.
>
> Here's the (out-of-date) original repo for git-subtree:
>
>   https://github.com/apenwarr/git-subtree/
>
> And a couple of blog posts describing its use:
>
>
> http://psionides.eu/2010/02/04/sharing-code-between-projects-with-git-subtree/
>   http://apenwarr.ca/log/?m=200904#30
>

That seems cool, thanks for the link. I felt it was kinda complex, but it
might be an option.

Maybe the best option is to move whatever is coupled to openspending to the
openspending repo, and tie the openspendingjs with git-subtree or something
similar? This feels too complex now, but maybe we can work to simplify it.

What do you think?

Cheers!
Vítor.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.okfn.org/pipermail/openspending-dev/attachments/20120807/4abea3dd/attachment.html>


More information about the openspending-dev mailing list