Connecting The Opportunistic Dots

Something I have talked about extensively recently has been my passion to see opportunistic developers served well on the Linux desktop. These kinds of programmers are people who want to write small, focused, fun little applications that scratch an itch, even if that itch is to have fun. These kinds of developers are having a whale of a time filling the iPhone App Store with scratch-your-itch type of applications, and I am really keen to see more of these kinds of applications on the Linux desktop, and making Ubuntu the perfect platform to develop them on.

We have been seeing a growing movement inside the Ubuntu community in helping to make Ubuntu a rocking platform for opportunistic developers. While all the components are Open Source and can be shipped on any distribution, I am really keen for Ubuntu to really optimize and integrate around the needs of opportunistic programmers and I just wanted to highlight some of the work that has happened here.

In much the same way that Linux/Apache/MySQL/PHP (LAMP) became a popular arrangement of tools for web development, we have been seeing a similar scenario in Ubuntu too, in which a set of tools work well together and are often preferred by developers. These are:

  • Python – a simple, easy to learn, flexible and efficient high-level language.
  • GTK – a simple, comprehensive and powerful graphical toolkit for creating applications.
  • GNOME – the desktop environment that ships with Ubuntu, offering many integration facilities.
  • GStreamer – a powerful but deliciously simple framework for playing back and creating audio, video and other multimedia content.
  • Glade – an application for creating user interfaces quickly and easily, which can then be loaded right into your Python programs.
  • DesktopCouch – a framework for saving content in a database that is fast and efficient, hooks neatly into Ubuntu One and is awesome for replication.

In Ubuntu land we love this framwork. Many of our applications are written using them and this helped make it simple for others to get involved and contribute patches and bug fixes. It has been interesting seeing many folks settle on the same set of tools.

There are of course may other tools and facilities that can augment this list, but this is a common foundation in many applications. Fortunately, all of these ship with an Ubuntu system except Glade, but you can install Glade 3 by using Applications->Ubuntu Software Center.

Many of you will have heard of Quickly which provides a devilishly simple way of generating a new application, hacking on the code, changing the GUI and saving it to bazaar. Quickly also provides some awesome features for uploading the code to Launchpad and releasing your program to others in a Personal Package Archive.

What I like about Quickly is that it automates much of repetition surrounding software development and it ultimately allows you to deploy software to a PPA which people can then download and use. Now, PPAs are a little more complicated to install right now: you need to know what a PPA is, know where to find it, and click a few things or enter some commands to switch it on. Fortunately, the rather awesome Ubuntu Software Center which everyone’s favourite Vogt…Michael Vogt…is developing, is going to be extended with functionality to better support PPAs. This, combined with the ratings and review features coming to the Ubuntu Software Center is pretty rocking. I am not sure of the specifics of how PPAs will be supported, but I believe they will first begin on visibility and then follow up with integration features later. If you want to get started with quickly take a look at this entry.

With Quickly able to get folks up and running with development, I wanted to make it easier for opportunistic developers to get their hands on code snippets and examples to learn from. As such, I created the Acire and Python Snippets projects. These projects provide a simple means in which you get access to a freely available regularly updated library of examples, across a range of different areas. With Acire you will always have a growing knowledge base of real code that you can read, run and share, and the community works together to regularly add to and support that knowledge base. The response so far has been great and you can read more about this in my previous blog post.

So, at this point we have all the tools needed to build applications, learn from code examples, and publish packages that ultimately will be visible in the Ubuntu Software Center. The one area that neither Quickly nor Acire has particularly served well is improving on how we collaborate together on software. Few Open Source projects have one sole developer, so we really want developers work well together, in conjunction with translators, documentation writers, bug triagers and more.

To do this we have the rather awesome Launchpad and Bazaar which are a doddle to use. Launchpad provides everything you need to work together on a software project and I have become a bit of a Launchpad fan as I have got used to using it. In my earlier days I tried Sourceforge, Trac and other systems, but Launchpad is rocking it for me.

