Any literature on the food of the peafowls would indicates that they are omnivorous and eat plants , seeds and insects including small creatures such as reptiles and amphibians.
They are called Mayura in Sanskrit and Hindi language. Mayura means killer of snakes. The available literature indicates that they feed on small snakes and avoid big ones.
As you are aware that the month of Shravan is dedicated to Lord Shiva and it is believed that if you worship with a clear intent and heart Lord Shiva would bless you and fulfill your desired wish.