Skip to content

Add Random::Formatter#phrase#3

Closed
nobu wants to merge 2 commits intoruby:masterfrom
nobu:random-phrase
Closed

Add Random::Formatter#phrase#3
nobu wants to merge 2 commits intoruby:masterfrom
nobu:random-phrase

Conversation

@nobu
Copy link
Copy Markdown
Member

@nobu nobu commented Aug 24, 2021

The method generates a random pass phrase.

@nobu nobu force-pushed the random-phrase branch 2 times, most recently from ca1f77d to 30b7397 Compare December 6, 2021 07:25
nobu and others added 2 commits December 30, 2023 00:02
Co-authored-by: Olle Jonsson <olle.jonsson@gmail.com>
PUNCT = %w[! - + / . ^ ~].freeze

# Default excluded characters for #phrase
EXCLUDE = %w"0 O o 1 l".freeze
Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Minor: Is there a specific style reason to have another %w list delimiter for EXCLUDE than what PUNCT is using?

Copy link
Copy Markdown
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Of course nothing ;)

@nobu
Copy link
Copy Markdown
Member Author

nobu commented Jan 3, 2024

It may be nice if this method accepts chars:, like as Random::Formatter#alphanumeric.

@jjb jjb mentioned this pull request Nov 6, 2024
@hsbt
Copy link
Copy Markdown
Member

hsbt commented Dec 16, 2024

Random::Formatter is removed from securerandom gem. I'll close this.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants