Conduit or armored cable?
These colors are a bit disturbing. One wire looks positively greenish. The cable entry at the top of your box could either be conduit such as EMT, or it could be an armored cable clamp. Armored cable forces you into 1 color choice: black-white-green, and that one wire looks kinda green. It might be blue or gray.
Green wires can only be used for grounds. Grounds must be green, green/yellow, or bare and nothing else can use those colors.
So we need to test for conduit vs. armored cable.
- Firmly grab the black wire and hold it so it cannot move.
- Grab the white wire and push it up 1/4 inch, then pull it back down 1/4 inch.
If the white wire moves easily, you are in conduit. If the white wire fights, binds and wants to buckle, then you are in armored cable.
That means the wire is green which makes this a real botch job. You're not allowed to use a green wire for anything but a ground. THat wire must be re-tasked to be a ground. Since you have both ends opened up, remove the red tape from both ends of the green. What were they thinking?
Now fix the grounds properly. Back of the box is a little hole on a dimple. That's tapped 10-32. They make cute little green ground screws that are 10-32, even. Regardless, you ground the boxes (here and in the ceiling) by putting a 10-32 screw in 'em and pigtail off those with 9" long sections of SOLID wire.
Good news is, since this is cable, it is legal to re-mark a white wire to be a hot. They've even used the preferred color for switched-hot! So with the grounds fixed, you are all set to use the black and "red" wires to go to the switch. You can leave it on the existing switch, but if you do that, you'll have a dead switch. I recommend just get a single switch, they are $2.
It looks like THHN wire, which is what you use in conduit. In that case, that strange wire could actually be blue.
However, in conduit, it is illegal to re-mark neutrals to be hots. First thing you do, tear off that red tape off the white wire on both ends, that does not belong there. Unfortunately we often see electricians who spend their whole career working in Romex, they do a little work in conduit and just use the same color codes - e.g. black and white in a switch loop. Not allowed!
Gray is also a color reserved for neutral. If that odd wire is gray, you need to do the same thing - remove the tape on both ends, it doesn't belong there. And that actually works in your favor - making this wire an actual neutral will help this box support smart switches.
But neutral is not required (unless your switch needs it). There's a rule that switch loops must have neutral, but conduit is exempt because it's so easy to add another wire.
If the odd wire is green, then it can only be a ground. Do the same thing I said under AC. However if the conduit is metal conduit, the ground wire is actually redundant.
Now if this leaves you a black and blue-taped-red wire, you're all set. Those two wires go to the switch and the blue-red wire goes to your lamp. Easy.
However, if the above restrictions leave you with only a black - you will need to "pull" an additional wire for switched-hot. The allowed colors are black brown red orange yellow pink blue or violet. You need THWN-2 wire the same size as the other wires. So rough-guess your distance, and off to the electrical supply house to buy that.
Some wires may be expendable/useless, which may help pulling another wire. How to pull is beyond the scope of this answer, but there are plenty of answers here about it.