I know as gardeners we sometimes make great discoveries by accident, that solves long standing problems. My discovery came when a large rosemary bush growing in my yard died because of the freezing days this past winter. I cut it down but stopped short of throwing it in the green waste bin. It was very prickly and still had a strong scent. Maybe it could be used as a deterrent to keep my neighbor's cat from using my flower bed as a litter box and before he turned his attention to my raised vegetable garden.
I had already tried two (2) commercial cat repellents that didn't work, couldn't hurt to try my idea. I knew from having cats of my own in the past that they don't like to walk on rough, and or uneven surfaces nor do they like strong scents.
So, I lined my vegetable beds with the dried rosemary branches with fantastic results. The cat has not gone to my garden or used my flower bed as a litter box since. It also works great as mulch.