concode 0.0.1 → 0.1.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- checksums.yaml +4 -4
- data/README.md +25 -5
- data/lib/concode/version.rb +1 -1
- metadata +2 -2
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 740e35769534530831cb4cedff12e007f6521b48ccbcd7a7c077d7bc1f3af61c
|
4
|
+
data.tar.gz: e9dbb01e36eae368f06268c13c8ca4ce9b9fa5b027efa4e94e6c6ef271ab1313
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: f455510cb32750b3d7974c49cbdac62b0d8242ccce09b59740059364dde9a362721f2c0ca1b4a1dd1546785ae5ee5932c39c0a49ff95721270a7a0b183db89cb
|
7
|
+
data.tar.gz: 4026e07fbe685b77177f7860461cfe222c5557f0f900c8c265589aac7fd12c82fa0ffbe4a5c1ed033a03f94b6ea27dfe30233b5f4f9ec25ffd490260564ff6fe
|
data/README.md
CHANGED
@@ -1,6 +1,11 @@
|
|
1
1
|
Concode
|
2
2
|
==================================================
|
3
3
|
|
4
|
+
[](https://badge.fury.io/rb/concode)
|
5
|
+
[](https://travis-ci.com/DannyBen/concode)
|
6
|
+
[](https://codeclimate.com/github/DannyBen/concode/maintainability)
|
7
|
+
[](https://codeclimate.com/github/DannyBen/concode/test_coverage)
|
8
|
+
|
4
9
|
---
|
5
10
|
|
6
11
|
Generate *consistent-codenames* from any string (Heroku style, aka Haiku).
|
@@ -32,16 +37,23 @@ Command Line Usage
|
|
32
37
|
--------------------------------------------------
|
33
38
|
|
34
39
|
```shell
|
35
|
-
$ concode
|
36
|
-
|
40
|
+
$ concode --help
|
41
|
+
|
42
|
+
Usage:
|
43
|
+
concode <string> [options]
|
44
|
+
concode --random [options]
|
45
|
+
concode --count [options]
|
46
|
+
concode (-h|--help|-v|--version)
|
37
47
|
|
38
48
|
Options:
|
39
49
|
-w, --words N Number of words to generate
|
40
50
|
-c, --chars N Max characters per word
|
41
51
|
-g, --glue CHAR Word separator
|
42
52
|
-C, --caps Capitalize words
|
53
|
+
-n, --count Count possible combinations
|
54
|
+
-r, --random Generate a random code
|
43
55
|
-h, --help Show this message
|
44
|
-
|
56
|
+
-v, --version Show version
|
45
57
|
```
|
46
58
|
|
47
59
|
### Examples
|
@@ -55,6 +67,9 @@ ancient-plausible-term
|
|
55
67
|
|
56
68
|
$ concode hello --words 3 --chars 3 --caps --glue ' '
|
57
69
|
Cut Red Bar
|
70
|
+
|
71
|
+
$ concode --random -w4
|
72
|
+
cruel-aggressive-cute-world
|
58
73
|
```
|
59
74
|
|
60
75
|
|
@@ -64,17 +79,22 @@ Library Usage
|
|
64
79
|
```ruby
|
65
80
|
require 'concode'
|
66
81
|
|
67
|
-
#
|
82
|
+
# basic use:
|
68
83
|
|
69
84
|
generator = Concode::Generator.new
|
70
85
|
puts generator.generate 'something annoying'
|
71
86
|
# => annoyed-poem
|
72
87
|
|
73
|
-
#
|
88
|
+
# or, with all the options:
|
74
89
|
|
75
90
|
generator = Concode::Generator.new words: 3, chars: 4, capitalize: true, glue: ' '
|
76
91
|
puts generator.generate 'something annoying'
|
77
92
|
# => Wise Rude Boot
|
93
|
+
|
94
|
+
# get the available combinations with:
|
95
|
+
|
96
|
+
puts generator.word_count
|
97
|
+
# => 7402200
|
78
98
|
```
|
79
99
|
|
80
100
|
|
data/lib/concode/version.rb
CHANGED
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: concode
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.0
|
4
|
+
version: 0.1.0
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Danny Ben Shitrit
|
8
8
|
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date: 2018-06-
|
11
|
+
date: 2018-06-22 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: byebug
|