When a metal reacts with HCl to release H2 gas it's a single displacement reaction. Copper doesn't displace hydrogen because copper has a higher standard electrode potential than hydrogen. This means that is has a higher potential to be reduced (gain electrons) and is therefore less likely to be oxidized (lose electrons), which is what would need to happen for it to displace hydrogen. For the sake of discussing the reaction, here's what the equation would look like if the reaction did take place:
`2Cu + 2HCl -> 2CuCl + H_2` , E = 0.159 V
`Cu + 2HCl -> CuCl_2 + H_2` , E = 0.337
Both of these reactions have a positive standard reduction potential (E) compared to hydrogen, which is zero volts. In order for a metal to displace hydrogen from HCl it must have a negative standard reduction potential, which means that it needs to be below hydrogen on the activity series. The activity series is the ranking of metals in order of reactivity, which is from highest to lowest tendency to be oxidized and therefore from lowest to highest standard reduction potential. Copper will stay in the reduced form, Cu, rather than losing electrons to go to an oxidized form, Cu+ or Cu2+.