Back in the good old days, radios used crystals to control the frequencies, and sometimes had internal jumpers that were set for the various options. Some time later on, they moved the internal jumpers to a jack on the back of the radio. They configured plugs with wire jumpers in them that plugged into the jack to enable certain options. These became the original code plugs. Later on, more things were controlled by these code plugs, such as tone encode/decode selection.
As radios became microprocessor controlled, the external code plugs moved inside the radio as programming information. The term has, unfortunately, remained with us, although there’s not much that still plugs in. The code plug contains the operating frequencies, tone selections, timeout values, system IDs, etc. In some instances, there’s even some parts of the program itself in the code plug which defines a radio’s personality. These days, the code plug is just a relatively small binary file that’s managed by software a program and transferred to or from the radio via several proprietary means.
Credit to kcbooboo from the batboard @ batlabs.com for the original text.