How to check Drupal version from the terminal

First go into your application folder and check the following files:

Drupal 8 & Drupal 9
grep VERSION core/lib/Drupal.php

Drupal 7
grep VERSION includes/bootstrap.inc

Drupal 6 and older
grep VERSION modules/system/system.module
whoami
Stefan Pejcic
Join the discussion

I enjoy constructive responses and professional comments to my posts, and invite anyone to comment or link to my site.