Wednesday, August 31, 2016

Display line numbers in a file

$ cat -n filename.txt

It will display line numbers on the left hand side for each line in a file


If you want to display line numbers in vi editor

$ vi +linenumber filename.txt

In command mode you just type :set nu to display line numbers

Friday, August 26, 2016

How to find device information in Android phone

Type *#*#4636#*#*

It will display all the phone and battery information on screen

Formatting date in Unix

For mm/dd/yy hh:mm:ss format

$ date +"%m/%d/%y : %r"
08/26/16 : 12:03:52


dd/mm/yy hh:mm:ss format

$ date +"%d/%m/%y : %r"
26/08/16 : 12:04:08


dd/mm/yyyy hh:mm:ss format

$ date +"%d/%m/%Y : %r"
26/08/2016 : 12:12:55


yyyy/mm/dd format

$ date +"%Y/%m/%d"
2016/08/26



Thursday, August 25, 2016

To find the IMEI code in Android phone

There are two ways to get the IMEI code in android phone

Type *#06#

It will display IMEI code on your screen

Another way is

Go to [Settings] -> [About Phone] -> [Status] -> [IMEI]

Wednesday, August 24, 2016

To find the software version of Nokia E72

Type *#0000#  It will display the software version information

Ex:

Software version
091.004

Sofware version date
02-Jan-2012

Custom version
091.004.C00.02

Custom version date
02-Jan-2012

Language set
40.01

Model
E72-1

Type
RM-123

Latest update
2/1/2012