While I love Launchpad and Bazaar, their integration in Ubuntu could have been better. As an example, to get code in and out of Launchpad so you can contribute to a project, you use the bzr command and the process typically works like this:

  • You download some code from the Launchpad project with bzr.
  • You branch the code: this effectively means making a duplicate directory of the code.
  • In that duplicate directory you add a feature, fix a bug or make some other kind of improvement.
  • You then commit your changes to your local branch: this effectively tells Bazaar of the changes you have made.
  • You then upload your branch to Launchpad (this is called pushing a branch).
  • The final step is to propose a merge. This is when you offer your branch and it’s changes to the project maintainer to merge into the main codebase. Launchpad ties together nicely with bzr to handle this process and has a web front end for doing code review.

Now, understanding how all this works and doing it a few times takes a little getting used to, and much of it is learning how to use the different bzr commands and how they hook in with Launchpad. Well, very recently my friend and yours Martin ‘doctormo’ Owens has released his Ground Control project which provides a graphical interface to the whole process by building it into the file manager in Ubuntu. I cannot tell you how bloody cool this is. It works a little like this:

  • You create a Projects directory in your home directory.
  • Click Places->Home Folder and go to the new Projects folder.
  • In there you can see a button to login to Launchpad. Click the button, enter your username and password. Job done.
  • You now see a a button where you can select a project to work on. Click on it, enter a project name, select it and it creates a new folder.
  • Now go into the folder and there is a button to download the code. Click it, select a branch and the code is downloaded.
  • You can now hack on your feature and a button will appear to commit your changes.
  • Finally, you will then see a button to propose a merge. You enter some text to describe your change, and it is uploaded.

No commands. None. What I love about Ground Control is that it is highly contextual: it is built into the file manager and it only ever shows you a button for what you can do at that time. It is simple, quick and Martin has done a wonderful job with it. Go and see a video demo of Martin showing Ground Control here.

Ground Control is still very very new so expect bugs, but do give it a go, report bugs, and importantly, he is looking for help to make sure it has full translations support. If you have done this before, drop him a line. The Ground Control Launchpad project is here.

