added singleton.{h,m} and helpers to git