Want to keep digging mammals out of your garden? Lace small onions or onion seeds (to grow onions) in with the plants you plant. Any mammal that spends its life underground has an acute sense of smell. If you think onion makes you tear up, imagine what it would do if your sense of smell were many times what it currently is.
Another trick, … if you have vole or mole hills showing up in your yard, take a shovel full of dirt out of the hole. Then drop a nice smelly onion that you’ve quartered into the hole and replace the dirt. You just made that area unusable for the critter.
I am told that garlic also works, but haven’t tried garlic myself.