One must assume that trapped miners, or anyone else in a similar situation--say shipwrecked sailors--are acting under the assumption that their situation, no matter how dire, is temporary. Any rules, or codes of conduct are only for the time when they await rescue, no further. The exigencies of survival would of necessity preclude them from adopting an entire new system of laws, as the above answer suggests; as it is highly doubtful that they could soberly and reflectively form a new government. Such a response might be appropriate if one were marooned on a distant island with no hope for immediate rescue. Although trapped miners are in dire straits, their situation should not be such that they revert back to a "state of nature," with all its pitfalls.
A more proper answer, I think, is that the trapped miners must consider themselves bound by the same code of conduct which they would observe without the emergency. Those in charge are still in charge. Acts which are criminal above ground are criminal below ground; although punishment of any such offenses must wait until rescue.
There is precedent for this situation in the case of The Queen vs. Dudley and Stephens(1884) in which three British sailors were shipwrecked; and in order to survive, the sailors drew lots to determine which one should be killed and eaten by the other two. Dudley and Stephens, the survivors, were tried and convicted of murder. The court determined that the exegencies of the moment did not relieve them of liability under the law:
It is not suggested that in this particular case the deeds were devilish, but it is quite plain that such a principle once admitted might be made the legal cloak for unbridled passion and atrocious crime. There is no safe path for judges to tread but to ascertain the law to the best of their ability and to declare it according to their judgment; and if in any case the law appears to be too severe on individuals, to leave it to the Sovereign to exercise that prerogative of mercy which the Constitution has intrusted to the hands fittest to dispense it.
It must not be supposed that in refusing to admit temptation to be an excuse for crime it is forgotten how terrible the temptation was; how awful the suffering; how hard in such trials to keep the judgment straight and the conduct pure. We are often compelled to set up standards we cannot reach ourselves, and to lay down rules which we could not ourselves satisfy. But a man has no right to declare temptation to be an excuse, though he might himself have yielded to it, nor allow compassion for the criminal to change or weaken in any manner the legal definition of the crime. It is therefore our duty to declare that the prisoners' act in this case was wilful murder, that the facts as stated in the verdict are no legal justification of the homicide; and to say that in our unanimous opinion the prisoners are upon this special verdict guilty, of murder.
This situation would be somewhat like a state of nature in which there would be no legitimate authority to tell the miners what to do and to enforce laws. Therefore, they would have to set up their own society. Of course, they would already have ideas from their society so it would not be exactly like a state of nature.
A guiding principle might be equality. It might be that every person stuck in the mine should be able to share equally in whatever resources they have. This would include food, of course, but it might also include time in any light source they have. It might include the idea that all have to share equally in whatever tasks they need to do in order to survive and be as healthy as possible.
In a criminal code, crimes would largely be offenses against this principle of equality. The major problem with a criminal code would be the need to figure out a way to punish any wrongdoing. It would presumably have to be in the form of "fines" with the offender losing all or part of his share of resources.
A major problem this "society" would face in trying to enforce these laws would be the possibility of factions arising among the miners. These might try to cheat on behalf of their members and prevent the system from working as it is supposed to.
"My stomach was full as it could be, and nobody ever got around to finding Timothy".
As stated, there is always a chance of rescue, therefore, no new Civilization need be incorporated by men and no laws need be drafted as when the Mayflower Compact was introduced into American Jurisprudence, a young new community in a new land, if you grasp the comparison.
There was an episode of the series Combat I remember, they somehow got trapped in a mine shaft, and one American soldier wanted kill the German prisoner, to have more food and air for the others.
Sgt. Saunders said, no, and when the soldier asked why, they would kill him above ground, Saunder's replied "I said Kill, not murder".
Laws of Man and God are not suspended when human tragedy unfolds.