Domino Designer and .git folder mystery

Twitter conversation about version control has brought me to the debate about .git folder appearing in NSF file and how to avoid having it there. I remember seeing one NSF file with .git folder in it a while ago and I’ve deleted it from NSF without any consequences. NSF is still fine, git repository it is connected to as well. But Cameron Gregor (and probably Sean Cull too) had different experience. Cameron was kind enough to “record” how this happens on his computer. When I was reproducing his steps I noticed one step different to my usual workflow. It turned out that although I do not use EGit plugin directly to commit changes from on disk project to git repository I am in fact using it in one configuration step. And this turned out to be the crucial step to make it work right. When you create on disk project, be it by exporting from NSF or cloning remote repository, next step should be to show DDE that this project is under version control. This is done by right click on ODP in Navigator, Team - Share project…, (optional) choose Git (this step is not shown if you have only one VCS plugin installed in DDE), check Use or create repository in parent folder of project and click Finish. From now on DDE knows this project is under version control and ignores .git folder during sync between NSF and on-disk project.
Read more

BLUG 2013

I am writing this at Brussels airport on Sunday afternoon waiting for evening flight back to Prague. Since Wednesday when we came to Leuven to attend BLUG 2013, weather got really bad and although we have March 24 whole Brussels and Antwerpen (and I am sure more other places) are covered by snow and it is freezing out there. Yet even this really unpleasant ending could not spoil great feeling I have about this year’s BLUG. In fact all previous BLUGs as well. This was my third. First one in 2011: as an attendee who has heard about it in This Week in Lotus Podcast and impulsively decided to go Antwerp by bus (it took just 15 hours or so). I met couple of people there that time and we are happy to see each other during BLUG every year. Second time I went as a speaker and that was hell of an experience! And it allowed me to meet even more people I knew only from their blogs or from Twitter, it allowed me to have the opportunity to speak to the guys from IBM who really do some work there :-) and I was able to tell them what I miss in XPages development environment. And I was extremely happy to see some of it solved (or at least being worked on) this year (see AD205 from Connect 2013 - unit testing and testing in general). This year I was not speaking but it still was great event for me. Watching other speakers nervously checking their presentations for 100th time, running demos to make sure they will work live on stage (they won’t, they never do). Chatting with people around coffee machines, when waiting for sessions, exchanging experiences and ideas after sessions… Add some wine and beer and you get a wild bunch of geeks enjoying speed sponsoring part, some of them really listening to the sponsors who are desperately trying to do sales pitch in 3 minutes…so much fun! It is hard to believe that you can use “sales” and “fun” in one sentence, right?
Read more

Call doc.closeMIMEEntities after touching doc.getMIMEEntity

Another stupid mistake has taken a lot of my time last week. I developed a small library to provide function(s) to move attachments from rich text fields to separate db (nsf or some other). This function was supposed to be part of bigger process, so saving of document being processed was meant to happen in other code. That is why I had not tested what doc.save() would do. My tests were just checking destination db for created records containing moved files. Other part of process was developed by colleague of mine, he tested his part expecting my function to return true or false. And the function was returning true or false. But when his code started to call real implementation of my function, our server crashed with nice and reassuring PANIC: LookupHandle: handle out of range.
Read more

Dynamic binding of fields bug?

I was developing very simple XPages component recently and because it was basically loop through a list of field names (and the task was to show something for each of them) I have used repeat control and inside of it there was custom control with properties such as fieldName (String), label (String), isRequired (boolean) and so on. In the custom control I was binding fileDownload and fileUpload controls (based on read/edit mode) to document field via EL as "document1[compositeData.fieldName]" where document1 is data source defined in XPage that “calls” this custom control. Everything worked fine and as expected, I had one generic custom control to “show” all fields I wanted. Parameter isRequired was passed to validation formula, …bla bla bla….I was happy with the solution.
Read more

Wanna use Git (with DDE) and you're afraid of command line? Try GitHub for Windows

