Add script to generate rules from existing .ndproj

Change-Id: Icc0a54eaa7400a2c7effd17e098f0aef817ffd9b