The one sin that underlies all other sins is indifference to suffering. God and Jesus both pound home on this. If you don't care if other people suffer then you're fully capable of justifying racism, rape, robbery, and murder. If you do care, then you will refrain from harming others because you wouldn't want to be harmed yourself, and you will act charitably because you would like charity extended to you when you need it. Specific acts are not in and of themselves selfish. On May 23, 1939 Electrician’s Mate Third Class Lloyd Maness slammed a steel hatch shut aboard the USS Squalus, locking 26 crewmen in the flooding after section of the sub and drowning them.
Maness did this to save the 33 men in the forward section of the sub, since waiting even a few seconds would have allowed the rushing wall of water to push open the hatch and flood the rest of the sub.
Now, that sailor killed those 26 men just as surely as if he had shoved their heads into a bucket of water and held them down until they drowned. But did he sin? If he hadn't locked them in, the entire crew would have perished. Maness was not indifferent to suffering; rather, he instantly knew from his experience as a submariner that those men in the aft section of the sub were already doomed, but there was a chance to save the rest of the crew (and they were; click on the story, it's pretty amazing).
Now, if we stick by hard and fast rules such as Moses' Old Testament purity laws, we end up in situations where suffering is magnified because it would be a sin to intercede (Jesus cites example after example after example of the Pharisees doing this). But if we stick to Jesus' principles then there is freedom and leeway in our actions; we may do a thing under one set of circumstances that would be wrong under another so long as the motivation is one of love, charity, and a desire to prevent unjust suffering.
This orbits us back to the issue of slavery, and the horrid racism it fostered. Slave owners didn't want to lose their "property" and their free labor, so they ignored Jesus' principle treat others the way you want to be treated and found willing stooges to promote a heretofore justifiably discarded inaccurate literal interpretation of the Bible.
They focused on the rules, as it were, instead of the reason.
Because of this, and because they deliberately fed into a pre-existing stream of willful ignorance embraced by the poor southern whites, the woefully inaccurate, grossly distorted, and factually wrong teaching of Biblical literalism took root and spread.
Case in point: Human beings refer to the covenant offered on Mt Sinai as "the Ten Commandments" when God never referred to them as such either by number or by that definition. God offered a contract that the Israelites were free to accept or refuse. If they wanted God to be their God they would do certain thing; if they didn't want to do those things then God would have let them go off on their own.
The term we humans translate as "commandments" is the result of translators working for an established king or government translating the term to impart maximum authority...which the king or government would then claim to share. The proper Jewish term is translated into Greek as the Decalogue, and means literally "the Ten Words".
Not commandments, words.
Yes, Jesus referred to them as laws and commandments but again remember, he was talking to people already steeped in about 1,600 years of a particular tradition; they understood the covenant to mean something it didn't, but there was no point trying to straighten that out at the time, it was just too culturally ingrained.*
So trying to figure out precisely what was said or meant is a problematic task, but taking the longer view of God's principles as voiced in Jesus' teachings, we see it's basically very simple and no complicated at all: Love God, love your neighbor, everything else is commentary.
* And further, Jesus spoke in Aramaic, which was translated and written down in Greek, and then further translated into Latin and other languages, all of which went through meaning and culture shifts over time.