Linux- How to check contents of .gz file
To check the contents of a .gz file in Linux, you can use the zcat command. Here is how you can do it:
zcat employee_data.csv.gzThis command will display the contents of the employee_data.csv.gz file. If you want to see only the first few lines, you can pipe the output to the head command:
zcat employee_data.csv.gz | headThis will display the first 10 lines of the file. You can adjust the number of lines displayed by using the -n option with head:
zcat employee_data.csv.gz | head -n 20This will display the first 20 lines of the file.