This is taken from the FAQ pinned at the top:
Self-diagnostic codes can be obtained from your 91-95 YJ by simply inserting the key into the ignition. Turn the key to the on position (when the lights on the dash come on) then off, on, off, and on. It has been said that you need to go through key cycle in less than 5 seconds.
Now that you have cycled the key on, off, on, off, on, the check engine light will begin to flash. One flash a short pause and two flashes indicates a code 12, three flashes, a short pause, and three flashes indicate a code 33. There will longer pauses between codes when there are multiple fault codes.
If your check engine light will not come on it's fairly common that it's because the bulb is burned out. In that case just remove the guage cluster and replace the CEL bulb with the bulb for the seatbelt reminder.
When you determine what codes are stored in the computer you must disconnect the battery for a minute or so after you have completed the repair so that the code will be erased from the computers memory. If you don't do it the motor will still run badly because the computer will still think there is a problem even though the check engine light is not on.
Here are the codes as listed in Chiltons.
11 No crank reference signal at PCM
12 Battery disconnect
13 No change in MAP from start to run
14 MAP sensor voltage too low or too high
15 No vehicle speed (distance) sensor signal
17 Engine is cold too long (thermostat stuck open)
21 O2S stays at center or O2S shorted to voltage
22 ECT sensor voltage too high or too low (engine coolant temperature sensor is faulty)
23 Intake air temp sensor voltage too low or too high
24 Throttle position sensor voltage too high or too low
25 Idle air control motor circuits
27 Injector control circuit
33 Air conditioning clutch relay circuit
34 Speed control solenoid circuit or switch voltage
41 Generator field not switching properly
42 Auto shutdown relay control circuit
44 Battery temp sensor volts out of limits
46 Charging system voltage too high
47 Charging system voltage too low
51 O2S signal stays below center (lean)
52 O2S signal stays above center (rich)
53 Internal PCM failure or PCM failure SPI communiations
54 No cam sync signal at PCM
55 Completion of diagnostic code display
62 PCM failure SPI miles not stored
63 PCM failure EEPROM write denied