×

This article covers the different ways in which the "cal" command can be used on a Linux Mint 20 system. In fact, the cal command is a command line utility for displaying a calendar in the terminal. It can be used to print a single month, many months or an entire year. It supports starting the week on a Monday or a Sunday, showing Julian dates and showing calendars for arbitrary dates passed as arguments.


Examples of using Linux "cal" command

1. To Display the calendar for this month, with today highlighted:

$ cal

2. To show the calendar for this month, but do not highlight today:

$ cal -h

3. To Display last month, this month, and next month:

$ cal -3

4. To Display this entire year's calendar:

$ cal -y

5. To Display the entire year 2000 calendar:

$ cal -y 2000

OR

$ cal 2000

6. To Display the calendar for December of this year:

$ cal -m December

OR

$ cal -m Dec



This article covers how to use the pwd command in Linux. In fact, pwd Linux command is mainly used for printing the name of the current working directory. Examples of printing the current working directory, avoiding symlinks and how to get the current working directory in shell scripts.



This article covers a few basic examples of the touch command. For more information use 'man touch' to view the manual page. In fact, the touch command is a standard command used in UNIX/Linux operating system which is used to create, change and modify timestamps of a file.


Touch Command Options

  • -a to change the access time only.
  • -c if the file does not exist, do not create it.
  • -d to update the access and modification times.
  • -m to change the modification time only.
  • -r to use the access and modification times of file.
  • -t creates a file using a specified time.



This article will guide you on how to use the #cat #command to display or create a new file on #Linux. To save a file, you must first be in Command mode. Press Esc to enter Command mode, and then type :wq to write and quit the file. The other, quicker option is to use the keyboard shortcut ZZ to write and quit.




More Linux Tutorials

We create Linux HowTos and Tutorials for Sys Admins. Visit us on IbmiMedia.com

Also for Tech related tips, Visit forum.outsourcepath.com or General Technical tips on www.outsourcepath.com