Remove a file from tracking in git

So you have added a new file to .gitignore or you have just added a new .gitignore file to your existing repo. The problem is same you don’t want git to rack one or many files. This can be archived in simple 3 step process. Assuming that you have already added or updated .gitignore file … Read more

Delete a git branch from local and remote

Git branch can be deleted easily using following commands Most of the time remote name is origin. For deleting git branch locally you can use following command If you are working in a large team and you don’t want to keep deleted branch locally you can prune your repo by using following command Hope this … Read more

Git revert to previous commit

There are situation when you mess up so bad you want to just go back and restart again. Fortunately If you are using Git then you can do it. We will be discussing ways in which git allows you to revert to previous commit 1.Git reset Git rest moves your head to a specific commit. … Read more

Change Status Bar text color in iOS

When you need to change the text color of status bar to white in order to enhance visibility you can proceed as shown below Set the UIViewControllerBasedStatusBarAppearance to YES in the .plist file. In the viewDidLoad do a [self setNeedsStatusBarAppearanceUpdate]; Add the following method: In order to cater for ViewControllers embedded in a NavigationController use this insted SwiftUI For swift UI add … Read more

Understanding UIView ContentMode with a simple example

Most of the time there is confusion about various content modes. I would like to clarify all 13 of them in this post. There are 13 content modes as listed below Scale To Fill Aspect Fit Aspect Fill Redraw Center Top Bottom Left Right Top Left Top Right Bottom Left Bottom Right Now I would … Read more

Making RGB colour in Xcode

I remember when I first tried using the colour directly from photoshop into my project the colours were appearing whitish while it was yellowish in photoshop the colour value was Color-R-160, G-97, B-5. though very basic but somehow I could not take into account that I need to give a value between 0 and 1.0. … Read more


Join group of Software Professionals