There is nothing known as automatic in Indian laws as far as divorce is concerned.
In India, issues relating to family is being governed by the personal laws and divorce is one among them. I will give you an example of living separately as a ground of divorce from Hindu Law.
As per the Hindu Marriage Act if you and your spouse have lived separately for two continuous years then either of them can approach the court seeking divorce on the ground of desertion. His or her application will be entertained and divorce will be granted to him or her accordingly.
Similarly if you and your spouse are living separately from past 18 months and have approached the court for divorce through mutual consent then you can get your divorce done at once as in that case as per the Supreme Court order you can file the first motion and the second motion of divorce at the same time.
But in both the cases you have to come before the court with your application and only then things will move further. It will not be done automatically without approaching the court.