In the 2 CCs that I’ve been to, yes, you can do that. However, you won’t get an Associates Degree. You get a certificate of achievement.
So if I wanted to be a car mechanic and not worry about any GE classes, I would sign up for the automotive technician program. I would only take automotive classes and not GE. When I finish the program, I get an automotive technician certificate.
But, you might want to talk to a guidance counselor for more specific info.
Your school’s website will list the courses required for the electrician program. Most of the classes will be electrician courses, but you will likely be required to take an English class, a math class, and maybe a class to help with resume writing and job seeking skills.
You will have to discuss this with the specific institution. The policies are not going to be the same everywhere.