refactor pdfdeck, add metadata, stdout options