Check duplicate pull request and use GLI for command parsing

All conflicts are resolved. Should be able to merge automatically now.