I hope you can avoid filing bankruptcy. Let's consider all available options first before you play the ultimate "bankruptcy" card. You do not mention whether you have any other debt such as credit cards with balances or personal loans. That would help me give you a more informed opinion, but I will assume for now that this is your only debt.
You have two goals: avoid bankruptcy and avoid repossession. The credit union appears to be working with you and understands you aren't currently employed. It was a smart move on your part to get in touch with them so quickly, as they are more likely to work with you if you make an effort.
Maybe they will work with you on a payment plan you can afford with your current income. You might only have unemployment income, and the credit union may accept something rather than nothing. You can increase the car payment once you start working again.
You can also look to sell the vehicle and pay off some or all of the balance. But you'll need to get the credit union's consent first. The credit union must agree to accept less than the outstanding balance and still release the title to the car. That usually requires you to agree to pay the difference. That means if you sell the car for $10,000 but owe the credit union $12,000, you'd have to pay $2,000 to the credit union over time.
In the end, you might have no choice and may be forced into bankruptcy. The loan-to-value ratio could be significantly upside-down, and the credit union may not be willing to wait for payments. But I just don't want you to concede that bankruptcy is your first option. Communicate with the credit union, and look for a solution that protects its interest and your credit.