I am currently living in Texas and my work is in Michigan. I will be filing non-resident tax return for michigan state. but how will my capital gains taxed (texas=no tax)

i am currently living in Texas and my work is in Michigan. I will be filing non-resident tax return for michigan state. but how will my capital gains be taxed since texas has no state tax. i have a signiificant amount of earnings from stock sales and i would like to avoid paying Michigan state income tax.