You were writing all the code for automation.
Only a minority of dev jobs are automating people out of work. There are entirely new industries like game dev that can't exist without it.
Software development has gained such a political whipping-boy status, you'd be forgiven for forgetting it's been the route to the middle classes for a lot of people who would otherwise be too common, weird or foreign.