Added output option. Update usage.