类似 Heroku 的随机名称生成器。
Generate Heroku-like memorable random names to use in your apps or anywhere else.
Add this line to your application's Gemfile:
gem 'haikunator'And then execute:
$ bundleOr install it yourself as:
$ gem install haikunatorHaikunator is pretty simple. There is nothing to configure and it only has a single method, .haikunate:
Haikunator.haikunate # => "rough-snowflake-1142"
# Token range
Haikunator.haikunate(100) # => "nameless-star-13"
# Don't include the token
Haikunator.haikunate(0) # => "long-flower"
# Use a different delimiter
Haikunator.haikunate(9999, '.') # => "cool.leaf.6743"
# No token, no delimiter
Haikunator.haikunate(0, ' ') # => "green fire"Everyone is encouraged to help improve this project. Here are a few ways you can help:
Haikunator has also been ported to other languages. Though, these projects are not affiliated with or endorsed by me, but check them out:
暂无开放 Issues,或尚未同步最近议题。