$ 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
Wednesday, August 31, 2016
Monday, August 29, 2016
To list directories in unix
$ ls -d */
It will display only the directories within the current directory
It will display only the directories within the current directory
Compare two files in unix
$ diff file1 file2
-> It will display the line by line differences between file1 and file2 contents
$ cmp file1 file2
-> Binary files comparison
-> It will display the line by line differences between file1 and file2 contents
$ cmp file1 file2
-> Binary files comparison
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
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
$ 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]
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
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
Subscribe to:
Posts (Atom)