Susanna Huhtanen adventuring in software

Archive for the ‘GNOME’ Category

A morning flight and arriving in time for lunch. Starting out with lunch was nice, seeing GOPW students and GSoC students all at once. Diego had come up with a game for the interns. So we were teamed up and for the next two days we will run around the venue and ask silly questions, so please, spare some of your time and share your wisdom, weather it is of your first GUADEC or about the Swedish Conspiracy.

OPW is nearly finished, but my work with the documentation on the other hand is not. After you have opened the door of documentation you can never really close it. There is always some room for improvements. Being introduced to a community thorough a program like this is brilliant. Initially, you have the brand of being a newbie and you are allowed to make all the mistakes and ask all the silly questions without feeling embarrassed.

My project, JavaScripter’s guide to GNOME has found it’s target, the developer docs. Talking about the developer story in Brno formed the idea that we need to have a staggered approach to the docs. Something for the beginners and something for more advanced users, so something for different skill levels. This way we can attract more people with different skill sets. If we can get to developers in an early stage, well have amazing developers later on with thorough knowledge of the platform from a longer time period.

For me the defining moment in this project was the Brno hackfest. That event sealed the feeling that I have found something I feel I belong to. GNOME, after the hackfest there is no way you are going to lose me, whether you like it or not!

The leap to become a developer has been a joyful one, with the necessary WTF moments. I have learned a lot and I still keep learning new things every day. I can’t emphasize enough of the meaning of the hackfest for me, it made all the difference, so all the future students should be brought to a hackfest as soon as possible. That is the way you get to keep us. For the future OPW and GSoC interns I have just one advice: enjoy.

My transition from a GNOME user to a developer has been in progress for two months now. I’m enjoying the challenges, but one constant annoyance has been bothering me along my journey:

The transition from user to developer seems to assume that in between I have had time to hack Linux for 10 years.

Well, I had a total of 0 days for that. I have grown up with the pleasure of not needing to know all the mysterious commands in terminal to get my Ubuntu running. Yes, I have memorized a couple of handy ones (killall -9 the programs!) but as a whole I’m a GUI-girl. I love to make small apps for myself to use, I like coding, but still without the OPW I would have given up already. For me the stumbling block is that the leap from user to developer is huge!

The thing that prompted this post was the setup for JHBuild. I felt uncertain and there were many things I wouldn’t have dared to do without the help of a friend. My dream would be to able to concentrate to the main thing itself with necessary information available without the presumption of being a hardcore Linux hacker.

There is need for both kinds of documentation: for those who are familiar with every nook and cranny of GNOME and Linux, and for those who have just had the great idea that they could have something to give to this community. I’m working towards my dream of having the latter, and I hope my documentation efforts will make this path easier for the enthusiastic hackers that come after me!

Working with small JavaScript apps for GNOME3 has led me to a wild exploration around internet, the quest for knowledge. The quest led me to trying to figure out two things – how to use different files from the same folder in your JavaScript app, and how to make asynchronous HTTP requests. I can tell the quest was a tricky one but now I can present you (queue dramatic music) my findings:

The first problem was brought up by wanting to separate asychronous calls to a different file. How can I reference the other file in my gjs code? The solution ended up being very simple. Just replace the normal gjs yourapp.js with this:$ GJS_PATH=`pwd` gjs yourapp.js

in terminal in the folder your files are. Then the file can be included simply with:const SomeClass = imports.myotherfile;

Where SomeClass is the variable that will hold any functions exported by the other file (by having those functions defined into the global namespace there), and myotherfile.js would be the name of the file.

You can see what keys are available through imports by running this JavaScript code through gjs:

for (i in imports) {
print(i);
}

If you want to distribute your files in different folders the GJS_PATH environment variable must contain the correct path.

As we see, pretty easy but hard to come by amongst all the information of internet. Maybe one more post about it will ease the search for the next person trying to figure this out 🙂

Then we get onwards with our asynchronous calls. HTTP get, using async libsoup. Yet again a simple thing but hard to find.

My first reaction to the new GNOME 3.2 was that I hate it! Resistance to anything new lives strong in me, apparently. Then the realization kicked in: I can make it work exactly like I want. Modifying the JavaScript-powered GNOME Shell is as easy as hacking a web page.

All of a sudden, after an hour of first whining and then hacking, GNOME 3.2 feels like home and I’m actually liking this ease of modifying my desktop to my preferences. This desktop is mine and I could have pink flying ponies in it if I wanted to. Brilliant!

The plans for the JavaScripter’s guide to GNOME 3. (or the cookbook as I call my project now) are advancing. The initial roadmap was layed this morning with Cosimo Cecci. Looks like I shall first dive into GNOME, explore the platform, read a lot of code and try to identify some patterns which are more common or important than others. Based on my views I will make a draft of what should be included in the cookbook.

On Tuesday I participated in Helsinki’s first JSmeetup. The thing that suprised me a lot was the fact that nearly no one knew of the possibility to write programs for GNOME with JavaScript. I promised to give a small presentation about the subject in February when my cookbook is looking a bit better. Making all the different possibilities known to developers out there is an important task we have to deal with.

First week on work is finally happening and I’m happy to work with this project. Taking a plunge to GNOME with a wide smile on my face!

New and exiting adventures ahead. I got GNOME Outreach Program for Women internship. I’ll be making a “JavaScripter’s Guide to GNOME” starting on December 12. The idea behind the guide is to enable web developers to utilize their skills in GNOME 3. development. I would explain how to structure an app, how to create windows, add content and functionality to them, and how to connect with various services of the platform, and build the necessary project templates to support it.

I believe that with the help of my mentors Cosimo Cecchi and Johannes Schmid I’ll be able to make a guide that will truly ease the way towards GNOME 3. And as a bonus I’ll have a chance to get to know a new community and make some new friends.