Last two blog posts were about using Git and git-flow with DDE. I use command line as main working interface when interacting with Git repositories. I am used to it, I am more productive this way. But If you’re not used to use CLI, there is GitHub for Windows available for you. Go try it! And if Git doesn’t sound familiar to you, try it in your browser, without the need to install anything.

Using Git with Domino Designer - the hardcore way, part II.

Today’s talk about setting up a development workflow for a new project reminded me of my promise to write the second part of this blog post. So here we go: Installing Gitflow Just read and follow the instructions in gitflow wiki. You may also want to setup very handy command completion, instructions are here. Start using it In the folder with your on-disk project (in our case it is C:\Program Files\ibm\lotus\notes\data\workspace\git_test) simply run the command git flow init and answer the questions (simply accepting the defaults is just fine). And that is all you need to do! From now on you can use all giflow commands in this project. If gitflow is completely new to you, here you can find some links to start with.
Read more

Using Git with Domino Designer - the hardcore way

This is a first part of posts on version control with Git for Notes developers. I’m writing it as an addendum to my BLUG 2012 session “Version control for Notes developers”. Version control for Domino Designer projects - using command line Git (aka the HARDCORE way) Designer 8.5.3 has built-in capability to link NSF/NTF files with so called on-disk projects that can be used by version control systems. That alone is not enough to successfully use version control systems directly from Designer. But it is enough to use them from the command line! From now on I’m assuming that you’ve created on-disk project out of one of your NSF/NTF files and this on-disk project is called “git_test”.
Read more

BLUG 2012: part 2

Day 2: Friday Waking up in the morning is not my hobby (“good morning” is an oxymoron for me). And after all those beers (Belgian beers are usually stronger than Czech ones, but we are used to drink 0,5l as “one beer”) this morning was especially hard. But we made it to the Crown Plaza Hotel just in time to attend “How XPages became mobile” with Earmon Muldoon and Paul Withers. Combination of coffee and interesting information was a nice start of a day. Speaking about the coffee: it was great all the time! Next “The Lotus Notes Dev Quiz” was fun! 20 questions with 4 possible answers, some of them very easy, some of them not. I learned a lot there and liked it very much. Good job, Theo. “Swimming in deep waters” by Sean Cull and Andrew Champion about lessons learned from real world XPages project - I like to hear other people’s real world stories (read “mistakes”), because it allows me not to do the same mistakes. Very important session, very good one. I took a longer lunch break (as I do all the time) so next session I attended was Ulrich Krause’s XPages: Beyond the basics. Ulrich was one of those two people being there in time for my session so I wanted to “pay him back”, but it was not necessary, there was enough people already. I wonder how he did that :-) Next session in the same room was Eureka moments: The JSF knowledge by Paul Withers. Full of very important information for developers trying to better understand XPages lifecycle. And I have to mention a role of a server (in one case with write only memory) played by Abigail Roberts. I really liked BLUG 2012. New experience as a speaker, great sessions and everything. Not to mention that I won TLCC course during closing session! See you next year at BLUG!

BLUG 2012: part 1

BLUG has been really good event this year. Again! Theo is a great host, doesn’t matter if you’re speaker or attendee, he treats you well. Extremely well. All that chocolate in a speakers room! I was full of energy and good mood until late night hours even after the whole busy day at a conference. Splendid! Day 0: Wednesday Being a speaker for the first time on LUG event (except Czech one) and presenting in English for the first time ever was kind of difficult for me. I was very shy at the opening event on Wednesday evening (and usually I’m not shy at all), Sean Cull helped me by “dragging me” into the conversation (thanks!) and then it went just fine. I met several speakers I had talked to year before and they remembered me! The fact that I had traveled 15 hours by bus last year to get to BLUG was probably very unusual, I don’t know why :-) Martin Donnelly introduced me to guys from XPages and Connections development team and it was an evening well spent. And those nice beers! And synchronized swimming! I had to leave early but it was for good, because having hangover and speaking is not my favorite combination.
Read more

My BLUG presentation on version control

Here is the slide deck for my BLUG session on version control