With each of these components we are seeing more and more gaps in the integration and ease of the development process getting filled. I am hugely excited about this and I am excited about it bringing more and more people to Ubuntu as a development platform and it ultimately generating more and more Free Software for us all to use. We still have a long road ahead though and plenty of good work yet to do. If you think there is a gap you can fill, come and help us rock it. :-)

  • Joern Konopka

    Awesome, this will help a lot getting more Devs interested into building for Ubuntu.

  • Tom

    Great post and really cool effort.

    One thing that might be a cool addition would be cool bzr frontend like gitorious or github. It would make branches etc. more social.

  • http://www.kumarchetan.com Kumar Chetan Sharma

    I just wrote a PyGTK hello world that instead of showing “Hello World” shows output of fortune command. It was like writing a scratch-your-itch-and-have-fun-too app. I did it in, surprise, 10 minutes. Ubuntu rocks :-)

  • pachi

    IMHO, you’d make a great contribution if Canonical can put some (modest) resources into Glade. It’s underdeveloped due to lack of people working on it, and some features are really close to being little revolutions but need some work.

    Some of the developments that could make a difference are: full support for textview and textentries formatting (richtext support through the use of texttags), pyobject support in liststores (or any other stores), full uimanager and action based menus and toolbars…

    These are really close to being complete, but sometimes need adding the gtkbuildable interface to some gtk+ widgets or some additional thinking (pygobject support, as other bindings may want native object support too, and just adding new types may be worse than using introspection or other nice tricks).

    With some of this changes most of the code tinkering with widgets wouldn’t be needed at all, just some callback code or very specific things.

    Anyhow, good to know that you see big value in the development stack. Casual programmers and hobbyists make make a difference regarding avaliable software, diversity and value of the OS, but work that’s not oriented to the professional developer is being neglected, IMHO, and that makes sense for MS, but not for a FLOSS ecosystem.

  • Ignacius

    IMHO, the only piece which is needed on the list and which would make definately Python be adopted by the masses is the lack of a great IDE which integrates all these technologies into one. This would definately make Python take off

  • http://danieltiecher.com/ Daniel Tiecher

    I can not agree more with what pachi said. This is one thing I realized several months ago but never got time to elaborate and publish it somewhere.

    Microsft tries really hard to give devs awesome tools and frameworks. Why? Because devs (and their CTO, etc.) have an immense power in choosing which languages, tools, frameworks and OSs to use and support when developing software. Specially when their clients have no formed opinion on the matter.

    Compared to the designer view of Visual Studio, for example, Glade (which is a project I use and admire) is simply not on the same level.

    Another thing professional developers find lacking when looking to linux development are more powerful and diverse widget sets. Something in the lines of DevExpress for dotNet.

    As an example, the company I work for have chosen to use C# on a multiplataform software we are developing (even though a lot of our developers are C and Python proficients and our C# knowledge was still crude) simply because they have come to the conclusion that client software development using GTK or even Qt compared to WinForms is a joke (Java is not an option because all of their toolkit suck like hell). And we are not even talking about WPF here…

    The good news is that both the KDE and Gnome side of FOSS plataforms have noticed this and are stepping up to the issue. And on this field, Nokia is doing an amazing job with the Qt framework and QtCreator.

    On our side (Gnome) we are still a little behind them due to lack of integration between our tools but I’m sure we will get there. Looking through all of this awesome tools you talked about, Jone, made me really happy. We just need to bring all of them to a powerful IDE (Eclipse, anyone?), write a great documentation guide on how to use them and we are set.

    I’m glad that I’m a web developer on my day job (Python and some PHP or Java from time to time) and I can use FOSS all day long because when it comes to web development, we are the leaders. But if I was a desktop developer problably I would bton the other side of the fence.

    anyhow, sorry for the long rant. =)

  • http://www.maximebf.com maximebf

    Great post and great ideas.

    However I don’t think that will be enough to attract casual programmer. While these tools could really help, I think Ubuntu is really missing an official SDK and a centralized documentation (or at least a big hub that points in the good direction). Also it must be easier for these developers to distribute their software. Apt + PPA is great but I don’t think new users understand well the concept and have trouble adding PPAs (as it is not really easy). The Software center really needs a category that list all applications, even if you don’t have the ppa. When choosing to install one, the ppa would be added and the application installed.

    But this is definitely the good direction!

  • http://dylanmccall.blogspot.com/ Dylan McCall

    Nice! Your picture shows something interesting, though: Every one of those projects needs an icon as pretty (and as scalable) as Software-Centre’s :b

    I would love to see Quickly pick up Vala at some point for higher performance applications (eg: ANYTHING that runs at login or in the background). It’s a really beautiful language, it’s easy to learn and it reminds me of Quickly itself in places: VERY opinionated.

    The language itself is modelled directly on GObject, so it fits perfectly on this platform and talks to libraries like dbus-glib in an incredibly native feeling way. The compiler, as well, has very few switches or fiddly bits. It does a lot of thinking for the user, choosing sane defaults, abstracting away the complexity of gcc and friends. It does a great job with that.

    As far as development stack is concerned, I think we still are being blocked kind of heavily by GTK+. I like the design of the toolkit, but I think developers expect to be able to implement animations, effects and the like and simply can’t with GTK. The day when that animation support lands in a stable release will be a very, very happy one.

    Hopefully when it does, somebody can arrange a good library with common effects, to keep things consistent and fun.

  • http://theravingrick.blogspot.com rickspencer3

    Jono,

    Don’t forget about projects like http://launchpad.net/quidgets, that strive to make Gtk programming even easier. There is also kiwiw, gthkhelpers, and a few others around, we should combine resources to create an easy and fun widget library built on top of Gtk as well.

    Cheers, Rick

  • Matthew Farrell

    Thank you for this post, it should be very helpful for me.

    Part of the problem with learning how to program and contribute is making an environment in which you can examine, modify, and otherwise poke at code to see what is going on. These tools should help me get in the loop.

  • amadeo

    What about Qt? Works in a lot more environments, and you can use several bindings and languages. It is clearly superior, and a tool and in terms of deployment.

  • ethana2

    So, that idea I had a few years ago for Ubuntu Developers Edition with all this stuff preinstalled instead of f-spot, pitivi, and OpenOffice… Does it have a better chance now?

  • http://topsy.com/tb/bit.ly/dsHF4t Tweets that mention Connecting The Opportunistic Dots | jonobacon@home — Topsy.com

    [...] This post was mentioned on Twitter by Jono Bacon, Scott Roberts, The Open Sourcerer, Planet Ubuntu, toorghezi and others. toorghezi said: Connecting The Opportunistic Dots: Something I have talked about extensively recently has been my passion to see… http://bit.ly/dsHF4t [...]

  • http://forums.opensuse.org/opensuse-marketing/432223-develop-suse.html#post2114292 Develop for SuSE – openSUSE Forums

    [...] for SuSE I read Jonos nice article about getting up and coding in no time for Ubuntu Connecting The Opportunistic Dots|jonobacon@home Are there any simple guide like that for OpenSuSE? (Hmm, why do I get that inner picture of a [...]

  • Vladimir Malyk

    It’s really good idea!

    Also, you should look at http://sourceforge.net/apps/trac/pygtkmvc/wiki

  • Unnamed_Hero

    Ubuntu is not the only GNU/Linux distributive. It is not very reasonable to say GTK/Python/Gnome is the only platfoms to develop GUI apps. Your neighbours from Kubuntu can approve it. Also, there is KDE desktop environment with very powerful Qt framework(also have good python bindings). What about it? I know, there is Gnome3 coming soon, and maybe you need more PR for it, but let’s back to the real world. Or may be this message intend to some people using suspicious Mono framework?

  • http://blogs.alfresco.com/wp/wabson/2010/02/06/opportunistic-alfresco/ Will Abson on Alfresco » Blog Archive » Opportunistic Alfresco

    [...] post from Jono at Ubuntu on making the Ubuntu platform better suited to opportunistic development, basically helping people who want to ’scratch an itch’ [...]

  • http://www.linuxmint.com/blog/?p=1269 The Linux Mint Blog » Blog Archive » The Mint Newsletter – issue 100

    [...] Bacon on developing apps for [...]

  • dz0

    Where could I find the slides of lectures, that are over, I do find IRC logs, but no slides :/ https://wiki.ubuntu.com/MeetingLogs/OpWeek1003

    by the way, can I install Lernid on Jaunty?

  • http://leftyfb.com/2010/03/18/trying-my-hand-at-developingbug-fixing/ leftyfb's Blog » Blog Archive » Trying my hand at developing/bug fixing

    [...] files to /usr/src/gstm1.2 including the packaging bits. And then I remembered about this whole Opportunistic developers thing and more specifically Ground Control by Martin Owens. I already had this installed so I just [...]

  • http://freakaboutlinux.wordpress.com/2010/03/26/introducing-pytask/ Introducing Pytask! « Ryan Macnish

    [...] Quickly app, which i see as a great and easy way to manage any small projects, especially ones that scratch an itch. Another little app i frequently use is called Acire, which is a great app if your fairly new to [...]

  • http://blog.lynxworks.eu/2010/09/software-centre/ Glasses, age, applets and the Software Centre @ Lynx Blog

    [...] remember Jono Bacon posted about “opportunistic developers” a while back and he’s quite right. We have the [...]