If a fellow Hebrew, man or woman, is sold to you, s/he shall serve you six years, and in the seventh year you shall set him/her free. When you set him/her free, do not let her/him go empty-handed: Furnish her/him out of the flock, threshing floor, and vat, with which Adonai your God has blessed you. Bear in mind that you were slaves in the land of Egypt and Adonai your God redeemed you; therefore I enjoin this commandment upon you today.
But should he say to you, "I do not want to leave you" --for he loves your household and is happy with you -- you shall take an awl and put it through his ear into the door, and he shall become your slave in perpetuity. Do the same with your female slave. When you do set him free, do not feel aggrieved; for in the six years he has given you double the service of a hired slave. Moreover, Adonai your God will bless you in all you do.
edited for gender-neutrality]