slugifa 0.0.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 ADDED
@@ -0,0 +1,7 @@
1
+ ---
2
+ SHA1:
3
+ metadata.gz: 19ef66d846f8c1735ecb7473c6390c34704fe6a1
4
+ data.tar.gz: dd98d64e97400b1216c69640b09ba454605e4c0f
5
+ SHA512:
6
+ metadata.gz: 6973dee17cf262e5ab22b1bf26b0d6b83b699b7659ba58bdca86eb6e7c4ab6c985096d3021be11a8d2d7a030475e781a2e4ff85089b2cc17642ec8b86556c6f5
7
+ data.tar.gz: 31f60007ce057758045ce3be318c4f023f585f0b28b1477a656dc9fffc4aa219a3c4243638845100b501f2ee4366125d2580687977e747ec4b493ca6a3933bbc
data/lib/slugifa.rb ADDED
@@ -0,0 +1,3 @@
1
+ # encoding: utf-8
2
+
3
+ require 'slugifa/slugifa_string'
@@ -0,0 +1,9 @@
1
+
2
+ String.class_eval do
3
+ def slugifa
4
+ string = self.downcase
5
+ string.gsub!(/([^آ-ی۰-۹a-z0-9]|-)+/, '-')
6
+ string.gsub!(/-+/, '-')
7
+ string
8
+ end
9
+ end
@@ -0,0 +1,3 @@
1
+ module Slugifa
2
+ VERSION = '0.0.1'
3
+ end
metadata ADDED
@@ -0,0 +1,47 @@
1
+ --- !ruby/object:Gem::Specification
2
+ name: slugifa
3
+ version: !ruby/object:Gem::Version
4
+ version: 0.0.1
5
+ platform: ruby
6
+ authors:
7
+ - Mohsen Alizadeh
8
+ autorequire:
9
+ bindir: bin
10
+ cert_chain: []
11
+ date: 2016-09-23 00:00:00.000000000 Z
12
+ dependencies: []
13
+ description: slug with Persian character set support.
14
+ email:
15
+ - mohsen@alizadeh.us
16
+ executables: []
17
+ extensions: []
18
+ extra_rdoc_files: []
19
+ files:
20
+ - lib/slugifa.rb
21
+ - lib/slugifa/slugifa_string.rb
22
+ - lib/slugifa/version.rb
23
+ homepage: https://github.com/mohsen-alizadeh/slugify
24
+ licenses: []
25
+ metadata: {}
26
+ post_install_message:
27
+ rdoc_options: []
28
+ require_paths:
29
+ - lib
30
+ required_ruby_version: !ruby/object:Gem::Requirement
31
+ requirements:
32
+ - - ">="
33
+ - !ruby/object:Gem::Version
34
+ version: '0'
35
+ required_rubygems_version: !ruby/object:Gem::Requirement
36
+ requirements:
37
+ - - ">="
38
+ - !ruby/object:Gem::Version
39
+ version: '0'
40
+ requirements: []
41
+ rubyforge_project:
42
+ rubygems_version: 2.6.6
43
+ signing_key:
44
+ specification_version: 4
45
+ summary: slug with Persian character set support.
46
+ test_files: []
47
+ has_rdoc: