space2dot 0.0.3 → 0.1.1
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/.rspec +0 -1
- data/Gemfile +0 -1
- data/README.md +11 -25
- data/Rakefile +7 -5
- data/bin/s2. +6 -0
- data/bin/space2dot +3 -4
- data/lib/space2dot/version.rb +1 -1
- data/lib/space2dot.rb +1 -5
- data/space2dot.gemspec +13 -12
- data/spec/space2dot_spec.rb +4 -8
- data/spec/spec_helper.rb +9 -1
- metadata +24 -8
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA1:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 964e1b346ea243d0c641b074684c850af5c47aaf
|
4
|
+
data.tar.gz: 628f1413c4e3005103bbaedc3cf342a51eebf0b1
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 2948899e37b0c9a4e6235810332449bbba32646e37d6c07aeb023714b288a3effae8828cef6dc8655e26e216c9395ad1188e8d06b4b1358d90e6f3f5304d755a
|
7
|
+
data.tar.gz: 94f12e9ea8b35e63ff529d395197cb143c6a6ebceb3c2b896d5ae40adb083657cf332dcfb2cf56aca980870aaec073daf5928ad5f76d884e6c53c4d2d0fb40d2
|
data/.rspec
CHANGED
data/Gemfile
CHANGED
data/README.md
CHANGED
@@ -1,39 +1,26 @@
|
|
1
1
|
# Space2dot
|
2
|
-
## What
|
2
|
+
## What is space2dot
|
3
3
|
Change the space into dot.
|
4
4
|
|
5
5
|
## Installation
|
6
|
-
|
7
|
-
Add this line to your application's Gemfile:
|
8
|
-
|
9
|
-
gem 'space2dot'
|
10
|
-
|
11
|
-
And then execute:
|
12
|
-
|
13
|
-
$ bundle
|
14
|
-
|
15
|
-
Or install it yourself as:
|
6
|
+
Install it yourself as:
|
16
7
|
|
17
8
|
$ gem install space2dot
|
18
9
|
|
19
|
-
|
20
|
-
|
21
|
-
$ sudo apt-get install xsel
|
22
|
-
|
23
|
-
If your computer is CentOS
|
24
|
-
|
25
|
-
$ sudo yum -y install xsel
|
10
|
+
## Usage
|
26
11
|
|
27
|
-
|
12
|
+
From the terminal:
|
28
13
|
|
29
|
-
$
|
14
|
+
$ space2dot style sheet
|
15
|
+
=> .style.sheet # Output to the standard output
|
30
16
|
|
31
|
-
##
|
17
|
+
## Shorthand
|
32
18
|
|
33
|
-
|
19
|
+
A shorthand alias for space2dot can also be used.
|
34
20
|
|
35
|
-
|
36
|
-
|
21
|
+
```
|
22
|
+
s2. new branch
|
23
|
+
```
|
37
24
|
|
38
25
|
## Contributing
|
39
26
|
|
@@ -42,4 +29,3 @@ From the terminal:
|
|
42
29
|
3. Commit your changes (`git commit -am 'Add some feature'`)
|
43
30
|
4. Push to the branch (`git push origin my-new-feature`)
|
44
31
|
5. Create new Pull Request
|
45
|
-
|
data/Rakefile
CHANGED
@@ -1,7 +1,9 @@
|
|
1
|
-
require
|
2
|
-
require "rspec/core/rake_task"
|
1
|
+
require 'bundler/gem_tasks'
|
3
2
|
|
4
|
-
|
5
|
-
|
6
|
-
task :default => :spec
|
3
|
+
Bundler.setup
|
4
|
+
require 'rspec/core/rake_task'
|
7
5
|
|
6
|
+
desc 'run spec'
|
7
|
+
RSpec::Core::RakeTask.new(:spec) do |t|
|
8
|
+
t.rspec_opts = ['-c', '-fs']
|
9
|
+
end
|
data/bin/s2.
ADDED
data/bin/space2dot
CHANGED
data/lib/space2dot/version.rb
CHANGED
data/lib/space2dot.rb
CHANGED
@@ -3,11 +3,7 @@ require 'space2dot/version'
|
|
3
3
|
module Space2dot
|
4
4
|
class << self
|
5
5
|
def convert(argv)
|
6
|
-
argv.length == 1 ? argv[0].strip.gsub(/\s/, '.')
|
7
|
-
end
|
8
|
-
|
9
|
-
def copy_command(dot_include_sentence)
|
10
|
-
"echo #{dot_include_sentence} | ruby -pe 'chomp' | pbcopy"
|
6
|
+
argv.length == 1 ? argv[0].strip.gsub(/\s/, '.') : argv.join('.')
|
11
7
|
end
|
12
8
|
end
|
13
9
|
end
|
data/space2dot.gemspec
CHANGED
@@ -4,21 +4,22 @@ $LOAD_PATH.unshift(lib) unless $LOAD_PATH.include?(lib)
|
|
4
4
|
require 'space2dot/version'
|
5
5
|
|
6
6
|
Gem::Specification.new do |spec|
|
7
|
-
spec.name =
|
7
|
+
spec.name = 'space2dot'
|
8
8
|
spec.version = Space2dot::VERSION
|
9
|
-
spec.authors = [
|
10
|
-
spec.email = [
|
11
|
-
spec.description =
|
12
|
-
spec.summary =
|
13
|
-
spec.homepage =
|
14
|
-
spec.license =
|
9
|
+
spec.authors = ['sachin21']
|
10
|
+
spec.email = ['sachin21.developer@gmail.com']
|
11
|
+
spec.description = 'change the space into dot'
|
12
|
+
spec.summary = 'change the space into dot'
|
13
|
+
spec.homepage = 'http://github.com/sachin21/space2dot'
|
14
|
+
spec.license = 'MIT'
|
15
15
|
|
16
|
-
spec.files = `git ls-files
|
16
|
+
spec.files = `git ls-files`.split($/)
|
17
17
|
spec.executables = spec.files.grep(%r{^bin/}) { |f| File.basename(f) }
|
18
18
|
spec.test_files = spec.files.grep(%r{^(test|spec|features)/})
|
19
|
-
spec.require_paths = [
|
19
|
+
spec.require_paths = ['lib']
|
20
20
|
|
21
|
-
spec.add_development_dependency
|
22
|
-
spec.add_development_dependency
|
23
|
-
spec.add_development_dependency
|
21
|
+
spec.add_development_dependency 'bundler', '~> 1.3'
|
22
|
+
spec.add_development_dependency 'rake'
|
23
|
+
spec.add_development_dependency 'rspec'
|
24
|
+
spec.add_development_dependency 'pry'
|
24
25
|
end
|
data/spec/space2dot_spec.rb
CHANGED
@@ -1,12 +1,8 @@
|
|
1
|
-
require
|
1
|
+
require 'spec_helper'
|
2
2
|
|
3
3
|
describe Space2dot do
|
4
|
-
it '
|
5
|
-
expect(Space2dot.convert(['fuga hoge foo'])).to
|
6
|
-
expect(Space2dot.convert(%w(fuga hoge foo))).to
|
7
|
-
end
|
8
|
-
|
9
|
-
it 'Successful copied' do
|
10
|
-
expect(Space2dot.copy_command('.fuga.hoge.foo')).to eq("echo .fuga.hoge.foo | ruby -pe 'chomp' | pbcopy")
|
4
|
+
it 'returns dot included in string' do
|
5
|
+
expect(Space2dot.convert(['fuga hoge foo'])).to include('.') # String case
|
6
|
+
expect(Space2dot.convert(%w(fuga hoge foo))).to include('.') # Array case
|
11
7
|
end
|
12
8
|
end
|
data/spec/spec_helper.rb
CHANGED
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: space2dot
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.
|
4
|
+
version: 0.1.1
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- sachin21
|
8
8
|
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date:
|
11
|
+
date: 2015-09-09 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: bundler
|
@@ -16,14 +16,14 @@ dependencies:
|
|
16
16
|
requirements:
|
17
17
|
- - "~>"
|
18
18
|
- !ruby/object:Gem::Version
|
19
|
-
version: '1.
|
19
|
+
version: '1.3'
|
20
20
|
type: :development
|
21
21
|
prerelease: false
|
22
22
|
version_requirements: !ruby/object:Gem::Requirement
|
23
23
|
requirements:
|
24
24
|
- - "~>"
|
25
25
|
- !ruby/object:Gem::Version
|
26
|
-
version: '1.
|
26
|
+
version: '1.3'
|
27
27
|
- !ruby/object:Gem::Dependency
|
28
28
|
name: rake
|
29
29
|
requirement: !ruby/object:Gem::Requirement
|
@@ -52,10 +52,25 @@ dependencies:
|
|
52
52
|
- - ">="
|
53
53
|
- !ruby/object:Gem::Version
|
54
54
|
version: '0'
|
55
|
-
|
55
|
+
- !ruby/object:Gem::Dependency
|
56
|
+
name: pry
|
57
|
+
requirement: !ruby/object:Gem::Requirement
|
58
|
+
requirements:
|
59
|
+
- - ">="
|
60
|
+
- !ruby/object:Gem::Version
|
61
|
+
version: '0'
|
62
|
+
type: :development
|
63
|
+
prerelease: false
|
64
|
+
version_requirements: !ruby/object:Gem::Requirement
|
65
|
+
requirements:
|
66
|
+
- - ">="
|
67
|
+
- !ruby/object:Gem::Version
|
68
|
+
version: '0'
|
69
|
+
description: change the space into dot
|
56
70
|
email:
|
57
71
|
- sachin21.developer@gmail.com
|
58
72
|
executables:
|
73
|
+
- s2.
|
59
74
|
- space2dot
|
60
75
|
extensions: []
|
61
76
|
extra_rdoc_files: []
|
@@ -66,13 +81,14 @@ files:
|
|
66
81
|
- LICENSE.txt
|
67
82
|
- README.md
|
68
83
|
- Rakefile
|
84
|
+
- bin/s2.
|
69
85
|
- bin/space2dot
|
70
86
|
- lib/space2dot.rb
|
71
87
|
- lib/space2dot/version.rb
|
72
88
|
- space2dot.gemspec
|
73
89
|
- spec/space2dot_spec.rb
|
74
90
|
- spec/spec_helper.rb
|
75
|
-
homepage:
|
91
|
+
homepage: http://github.com/sachin21/space2dot
|
76
92
|
licenses:
|
77
93
|
- MIT
|
78
94
|
metadata: {}
|
@@ -92,10 +108,10 @@ required_rubygems_version: !ruby/object:Gem::Requirement
|
|
92
108
|
version: '0'
|
93
109
|
requirements: []
|
94
110
|
rubyforge_project:
|
95
|
-
rubygems_version: 2.
|
111
|
+
rubygems_version: 2.2.3
|
96
112
|
signing_key:
|
97
113
|
specification_version: 4
|
98
|
-
summary:
|
114
|
+
summary: change the space into dot
|
99
115
|
test_files:
|
100
116
|
- spec/space2dot_spec.rb
|
101
117
|
- spec/spec_helper.rb
|