https://github.com/krthr/costelog-crystal
Get random sentence from Costeño idioms for your log.
https://github.com/krthr/costelog-crystal
costelog crystal crystal-language shard
Last synced: 6 months ago
JSON representation
Get random sentence from Costeño idioms for your log.
- Host: GitHub
- URL: https://github.com/krthr/costelog-crystal
- Owner: krthr
- License: mit
- Archived: true
- Created: 2018-11-27T16:31:56.000Z (almost 7 years ago)
- Default Branch: master
- Last Pushed: 2018-11-28T05:51:14.000Z (almost 7 years ago)
- Last Synced: 2025-04-14T00:58:05.627Z (6 months ago)
- Topics: costelog, crystal, crystal-language, shard
- Language: Crystal
- Homepage:
- Size: 8.79 KB
- Stars: 2
- Watchers: 2
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
# costelog-crystal



[](http://opensource.org/licenses/MIT)This is the **Crystal** version of [gmoralesc's costelog](https://github.com/gmoralesc/costelog)
## Installation
- Add the dependency to your `shard.yml`:
```yaml
dependencies:
costelog-crystal:
github: krthr/costelog-crystal
```- Run `shards install`
## Usage
```crystal
require "costelog-crystal"# Get just one phrase
puts Costelog.random_phrase # => "Puya el burro"
puts Costelog.random_phrase "Wilson" # => "Va pa' esa Wilson"# Get all the phrases
puts Costelog.all # => ["Que vaina e buena", "Ya te dije cuadro", "Va pa' esa cuadro", "cuadro Que vaina linda", ...]
puts Costelog.all "Wilson" # => ["Que vaina e buena", "Ya te dije Wilson", "Va pa' esa Wilson", "Wilson Que vaina linda", ...]
```The _name_ param is optional. If you dont pass any name, the library will select a random valid name.
## TODO
TODO: Write specs
## Contributing
1. Fork it ()
2. Create your feature branch (`git checkout -b my-new-feature`)
3. Commit your changes (`git commit -am 'Add some feature'`)
4. Push to the branch (`git push origin my-new-feature`)
5. Create a new Pull Request## Contributors
- The original library was created by [Gustavo Morales](https://twitter.com/gmoralesc)
- [krthr](https://github.com/krthr) - creator and maintainer