• Twitter
  • Facebook
  • Google+
  • Instagram

About me

Let me introduce myself

A bit about me

I am a self starter and ambitious about learning new technologies deeply and thoroughly. I have 3+ Years of Mobile Application Development Experience for Android and iOS platforms.

profile for Salman Khakwani at Stack Overflow, Q&A for professional and enthusiast programmers


Salman Khakwni

Personal info

Salman Khakwani

Phone number: +(92) 343 201 2045
E-mail: me@salmankhakwani.com

Skills & Things about me

Mobile Developer
Problem Solving


My latest posts

How to Rename a Local Branch Using Git

Naming a git branch incorrectly and pushing it to the origin happens often during continuous integration. Fortunately, there is a way to rename the existing branch without losing all your precious commits. You can use the following steps for successfully renaming the git branch:

1. Renaming Local Branch:
In case you are on the same branch, then use the following git command.
>git branch -m new-branch-name

In case you are on the another branch, then use the following git command.
git branch -m old-branch-name new-branch-name

2. Delete the old-branch-name remote branch and push the new-branch-name local branch:
git push origin :old-branch-name new-branch-name

3. Reset the upstream branch for the new-branch-name local branch:
Move to the branch and then, enter the following command
git push origin -u new-branch-name

Note: Please don't forget to pull the latest code before making any changes.

Keeping Entire Package Using Proguard

Keeping Entire Package Using Proguard

Pro-guard was released in 2002 and since it's first public release it has been downloaded over tens of  millions times by more than one million developers. Pro-guard is mainly used for obfuscating applications. Also, shrinking the unused code and optimization of the Java byte-code is catered by Pro-guard. Since, Android uses Dalvik byte code, some optimizations doesn't work well.

There are always some scenarios, in which, we need to keep some of our packages from being obfuscated by Pro-guard. The most popular scenario is when we are using GSON and we have got models (POJO) that are used by GSON library. In this post we are going to dig into the ways of keeping entire packages from Pro-guard.

There are several ways of achieving this, we will look into them one by one.
1. Keeping names of public classes:
-keep public class com.salmankhakwani.application.network.gson.models.*

2. Keeping names of public classes for packages and sub-packages:
-keep public class com.salmankhakwani.application.network.gson.models.**

3. Keeping names of public/protected/private classes/methods/fields for packages and sub-packages:
-keep public class com.salmankhakwani.application.network.gson.models.** {
  public protected private *;

I hope this helps anyone who got into similar scenario of keeping packages from Pro-guard.

Freelancing Heaven

I have been working as a mobile application developer for the last 3+ years. I have worked on a range of applications including video editing, image processing, drawing & annotations, document manipulation and simple web-service consuming client applications. I have worked both independently and with in a team, it has been always my first priority to deliver an application that is bug free on the agreed time and I always try to give my 100% for that.

My favorite programming language is Java and I have worked on Android and iOS mobile platforms. Prior to working as a mobile application software developer professionally, i used to work as a part time freelancer on Elance along with my University studies and I did pretty well on Elance with a 5.0 average rating.

Recently my interests are grown again into working as a freelancer and I have been doing research in finding the best freelancing platform available. My search ended when i stumble upon Toptal.com, it has everything that makes a freelancing website perfect. Here are some of my findings that I want to share with you about Toptal.

Elite Community of Freelancers:
Toptal has a community of best freelancers available for hire, they have a bullet-proof screening test to identify the best engineers. Only 3% of the applications among thousands are accepted from thousands of Applications received by Toptal.

Long-term Working opportunities:
With my experience I felt that It is hard to find long-term projects on other freelancing websites because most of the work posted there low paying and short-term. While on the other side of horizon there is Toptal, which promises to provide long-term projects with competitive salary. Once you get selected you also get to work with Toptal's prestigious clients such as J.P.Morgan, Airbnb, Zendesk, etc.

My interview process with Toptal has just begun and I would really like to get in and become one of the freelancers in their community. If you are a Software Developer/Engineer, then i would recommend you to do the same.


Get in touch with me

Email adress


Phone number

+(92) 343 201 2045