Archives for the ‘Eclipse’ Category

22 May 2015
2

Appcelerator Tip: How to recover a GIT Reset in Titanium Studio

This post is an example of how a GIT reset in Appcelerator’s Titanium Studio almost cost me 6 hours worth of work and how I managed to recover what I lost.

My Working Environment

Apple OSX 10

Titanium Studio

eGit and Mylyn for Bitbucket

Let me add some context

Once upon a time, about a year ago, I spent the most part of my day working on a mobile app, when a critical issue arose that forced me to switch my project’s current source control branch (using eGit Source Control), to its Master branch. After switching branches on my project, I made one small temp modification to the tiapp.xml file in the Master branch, then published a mobile build of the project to iOS.

I sent the updated mobile app to my client and all was right with the world again.

Then…

After I was done deploying the iOS fix, I switched back to the branch I was working on, when I received the following message:

Funny though that I didn’t get this message when switching from my current branch to Master initially, but anyways. I clicked on “Reset” because the change I made was temporary, so I was happy to have it reset to what is was prior to the change.

Then, came the fear. All my current work was gone. 6 good hours GONE!!! This was not my finest moment. While reacting to my client’s request, I accidentally forgot to commit my work to BitBucket. I tried all sorts of rollbacks against my project, but nothing was working. I searched online and only get mentions of reflogs, which won’t help in my case.

I was ready to take a walk…cry a little…and come back to start over. Before doing that though, I opened one of the JS files that was reset, to see how many changes I would need to make, when i tried the following:

I right-clicked on the JS file and noticed the option “Replace With\Local History“.

Screen Shot 2014-05-21 at 7.28.17 PM

Now, when you perform this action directly against the project’s root folder (which is an option and was the first thing I tried), you don’t get any positive results. But, if you do this directly against the file in your project….IT WORKS!!!

Eclipse/eGit was managing my saves per file automatically, so all I needed to do was perform individual replacements for every file in my project that was affected.

5 minutes later I was good to go.

Summary

First and foremost…based on what happened to me, I strongly recommend creating a habit of checking in your code in multiple increments per day and not just at the end of the day. I would’ve cried hard had I needed to spend an additional 6 hours unnecessarily.

Finally, what I mentioned above is relevant to Titanium Studio, but I’m almost positive this same exercise could work in other development environments, especially Eclipse.

Till next time

John :)

21 Nov 2012
3

Check the Eclipse version of your Lotus Notes 8 Client

Hi everyone. Just thought I’d blog this quickly. I wanted to check which version of Eclipse is being used for my Notes 8.5.3 FP1 Client and it was a touch tricker than expected. Thanks to Nathan T Freeman, I now know where to find this:

1. Open your Notes Client and click on “HelpAbout”.

2. Click on the “Plug-in Details” button.

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

3. Sort the “Plug-in Name” Column and search for “Eclipse UI”. You will see the version in the Version Column. In my case it’s version 3.4.2……

 

 

This is baseline for determining the overall version of Eclipse that’s used for Lotus Notes.

 

Hope this helps.

Cheers.