The Vigilantes, groups of normal law abiding citizens who banded together to dispense "Justice" in the mining camps and areas were there was no "Official" law Depending on the nature of the offense, punishments ranged from beatings to running out of town to hanging.
Actually the miners in the "diggings" set up the first mining rules, not laws, to govern their property rights. Stuff about claim jumping, who could dig, gold bands accross another claim, stuff like that. Look at wikipedia for the following:
mining law gold rush. The first section shows the informal, but effective rules, the miners established for themselves.