If you're trying to figure out if you should file, your credit is probably already damaged. A Chapter 7 filing will stay on your credit report for ten years, while a Chapter 13 will remain there for seven. Any creditors you solicit for debt (a loan, credit card, line of credit, or mortgage) will see the discharge on your report, which will prevent you from getting any credit.
It is important to understand that while bankruptcy is a chance to start over, it definitely affects your credit and future ability to use money. It may prevent or delay foreclosure on a home and repossession of a car and it can also stop wage garnishment and other legal actions creditors use to collect debts, but in the end, there is a price to pay.