examples below
cat /proc/cpuinfo cat /proc/meminfo
But if you want a detailed description of the hardware components, then this is the better way. It also gives the voltage of the CPU, type of RAM, serial number of the mother board, etc. check it yourself.
dmidecode