Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/vinc/regexp_sample
A very limited `Regexp#sample` method
https://github.com/vinc/regexp_sample
Last synced: 14 days ago
JSON representation
A very limited `Regexp#sample` method
- Host: GitHub
- URL: https://github.com/vinc/regexp_sample
- Owner: vinc
- License: mit
- Created: 2014-12-21T19:11:35.000Z (about 10 years ago)
- Default Branch: master
- Last Pushed: 2014-12-21T22:43:38.000Z (about 10 years ago)
- Last Synced: 2024-10-19T23:49:13.148Z (2 months ago)
- Language: Ruby
- Size: 129 KB
- Stars: 1
- Watchers: 3
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
RegexpSample
============A very limited `Regexp#sample` method.
Install
-------$ gem install regexp_sample
Usage
-----```ruby
require "regexp_sample"using RegexpSample
/[a-z0-9]{5}/.sample #=> "nt3r6"
/app[0-9]{5}/.sample(2) #=> ["app94832", "app04535"]
```
Copyright
---------Copyright (C) 2014 Vincent Ollivier. See LICENSE for details.