UsefulTNT creates an item, which when used on TNT, will set the TNT off in a way that is more useful to mining.
TNT detonated in this manner always drops items. Additionally, it will not destroy existing items or xp, and will not hurt players. To minimize collateral damage, it also will not chain with other TNT.
Source Code
The source code for UsefulTNT can be found here:GitHub