Feb 10

Here is an useful Video from Perforce on the many useful features for admins in P4. I liked the license file replacement and the management of the protections table from the UI:

Aug 02

Ever wondered how you can quickly get to know your permissions in perforce? “p4 protects” is the answer. Run “p4 protects” to know the lines in the protection table that are relevant to you. If you have the super user permission then you can check the permissions of other users and groups as well. This is a quick and much safer option than trying to read the protections table.

Here is the official documentation of this command:

http://www.perforce.com/perforce/doc.current/manuals/cmdref/protects.html

Dec 03

Perforce clients or workspaces act as the interface between the files in the depot and their copies on your disk. Perforce manages all info about the clients only in the server as against how Subversion manages them. Hence, if you happen to make changes to files directly through the OS and not through Perforce, the client metadata goes out of sync.

But perforce provides some help to manage this situation.

Find P4 managed files that are missing on your local client

p4 diff -sd

Find files that are edited on your local client, but unopened


p4 diff -se

Similarly, “p4 diff -sa”, “p4 diff -sb” and “p4 diff -sr” help you find out files that are out of sync with the perforce server meta data.


Read more about this command here.


Oct 02

As smart phones are fast becoming the norm across the world including India, serious interest in mobile app development is on the rise. Developing applications for smart phones is something that can be taken up by individual developers easily on top of their day jobs. And there are plenty of market places where you can showcase your work (Apple app store, Android market to name a few). But the biggest challenge is in converting your idea into applications that can run on most of the leading smart phone platforms out there. Interestingly, there are already a number of notable cross-platform app development tools available on the market to help you develop applications that run on most of the platforms. Here are a few of them:

Rhomobile Rhodes

This is a Ruby based framework. You just need to write your app in Ruby and this framework takes care of converting your Ruby code into the native code of the target platform.

PhoneGap

This framework lets you develop your application using HTML, CSS and Javascript. Your application is run on the target device using the device’s browser object and PhoneGap’s libraries. This framework supports Palm as well.

Appcelerator Titanium

This is implemented using Javascript and JSON. This currently supports only Android and iOS. It comes up with its own development environment. Moreover, you will be able to extend your application using the respective native language if you wish to do so. After going through this briefly, I kind of liked this framework. This is probably the first one I’ll be trying out.

Application Markup Language (AML)

Application Markup Language, or AML, is a simple XML-based language that allows you to easily build a clean, functional, native application for your mobile device. The AML library implementation is open-source, and doesn’t require any imports from your package to work. AML doesn’t require you to know the details of how the mobile device builds its views. It doesn’t depend on some extra plugin installed on your device, and it doesn’t run your app code through another service.

In addition to these cross platform environments, you have a few interesting platform specific tools such as Google’s App Inventor, Driod draw etc. If you are looking to start trying out mobile app development, take a look at these and chances are that you will start with one of these. Most of these are free and open source.

If you come across more interesting mobile app development tools, please do share it.  Write a mail to me or comment here.

Oct 01

App Inventor for Android is a cool google labs project that provides a web based IDE for developing Android applications with zero coding! The project is aimed at non programmers and students of non computer science background to enable them to contribute with Android mobile applications!

It is currently in invite only mode. You need to apply for it and wait for the invite. It took about a few weeks for me to get my invite.

App Inventor provides you with an easy to use UI where you can drag and drop your design elements on to your screen and easily add some logic to these elements. The programming logic is designed by something called as a “Blocks editor”. As the name suggests, the blocks editor lets you construct your logic by placing blocks which fit together. Again, this is easy to use and very intuitive.

In brief:

  • Drag and drop objects (buttons, text boxes etc) on to your screen
  • Edit their properties (Name, Description etc)
  • Define your logic using the blocks editor
  • Connect your phone to your computer
  • Run your app!!

Pros
  • Very easy to use. You can deploy your first app within minutes
  • You do not need a phone to try this out. You can connect this to an emulator as well
  • Good for prototyping
  • You can think of apps that you can develop for your own use
Cons
  • Doesn’t give you the Java source code and hence you can add more to your prototype
  • As of now, allows you to create only one screen
  • Can’t publish my app to the android market
  • Doesn’t support the entire API set
Verdict
  • It’s more of a toy right now
  • But an effective and easy way to get started with Android app development
Sep 14

Stumbled upon the following wiki book:

http://en.wikibooks.org/wiki/Release_Management

Very brief, but gives the basic info anyone new to this field might need. It would be nice to contribute some stuff to this page.

Sep 13

Came across this cool stuff called S4LA - Scripting Layer for Android, that lets you develop andriod apps in many of the popular scripting languages like Perl, Ruby, Python, TCL etc! The intention is to let you quickly prototype your apps before jumping in and developing the production ready version using Java.

I have been playing around with this for a few days. Here is a brief step-by-step on how to get started with this:

1. Get the android SDK setup on your box. This is straight forward. Please check Android Dev page for details.

2. Create a Virtual Device. Please check the Android SDK pages for info.

3. Install SL4A on your Virtual device

  • Download the sl4a apk from the project page
  • Run the command “adb install <sl4a apk path>” to install it on your virtual device
  • If you want to install this directly on your phone, scan the barcode displayed on the project page. You will need to enable ‘apps from other sources’ on your phone for this to work

4. Install an interpreter

  • SL4A appears as an app in your phone or your AVD (Android Virtual Device). Run it and use the menu “View->Interpreters” to add your favorite interpreters

5. Now you can edit and run your scripts right on the phone or the AVD

6. If you wish ot to edit your scripts right on the phone, you can edit in your computer and push the script file to your device and run it there

Some thoughts on this:

  • I  absolutely like the fact that I can write some stuff using my favorite perl
  • It is easy and straight forward to set this up and get started
  • On the flip side, if someone wants to run my scripts on their phone they need to have the interpreter installed, which most folks might not prefer

Overall this is a great start. This is something which you can expect to get only on android!

Sep 11

Recently while writing a small script, I needed just the list of sym links present in a dir. It is pretty straight forward. Thought of jotting it out here so that it could be useful for someone else..

Here are two simple ways:

Use the -F option to ls that adds an ‘@’ at the end of every sym link and then pick your hits from the result.

ls -F | awk ‘/@$/’

Another way: Use the ‘l’ mentioned at the beginning of a sym links line to pick your hits..

ls -l | awk ‘/^l/’

The second one gives you the link path as well.

Jul 30

Recently, I was in a situation where I had to make sure that two branches in P4 are just the same - file by file. You might find yourself in this situation if you use Release Branching methodology to mange your code bases.

Thankfully, P4 has a rather direct way to achieve this. ‘P4 diff2′ command takes care of this task.

Following takes care of diff’ing files belonging to the given branchspec:

p4 diff2 -b [branch]

Aug 14

Read on the official P4 blog that Perforce is considering the option of adding “Perforce Certified Administrator” to their list of certification offerings. They are running a survey to assess the interest level. I would suggest you to take the survey if you will be interested in this certification.

I have responded positively for the survey and said Yes for the certification mainly for two reasons:

  1. Will get to know the nitty gritty of the internals of the system which I would give a miss otherwise
  2. Will be a good recognition
Waiting eagerly to see the outcome of the survey!