I order a bunch of food from Harmony House. I'm sure there are other places too, this is just the first place I found. I started with their Backpacking kit, and then over time learned which foods I like better than others. Here is what my current supply looks like. My starches:
I combine them into a bowl with 1/3 starches, 1/3 beans, 1/3 veggies. I just pick at random what I want from the 3 categories. When I make several bowls, I'll get variation.
For backpacking I add 150g to each "sandwich" size ziplock bag. Looking at the nutritional info, I learned that most of the foods are between 3-4 calories/g, so I take 3.5 as the average. This gives me plenty of calories for a meal. Actually I get really full eating this. It seems like more than 525 calories. For not-backpacking, I put in 125g per bag. Even that seems like a lot. For backpacking, I will also bring nuts, roasted chickpeas and raisins. For non-backpacking I will usually be able to have fresh fruit and nuts.
I put the small ziplock bags into a large gallon-size bag for more complete sealing. About 6 small bags fit in the bigger bag.
[edited later] Thanks to a commenter for reminding me to describe how I "cook" the food. I add about 3 times as much water as food (I think recommendation is twice), and if I happen to have a stove, I cook it for 5-10 minutes. But usually I don't. I just soak it for 30 minutes- 5 hours. The longer it soaks (or cooks), the better it is in my opinion. On my backpacking trip, I don't even have to bring a stove! (I don't drink coffee so don't need it for that either). I just start soaking my next meal after I finish my current one. I do the same on other kinds of trips. I bought some leak-proof containers to soak the food in.