add optional user field to askForPassword()

Open
#37 0 comments 6 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

Assessment

Difficulty
3/5
Estimated time
1-2 days
Newbie friendliness
45/100
Issue type
Feature
Clarity
Mostly clear
Activity status
Stale
Tech stack
r
Domain
api

Research direction

Start by reading the existing askForPassword() and showPrompt() entry points to understand their argument conventions and dialog behavior. Decide which proposed interface fits the API, then verify that an optional username field, its prompt, and its default value behave as described when present and preserve the existing password-only behavior when absent.

Written by the indexing model from the issue text.

Description

It would be really convenient to be able to prompt for both username and password in a single dialog instead of using showPrompt() followed by askForPassword().

Perhaps:

askForPassword(prompt, visiblePrompt=NULL, default=NULL)

where a plain text field is displayed only if !is.null(visiblePrompt) and can optionally be prefilled with default as in showPrompt().

Another approach would be to add a separate function like:

askForUserPassword(userPrompt, passwordPrompt, default=NULL)

which would provide for a more natural ordering to the arguments.

Dominant language
R
Stars
175
Forks
37
PR merge metrics
No merged PRs in 30d

Contributor guide

No contributing guide indexed for this repository

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

More from rstudio/rstudioapi

All issues in rstudio/rstudioapi

Similar issues

More R issues

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.