We established in the last post that distance is your friend and if your assailant closes that distant, you will have to use hand to hand techniques to prevent grave injury or death.
Not many of us are trained in close quarter combatives. In the ideal world you would supplement your gun skills with a good street level self-defense program. My pick would be Krav Maga for street level fighting techniques.
Here is one that you can practice with a training handgun (not a real one). Get a friend and try to perfect this technique.