Next time you happen to spot shredded cheese on sale, buy it up!
We use shredded cheese a lot in this house! What can I say? We like it! So I tend to keep quite a bit on hand. But I was still having the problem of it going bad before I could use it all. Until I learned that you can freeze it.
It is actually very simple! Just throw the bag of cheese, direct from the grocery store, into the freezer. When you want to use it, pull out the flavor/kind that you want, break it up a little and use just like you would if not frozen. If you are going to use the full amount in the bag, then you can allow it to completely thaw in the fridge for a few hours before making dinner. If using from frozen, it will take a little longer to melt. So if you are using it on say a baked potato, you may have to give it a few minutes or throw it in the microwave or warm oven to help it along. I use the frozen cheese in salads I send to work with my husband. By the time he gets his lunch at work, the cheese is thawed! And we never have to deal with moldy cheese again!