sonic_pass 0.2.0 → 0.2.1
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 +56 -20
- data/lib/sonic_pass/version.rb +1 -1
- metadata +1 -1
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 03e4a2e45c294c05b0f9a731d4b1ea486a682b48ccf88bee3704bd173852980c
|
4
|
+
data.tar.gz: a584318ca8872d323452cdb483951aa6476fb29b9ddfd15290855fe69ea2763d
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 4dacbdd5965f0ff8c1058910094392eb38a021c8d52b8da3aed02f24fba1c149628c70314650f31d762e20587df71373a80ce65f3b12751499b8b3d74c8fd2ee
|
7
|
+
data.tar.gz: 399abfa3c530b420ad42823c6a7ac5a3460c371fe147a441062465333b9816e9013ef294671efa899b52a65fb5f537f46d5a7c9fb05ec9fccc1929a5f68c4927
|
data/README.md
CHANGED
@@ -1,39 +1,75 @@
|
|
1
|
-
|
1
|
+
Table of Contents
|
2
|
+
-----------------
|
2
3
|
|
3
|
-
|
4
|
+
* [Overview](#overview)
|
5
|
+
* [Installation](#installation)
|
6
|
+
* [Usage](#usage)
|
7
|
+
* [Configuration](#configuration)
|
8
|
+
* [Methods](#methods)
|
9
|
+
* [Contributing](#contributing)
|
10
|
+
* [License](#license)
|
4
11
|
|
5
|
-
|
12
|
+
### Overview
|
6
13
|
|
7
|
-
|
14
|
+
Sonic Pass is a Ruby gem designed to generate strong, unique passwords. It provides a simple and efficient way to create passwords of varying lengths, making it an ideal tool for developers and users alike.
|
8
15
|
|
9
|
-
|
16
|
+
### Installation
|
10
17
|
|
11
|
-
|
18
|
+
To install the Sonic Pass gem, run the following command in your terminal:
|
12
19
|
|
13
|
-
|
20
|
+
```bash
|
21
|
+
gem install sonic_pass
|
22
|
+
```
|
14
23
|
|
15
|
-
|
24
|
+
Alternatively, you can add the following line to your Gemfile:
|
16
25
|
|
17
|
-
|
26
|
+
```ruby
|
27
|
+
gem 'sonic_pass'
|
28
|
+
```
|
18
29
|
|
19
|
-
|
30
|
+
Then, run `bundle install` to install the gem.
|
20
31
|
|
21
|
-
|
32
|
+
### Usage
|
22
33
|
|
23
|
-
|
34
|
+
To use the Sonic Pass gem, simply require it in your Ruby file:
|
24
35
|
|
25
|
-
|
36
|
+
```ruby
|
37
|
+
require 'sonic_pass'
|
38
|
+
```
|
26
39
|
|
27
|
-
|
40
|
+
You can then generate a password using the `SonicPass.generate` method:
|
28
41
|
|
29
|
-
|
42
|
+
```ruby
|
43
|
+
password = SonicPass.generate(length: 12)
|
44
|
+
puts password
|
45
|
+
```
|
30
46
|
|
31
|
-
|
47
|
+
This will output a strong password of the specified length.
|
32
48
|
|
33
|
-
|
49
|
+
### Configuration
|
34
50
|
|
35
|
-
The gem
|
51
|
+
The Sonic Pass gem can be configured to use different character sets for password generation. The available character sets are:
|
36
52
|
|
37
|
-
|
53
|
+
* `ALPHANUMERIC_CHARSETS`: A combination of uppercase letters, lowercase letters, and digits.
|
54
|
+
* `SPECIAL_CHARSETS`: A set of special characters.
|
38
55
|
|
39
|
-
|
56
|
+
You can specify the character set to use when generating a password:
|
57
|
+
|
58
|
+
```ruby
|
59
|
+
password = SonicPass.generate(length: 12, charset: SonicPass::ALPHANUMERIC_CHARSETS)
|
60
|
+
puts password
|
61
|
+
```
|
62
|
+
|
63
|
+
### Methods
|
64
|
+
|
65
|
+
The Sonic Pass gem provides the following methods:
|
66
|
+
|
67
|
+
* `SonicPass.generate(length: 12, charset: SonicPass::ALPHANUMERIC_CHARSETS)`: Generates a strong password of the specified length using the specified character set.
|
68
|
+
|
69
|
+
### Contributing
|
70
|
+
|
71
|
+
Contributions to the Sonic Pass gem are welcome. To contribute, please fork the repository and submit a pull request with your changes.
|
72
|
+
|
73
|
+
### License
|
74
|
+
|
75
|
+
The Sonic Pass gem is released under the MIT License. See the LICENSE file for details.
|
data/lib/sonic_pass/version.rb
CHANGED