naughty_words 0.1.1

Sign up to get free protection for your applications and to get access to all the features.
checksums.yaml ADDED
@@ -0,0 +1,7 @@
1
+ ---
2
+ SHA256:
3
+ metadata.gz: d85fccb7a94fab7fb39c18575bd3489c31ff0da5d0bfba585df0dda4fd49f560
4
+ data.tar.gz: f2bbf7546a3e1c7ae53657060b39ef80cc4ec1a7eccae82cd74450f2dc6c7bd4
5
+ SHA512:
6
+ metadata.gz: a5cefb81ba419a3868697f08660b4931bda9ad09d68d609aa85adb40aeb4c286e96747cb30f5f7f289529da2009611e74db53bbf351609398b456630a44594bc
7
+ data.tar.gz: 15b967ffd773daa055b5af6bb0395681b4a9669b9df9f642bb2f36871c6a218dd15b48ef15568c415ee4d03e52d2febaec1d8b2f8ed107bc053e00db5509991f
data/.rspec ADDED
@@ -0,0 +1,3 @@
1
+ --format documentation
2
+ --color
3
+ --require spec_helper
data/.rubocop.yml ADDED
@@ -0,0 +1,17 @@
1
+ AllCops:
2
+ TargetRubyVersion: 2.6
3
+
4
+ Style/StringLiterals:
5
+ Enabled: true
6
+ EnforcedStyle: double_quotes
7
+
8
+ Style/StringLiteralsInInterpolation:
9
+ Enabled: true
10
+ EnforcedStyle: double_quotes
11
+
12
+ Layout/LineLength:
13
+ Max: 120
14
+
15
+ Style/Documentation:
16
+ Description: 'Document classes and non-namespace modules.'
17
+ Enabled: false
data/CHANGELOG.md ADDED
@@ -0,0 +1,5 @@
1
+ ## [Unreleased]
2
+
3
+ ## [0.1.0] - 2022-05-18
4
+
5
+ - Initial release
@@ -0,0 +1,84 @@
1
+ # Contributor Covenant Code of Conduct
2
+
3
+ ## Our Pledge
4
+
5
+ We as members, contributors, and leaders pledge to make participation in our community a harassment-free experience for everyone, regardless of age, body size, visible or invisible disability, ethnicity, sex characteristics, gender identity and expression, level of experience, education, socio-economic status, nationality, personal appearance, race, religion, or sexual identity and orientation.
6
+
7
+ We pledge to act and interact in ways that contribute to an open, welcoming, diverse, inclusive, and healthy community.
8
+
9
+ ## Our Standards
10
+
11
+ Examples of behavior that contributes to a positive environment for our community include:
12
+
13
+ * Demonstrating empathy and kindness toward other people
14
+ * Being respectful of differing opinions, viewpoints, and experiences
15
+ * Giving and gracefully accepting constructive feedback
16
+ * Accepting responsibility and apologizing to those affected by our mistakes, and learning from the experience
17
+ * Focusing on what is best not just for us as individuals, but for the overall community
18
+
19
+ Examples of unacceptable behavior include:
20
+
21
+ * The use of sexualized language or imagery, and sexual attention or
22
+ advances of any kind
23
+ * Trolling, insulting or derogatory comments, and personal or political attacks
24
+ * Public or private harassment
25
+ * Publishing others' private information, such as a physical or email
26
+ address, without their explicit permission
27
+ * Other conduct which could reasonably be considered inappropriate in a
28
+ professional setting
29
+
30
+ ## Enforcement Responsibilities
31
+
32
+ Community leaders are responsible for clarifying and enforcing our standards of acceptable behavior and will take appropriate and fair corrective action in response to any behavior that they deem inappropriate, threatening, offensive, or harmful.
33
+
34
+ Community leaders have the right and responsibility to remove, edit, or reject comments, commits, code, wiki edits, issues, and other contributions that are not aligned to this Code of Conduct, and will communicate reasons for moderation decisions when appropriate.
35
+
36
+ ## Scope
37
+
38
+ This Code of Conduct applies within all community spaces, and also applies when an individual is officially representing the community in public spaces. Examples of representing our community include using an official e-mail address, posting via an official social media account, or acting as an appointed representative at an online or offline event.
39
+
40
+ ## Enforcement
41
+
42
+ Instances of abusive, harassing, or otherwise unacceptable behavior may be reported to the community leaders responsible for enforcement at johnadamarnold@gmail.com. All complaints will be reviewed and investigated promptly and fairly.
43
+
44
+ All community leaders are obligated to respect the privacy and security of the reporter of any incident.
45
+
46
+ ## Enforcement Guidelines
47
+
48
+ Community leaders will follow these Community Impact Guidelines in determining the consequences for any action they deem in violation of this Code of Conduct:
49
+
50
+ ### 1. Correction
51
+
52
+ **Community Impact**: Use of inappropriate language or other behavior deemed unprofessional or unwelcome in the community.
53
+
54
+ **Consequence**: A private, written warning from community leaders, providing clarity around the nature of the violation and an explanation of why the behavior was inappropriate. A public apology may be requested.
55
+
56
+ ### 2. Warning
57
+
58
+ **Community Impact**: A violation through a single incident or series of actions.
59
+
60
+ **Consequence**: A warning with consequences for continued behavior. No interaction with the people involved, including unsolicited interaction with those enforcing the Code of Conduct, for a specified period of time. This includes avoiding interactions in community spaces as well as external channels like social media. Violating these terms may lead to a temporary or permanent ban.
61
+
62
+ ### 3. Temporary Ban
63
+
64
+ **Community Impact**: A serious violation of community standards, including sustained inappropriate behavior.
65
+
66
+ **Consequence**: A temporary ban from any sort of interaction or public communication with the community for a specified period of time. No public or private interaction with the people involved, including unsolicited interaction with those enforcing the Code of Conduct, is allowed during this period. Violating these terms may lead to a permanent ban.
67
+
68
+ ### 4. Permanent Ban
69
+
70
+ **Community Impact**: Demonstrating a pattern of violation of community standards, including sustained inappropriate behavior, harassment of an individual, or aggression toward or disparagement of classes of individuals.
71
+
72
+ **Consequence**: A permanent ban from any sort of public interaction within the community.
73
+
74
+ ## Attribution
75
+
76
+ This Code of Conduct is adapted from the [Contributor Covenant][homepage], version 2.0,
77
+ available at https://www.contributor-covenant.org/version/2/0/code_of_conduct.html.
78
+
79
+ Community Impact Guidelines were inspired by [Mozilla's code of conduct enforcement ladder](https://github.com/mozilla/diversity).
80
+
81
+ [homepage]: https://www.contributor-covenant.org
82
+
83
+ For answers to common questions about this code of conduct, see the FAQ at
84
+ https://www.contributor-covenant.org/faq. Translations are available at https://www.contributor-covenant.org/translations.
data/Gemfile ADDED
@@ -0,0 +1,14 @@
1
+ # frozen_string_literal: true
2
+
3
+ source "https://rubygems.org"
4
+
5
+ # Specify your gem's dependencies in naughty_words.gemspec
6
+ gemspec
7
+
8
+ gem "rake", "~> 13.0"
9
+
10
+ gem "rspec", "~> 3.0"
11
+
12
+ gem "rubocop", "~> 1.21"
13
+
14
+ gem 'pry', '~> 0.13.1'
data/Gemfile.lock ADDED
@@ -0,0 +1,61 @@
1
+ PATH
2
+ remote: .
3
+ specs:
4
+ naughty_words (0.1.0)
5
+
6
+ GEM
7
+ remote: https://rubygems.org/
8
+ specs:
9
+ ast (2.4.2)
10
+ coderay (1.1.3)
11
+ diff-lcs (1.5.0)
12
+ method_source (1.0.0)
13
+ parallel (1.22.1)
14
+ parser (3.1.2.0)
15
+ ast (~> 2.4.1)
16
+ pry (0.13.1)
17
+ coderay (~> 1.1)
18
+ method_source (~> 1.0)
19
+ rainbow (3.1.1)
20
+ rake (13.0.6)
21
+ regexp_parser (2.4.0)
22
+ rexml (3.2.5)
23
+ rspec (3.11.0)
24
+ rspec-core (~> 3.11.0)
25
+ rspec-expectations (~> 3.11.0)
26
+ rspec-mocks (~> 3.11.0)
27
+ rspec-core (3.11.0)
28
+ rspec-support (~> 3.11.0)
29
+ rspec-expectations (3.11.0)
30
+ diff-lcs (>= 1.2.0, < 2.0)
31
+ rspec-support (~> 3.11.0)
32
+ rspec-mocks (3.11.1)
33
+ diff-lcs (>= 1.2.0, < 2.0)
34
+ rspec-support (~> 3.11.0)
35
+ rspec-support (3.11.0)
36
+ rubocop (1.29.1)
37
+ parallel (~> 1.10)
38
+ parser (>= 3.1.0.0)
39
+ rainbow (>= 2.2.2, < 4.0)
40
+ regexp_parser (>= 1.8, < 3.0)
41
+ rexml (>= 3.2.5, < 4.0)
42
+ rubocop-ast (>= 1.17.0, < 2.0)
43
+ ruby-progressbar (~> 1.7)
44
+ unicode-display_width (>= 1.4.0, < 3.0)
45
+ rubocop-ast (1.18.0)
46
+ parser (>= 3.1.1.0)
47
+ ruby-progressbar (1.11.0)
48
+ unicode-display_width (2.1.0)
49
+
50
+ PLATFORMS
51
+ arm64-darwin-21
52
+
53
+ DEPENDENCIES
54
+ naughty_words!
55
+ pry (~> 0.13.1)
56
+ rake (~> 13.0)
57
+ rspec (~> 3.0)
58
+ rubocop (~> 1.21)
59
+
60
+ BUNDLED WITH
61
+ 2.2.30
data/LICENSE.txt ADDED
@@ -0,0 +1,21 @@
1
+ The MIT License (MIT)
2
+
3
+ Copyright (c) 2022 John Arnold
4
+
5
+ Permission is hereby granted, free of charge, to any person obtaining a copy
6
+ of this software and associated documentation files (the "Software"), to deal
7
+ in the Software without restriction, including without limitation the rights
8
+ to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
9
+ copies of the Software, and to permit persons to whom the Software is
10
+ furnished to do so, subject to the following conditions:
11
+
12
+ The above copyright notice and this permission notice shall be included in
13
+ all copies or substantial portions of the Software.
14
+
15
+ THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
16
+ IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
17
+ FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
18
+ AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
19
+ LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
20
+ OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
21
+ THE SOFTWARE.
data/README.md ADDED
@@ -0,0 +1,68 @@
1
+ # NaughtyWords
2
+
3
+ A super basic gem to check if a string has profanites.
4
+
5
+ ## Installation
6
+
7
+ Add this line to your application's Gemfile:
8
+
9
+ ```ruby
10
+ gem 'naughty_words'
11
+ ```
12
+
13
+ And then execute:
14
+
15
+ $ bundle install
16
+
17
+ Or install it yourself as:
18
+
19
+ $ gem install naughty_words
20
+
21
+ ## Usage
22
+
23
+ **Check if a string includes a profanity**
24
+ The `check` method takes in a `string:` argument and will return a boolean.
25
+ ```ruby
26
+ NaughtyWords.check(string: "ass")
27
+ => true
28
+
29
+ NaughtyWords.check(string: "hello world")
30
+ => false
31
+
32
+ NaughtyWords.check(string: "hello asshole")
33
+ => true
34
+ ```
35
+
36
+ **Filter out words**
37
+ The `filter` method takes a `string:` argument and an optional `replacement:` argument.
38
+
39
+ ``` ruby
40
+ # passing a string with no profanity will return the string
41
+ NaughtyWords.filter(string: "hello world")
42
+ => "hello world"
43
+
44
+ # passing a string with profanities will return the string with the profanity filtered out
45
+ NaughtyWords.filter(string: "hello asshole")
46
+ => "hello *******"
47
+
48
+ # you can use in your own filter character by passing it in as an argument ("*" is by default)
49
+ NaughtyWords.filter(string: "hello asshole", replacement: "!")
50
+ => "hello !!!!!!!"
51
+ ```
52
+ Note: Current, this is comically easy to circumvent. String like "shitshitshit" will only filter out the first match, returning "*****shitshit". A fix is enroute.
53
+
54
+ ## Development
55
+
56
+ After checking out the repo, run `bin/setup` to install dependencies. Then, run `rake spec` to run the tests. You can also run `bin/console` for an interactive prompt that will allow you to experiment.
57
+
58
+ ## Contributing
59
+
60
+ Bug reports and pull requests are welcome on GitHub at https://github.com/jaarnie/naughty_words. This project is intended to be a safe, welcoming space for collaboration, and contributors are expected to adhere to the [code of conduct](https://github.com/jaarnie/naughty_words/blob/master/CODE_OF_CONDUCT.md).
61
+
62
+ ## License
63
+
64
+ The gem is available as open source under the terms of the [MIT License](https://opensource.org/licenses/MIT).
65
+
66
+ ## Code of Conduct
67
+
68
+ Everyone interacting in the NaughtyWords project's codebases, issue trackers, chat rooms and mailing lists is expected to follow the [code of conduct](https://github.com/[USERNAME]/naughty_words/blob/master/CODE_OF_CONDUCT.md).
data/Rakefile ADDED
@@ -0,0 +1,12 @@
1
+ # frozen_string_literal: true
2
+
3
+ require "bundler/gem_tasks"
4
+ require "rspec/core/rake_task"
5
+
6
+ RSpec::Core::RakeTask.new(:spec)
7
+
8
+ require "rubocop/rake_task"
9
+
10
+ RuboCop::RakeTask.new
11
+
12
+ task default: %i[spec rubocop]
data/bin/console ADDED
@@ -0,0 +1,15 @@
1
+ #!/usr/bin/env ruby
2
+ # frozen_string_literal: true
3
+
4
+ require "bundler/setup"
5
+ require "naughty_words"
6
+
7
+ # You can add fixtures and/or initialization code here to make experimenting
8
+ # with your gem easier. You can also use a different console, if you like.
9
+
10
+ # (If you use this, don't forget to add pry to your Gemfile!)
11
+ # require "pry"
12
+ # Pry.start
13
+
14
+ require "irb"
15
+ IRB.start(__FILE__)
data/bin/setup ADDED
@@ -0,0 +1,8 @@
1
+ #!/usr/bin/env bash
2
+ set -euo pipefail
3
+ IFS=$'\n\t'
4
+ set -vx
5
+
6
+ bundle install
7
+
8
+ # Do any other automated setup that you need to do here
@@ -0,0 +1,34 @@
1
+ # frozen_string_literal: true
2
+
3
+ module NaughtyWords
4
+ class Base
5
+ class << self
6
+ def profanity?(string:)
7
+ blacklist_file.each do |line|
8
+ return true if string.include?(line.chomp)
9
+ end
10
+
11
+ false
12
+ end
13
+
14
+ def filter(string:, replacement:)
15
+ # TODO: Fix filtering full words ending with 'ing' and repeated words such as 'fuckfuckfuck'
16
+ blacklist_file.each do |line|
17
+ word = line.chomp
18
+ string.gsub!(word, replacement * word.length)
19
+ end
20
+
21
+ string
22
+ end
23
+
24
+ private
25
+
26
+ def blacklist_file
27
+ txt_file = File.join(File.dirname(File.expand_path(__FILE__)), "config/en.txt")
28
+ file = File.open(txt_file)
29
+
30
+ @blacklist_file ||= file.readlines
31
+ end
32
+ end
33
+ end
34
+ end
@@ -0,0 +1,407 @@
1
+ 2g1c
2
+ 2 girls 1 cup
3
+ acrotomophilia
4
+ alabama hot pocket
5
+ alaskan pipeline
6
+ anal
7
+ anilingus
8
+ anus
9
+ apeshit
10
+ arsehole
11
+ asshole
12
+ assmunch
13
+ ass
14
+ auto erotic
15
+ autoerotic
16
+ babeland
17
+ baby batter
18
+ baby juice
19
+ ball gag
20
+ ball gravy
21
+ ball kicking
22
+ ball licking
23
+ ball sack
24
+ ball sucking
25
+ ball bag
26
+ ballbag
27
+ bangbros
28
+ bangbus
29
+ bareback
30
+ barely legal
31
+ barenaked
32
+ bastard
33
+ bastardo
34
+ bastinado
35
+ bbw
36
+ bdsm
37
+ beaner
38
+ beaners
39
+ beaver cleaver
40
+ beaver lips
41
+ beastiality
42
+ bestiality
43
+ big black
44
+ big breasts
45
+ big knockers
46
+ big tits
47
+ bimbos
48
+ birdlock
49
+ bitch
50
+ bitches
51
+ black cock
52
+ blonde action
53
+ blonde on blonde action
54
+ blowjob
55
+ blow job
56
+ blow your load
57
+ blue waffle
58
+ blumpkin
59
+ bollocks
60
+ bondage
61
+ boner
62
+ boob
63
+ boobs
64
+ booty call
65
+ brown showers
66
+ brunette action
67
+ bukkake
68
+ bulldyke
69
+ bullet vibe
70
+ bullshit
71
+ bung hole
72
+ bunghole
73
+ busty
74
+ butt
75
+ buttcheeks
76
+ butthole
77
+ camel toe
78
+ camgirl
79
+ camslut
80
+ camwhore
81
+ carpet muncher
82
+ carpetmuncher
83
+ chocolate rosebuds
84
+ cialis
85
+ circlejerk
86
+ cleveland steamer
87
+ clit
88
+ clitoris
89
+ clover clamps
90
+ clusterfuck
91
+ cock
92
+ cocks
93
+ coprolagnia
94
+ coprophilia
95
+ cornhole
96
+ coon
97
+ coons
98
+ creampie
99
+ cum
100
+ cumming
101
+ cumshot
102
+ cumshots
103
+ cunnilingus
104
+ cunting
105
+ cunt
106
+ darkie
107
+ date rape
108
+ daterape
109
+ deep throat
110
+ deepthroat
111
+ dendrophilia
112
+ dick
113
+ dildo
114
+ dingleberry
115
+ dingleberries
116
+ dirty pillows
117
+ dirty sanchez
118
+ doggie style
119
+ doggiestyle
120
+ doggy style
121
+ doggystyle
122
+ dog style
123
+ dolcett
124
+ domination
125
+ dominatrix
126
+ dommes
127
+ donkey punch
128
+ double dong
129
+ double penetration
130
+ dp action
131
+ dry hump
132
+ dvda
133
+ eat my ass
134
+ ecchi
135
+ ejaculation
136
+ erotic
137
+ erotism
138
+ escort
139
+ eunuch
140
+ fag
141
+ faggot
142
+ fecal
143
+ felch
144
+ fellatio
145
+ feltch
146
+ female squirting
147
+ femdom
148
+ figging
149
+ fingerbang
150
+ fingering
151
+ fisting
152
+ foot fetish
153
+ footjob
154
+ frotting
155
+ fucking
156
+ fuck buttons
157
+ fuckin
158
+ fucktards
159
+ fuck
160
+ fudge packer
161
+ fudgepacker
162
+ futanari
163
+ gangbang
164
+ gang bang
165
+ gay sex
166
+ genitals
167
+ giant cock
168
+ girl on
169
+ girl on top
170
+ girls gone wild
171
+ goatcx
172
+ goatse
173
+ god damn
174
+ gokkun
175
+ golden shower
176
+ goodpoop
177
+ goo girl
178
+ goregasm
179
+ grope
180
+ group sex
181
+ g-spot
182
+ guro
183
+ hand job
184
+ handjob
185
+ hard core
186
+ hardcore
187
+ hentai
188
+ homoerotic
189
+ honkey
190
+ hooker
191
+ horny
192
+ hot carl
193
+ hot chick
194
+ how to kill
195
+ how to murder
196
+ huge fat
197
+ humping
198
+ incest
199
+ intercourse
200
+ jack off
201
+ jail bait
202
+ jailbait
203
+ jelly donut
204
+ jerk off
205
+ jigaboo
206
+ jiggaboo
207
+ jiggerboo
208
+ jizz
209
+ juggs
210
+ kike
211
+ kinbaku
212
+ kinkster
213
+ kinky
214
+ knobbing
215
+ leather restraint
216
+ leather straight jacket
217
+ lemon party
218
+ livesex
219
+ lolita
220
+ lovemaking
221
+ make me come
222
+ male squirting
223
+ masturbate
224
+ masturbating
225
+ masturbation
226
+ menage a trois
227
+ milf
228
+ missionary position
229
+ mong
230
+ motherfucker
231
+ mound of venus
232
+ mr hands
233
+ muff diver
234
+ muffdiving
235
+ nambla
236
+ nawashi
237
+ negro
238
+ neonazi
239
+ nigga
240
+ nigger
241
+ nig nog
242
+ nimphomania
243
+ nipple
244
+ nipples
245
+ nsfw
246
+ nsfw images
247
+ nude
248
+ nudity
249
+ nutten
250
+ nympho
251
+ nymphomania
252
+ octopussy
253
+ omorashi
254
+ one cup two girls
255
+ one guy one jar
256
+ orgasm
257
+ orgy
258
+ paedophile
259
+ paki
260
+ panties
261
+ panty
262
+ pedobear
263
+ pedophile
264
+ pegging
265
+ penis
266
+ phone sex
267
+ piece of shit
268
+ pikey
269
+ pissing
270
+ piss pig
271
+ pisspig
272
+ playboy
273
+ pleasure chest
274
+ pole smoker
275
+ ponyplay
276
+ poof
277
+ poon
278
+ poontang
279
+ punany
280
+ poop chute
281
+ poopchute
282
+ porn
283
+ porno
284
+ pornography
285
+ prince albert piercing
286
+ pthc
287
+ pubes
288
+ pussy
289
+ queaf
290
+ queef
291
+ quim
292
+ raghead
293
+ raging boner
294
+ rape
295
+ raping
296
+ rapist
297
+ rectum
298
+ reverse cowgirl
299
+ rimjob
300
+ rimming
301
+ rosy palm
302
+ rosy palm and her 5 sisters
303
+ rusty trombone
304
+ sadism
305
+ santorum
306
+ scat
307
+ schlong
308
+ scissoring
309
+ semen
310
+ sex
311
+ sexcam
312
+ sexo
313
+ sexy
314
+ sexual
315
+ sexually
316
+ sexuality
317
+ shaved beaver
318
+ shaved pussy
319
+ shemale
320
+ shibari
321
+ shitblimp
322
+ shitty
323
+ shitbag
324
+ shit
325
+ shota
326
+ shrimping
327
+ skeet
328
+ slanteye
329
+ slut
330
+ s&m
331
+ smut
332
+ snatch
333
+ snowballing
334
+ sodomize
335
+ sodomy
336
+ spastic
337
+ spic
338
+ splooge
339
+ splooge moose
340
+ spooge
341
+ spread legs
342
+ spunk
343
+ strap on
344
+ strapon
345
+ strappado
346
+ strip club
347
+ style doggy
348
+ suck
349
+ sucks
350
+ suicide girls
351
+ sultry women
352
+ swastika
353
+ swinger
354
+ tainted love
355
+ taste my
356
+ tea bagging
357
+ threesome
358
+ throating
359
+ thumbzilla
360
+ tied up
361
+ tight white
362
+ tit
363
+ tits
364
+ titties
365
+ titty
366
+ tongue in a
367
+ topless
368
+ tosser
369
+ towelhead
370
+ tranny
371
+ tribadism
372
+ tub girl
373
+ tubgirl
374
+ tushy
375
+ twat
376
+ twink
377
+ twinkie
378
+ two girls one cup
379
+ undressing
380
+ upskirt
381
+ urethra play
382
+ urophilia
383
+ vagina
384
+ venus mound
385
+ viagra
386
+ vibrator
387
+ violet wand
388
+ vorarephilia
389
+ voyeur
390
+ voyeurweb
391
+ voyuer
392
+ vulva
393
+ wank
394
+ wetback
395
+ wet dream
396
+ white power
397
+ whore
398
+ worldsex
399
+ wrapping men
400
+ wrinkled starfish
401
+ xx
402
+ xxx
403
+ yaoi
404
+ yellow showers
405
+ yiffy
406
+ zoophilia
407
+ 🖕
@@ -0,0 +1,5 @@
1
+ # frozen_string_literal: true
2
+
3
+ module NaughtyWords
4
+ VERSION = "0.1.1"
5
+ end
@@ -0,0 +1,17 @@
1
+ # frozen_string_literal: true
2
+
3
+ require_relative "naughty_words/version"
4
+ require "naughty_words/base"
5
+
6
+ module NaughtyWords
7
+ class Error < StandardError; end
8
+ class << self
9
+ def check(string:)
10
+ Base.profanity?(string: string)
11
+ end
12
+
13
+ def filter(string:, replacement: "*")
14
+ Base.filter(string: string, replacement: replacement)
15
+ end
16
+ end
17
+ end
Binary file
metadata ADDED
@@ -0,0 +1,64 @@
1
+ --- !ruby/object:Gem::Specification
2
+ name: naughty_words
3
+ version: !ruby/object:Gem::Version
4
+ version: 0.1.1
5
+ platform: ruby
6
+ authors:
7
+ - John Arnold
8
+ autorequire:
9
+ bindir: exe
10
+ cert_chain: []
11
+ date: 2022-05-19 00:00:00.000000000 Z
12
+ dependencies: []
13
+ description: This gem will detect simple profanity and can substitute them with a
14
+ specified replacement.
15
+ email:
16
+ - johnadamarnold@gmail.com
17
+ executables: []
18
+ extensions: []
19
+ extra_rdoc_files: []
20
+ files:
21
+ - ".rspec"
22
+ - ".rubocop.yml"
23
+ - CHANGELOG.md
24
+ - CODE_OF_CONDUCT.md
25
+ - Gemfile
26
+ - Gemfile.lock
27
+ - LICENSE.txt
28
+ - README.md
29
+ - Rakefile
30
+ - bin/console
31
+ - bin/setup
32
+ - lib/naughty_words.rb
33
+ - lib/naughty_words/base.rb
34
+ - lib/naughty_words/config/en.txt
35
+ - lib/naughty_words/version.rb
36
+ - naughty_words-0.1.0.gem
37
+ homepage: https://github.com/jaarnie/naughty_words
38
+ licenses:
39
+ - MIT
40
+ metadata:
41
+ allowed_push_host: https://rubygems.org
42
+ homepage_uri: https://github.com/jaarnie/naughty_words
43
+ source_code_uri: https://github.com/jaarnie/naughty_words
44
+ changelog_uri: https://github.com/jaarnie/naughty_words/blob/main/CHANGELOG.md
45
+ post_install_message:
46
+ rdoc_options: []
47
+ require_paths:
48
+ - lib
49
+ required_ruby_version: !ruby/object:Gem::Requirement
50
+ requirements:
51
+ - - ">="
52
+ - !ruby/object:Gem::Version
53
+ version: 2.6.0
54
+ required_rubygems_version: !ruby/object:Gem::Requirement
55
+ requirements:
56
+ - - ">="
57
+ - !ruby/object:Gem::Version
58
+ version: '0'
59
+ requirements: []
60
+ rubygems_version: 3.1.6
61
+ signing_key:
62
+ specification_version: 4
63
+ summary: Simple gem to detect naughty words
64
+ test_files: []