extended_string 0.1.6 → 0.1.7
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.
- data/README.rdoc +51 -27
- data/VERSION +1 -1
- data/extended_string.gemspec +1 -1
- metadata +3 -3
data/README.rdoc
CHANGED
@@ -1,43 +1,45 @@
|
|
1
1
|
= extended_string
|
2
2
|
|
3
|
-
|
3
|
+
Intention for this gem is to follow step by step how to create the very gem from the scratch. It will add one method to
|
4
4
|
standard String class. I intend to put some tests, release couple of versions, and so on...
|
5
5
|
|
6
6
|
== Preconfig
|
7
7
|
|
8
8
|
=== Install Rails
|
9
9
|
|
10
|
-
|
11
|
-
|
10
|
+
I do prefer using rvm for this task, but it can be done as it is. If you know how to use rvm, then you will not
|
11
|
+
need any guidance.
|
12
12
|
|
13
13
|
gem install rails --no-ri --no-rdoc
|
14
14
|
gem install jeweler
|
15
15
|
|
16
|
-
|
16
|
+
Currently I'm working on version 3.0.1
|
17
17
|
|
18
18
|
=== Configure Git
|
19
|
-
|
19
|
+
|
20
|
+
You need to configure some git settings, before you use jeweler to create first gem.
|
20
21
|
|
21
22
|
git config --global github.user m4risU
|
22
|
-
git config --global github.token 227addfh048cgfbbda2060dc8e9233a6
|
23
|
-
|
24
|
-
|
23
|
+
git config --global github.token 227addfh048cgfbbda2060dc8e9233a6
|
24
|
+
|
25
|
+
Don't worry, this is not my key, but you have to use yours.
|
26
|
+
Probably you will find it in here:
|
25
27
|
|
26
|
-
https://github.com/account in Account Admin
|
28
|
+
https://github.com/account in Account Admin
|
27
29
|
|
28
30
|
=== Generate the gem project
|
29
31
|
|
30
32
|
jeveler enhanced_string
|
31
33
|
|
32
|
-
|
34
|
+
Good. We are here! What can we do next?
|
33
35
|
|
34
36
|
=== Rake tasks
|
35
37
|
|
36
|
-
|
38
|
+
As I already know, rake tasks will be the key to build the gem. so lets try
|
37
39
|
|
38
40
|
rake -T
|
39
41
|
|
40
|
-
|
42
|
+
It will give the following
|
41
43
|
|
42
44
|
rake build # Build gem
|
43
45
|
rake check_dependencies # Check that runtime and development d...
|
@@ -64,54 +66,76 @@ https://github.com/account in Account Admin
|
|
64
66
|
|
65
67
|
=== Install the gem locally
|
66
68
|
|
67
|
-
|
69
|
+
To do this we need to write the very first version.
|
68
70
|
|
69
71
|
rake version:write MAJOR=0 MINOR=1 PATCH=0
|
70
72
|
|
71
|
-
|
73
|
+
and after that
|
72
74
|
|
73
75
|
rake install
|
74
76
|
|
75
77
|
=== First issues
|
76
78
|
|
77
|
-
|
79
|
+
After previous line I run into following problem:
|
78
80
|
|
79
81
|
"FIXME" or "TODO" is not a description
|
80
82
|
|
81
|
-
|
83
|
+
Oh, yes! I didn't look carefully on Rakefile file.
|
82
84
|
|
83
|
-
|
84
|
-
|
85
|
+
There was auot generated line:
|
86
|
+
s.description = %q{TODO: longer description of your gem}
|
87
|
+
You know how to fix it I hope :)
|
85
88
|
|
86
89
|
=== RVM and system rubies
|
87
90
|
|
88
|
-
|
91
|
+
When using rvm, it is enough, but in other cases, it is possible you will need to use
|
89
92
|
|
90
93
|
sudo rake install
|
91
94
|
|
92
|
-
|
95
|
+
Just remember about that.
|
93
96
|
|
94
97
|
=== I'm ready!
|
95
98
|
|
96
|
-
|
99
|
+
You want to get the world amazed with your work? Try this!
|
97
100
|
|
98
101
|
rake release
|
99
102
|
|
100
103
|
=== Project do not exist yet on github?
|
101
104
|
|
102
|
-
|
103
|
-
|
105
|
+
Ok, How to start with it?
|
106
|
+
I simply went to my git account and created project extended_string, then From command line after commits to local repo
|
104
107
|
|
105
108
|
git push origin master
|
106
109
|
|
110
|
+
=== Account on Rubygems.com
|
111
|
+
|
112
|
+
You will be asked to create account on Rubygems.com nothing hard really. Confirm an account with the email, and
|
113
|
+
when you release you will be able to provide credentials to your account
|
114
|
+
|
115
|
+
=== Bumping versions
|
116
|
+
|
117
|
+
I found it usefull, since You do not want to do it manually. Do it often, keep sanity :)
|
118
|
+
|
119
|
+
rake versions:bump:patch
|
120
|
+
|
121
|
+
0.1.2 => 0.1.3
|
122
|
+
|
123
|
+
rake versions:bump:minor
|
124
|
+
|
125
|
+
0.1.2 => 0.2.2
|
126
|
+
|
127
|
+
rake versions:bump:major
|
128
|
+
|
129
|
+
0.1.2 => 1.1.2
|
130
|
+
|
107
131
|
=== Test my work with rvm
|
108
132
|
|
109
133
|
rvm install ree
|
110
134
|
rvm --create ree@foo
|
111
135
|
|
112
|
-
|
136
|
+
I will not worry about this gemset, but I want to check if I can install my gem from gems.
|
113
137
|
|
114
|
-
|
138
|
+
I got after following
|
115
139
|
gem install extended_string
|
116
140
|
ERROR: Could not find a valid gem 'extended_string' (>= 0) in any repository
|
117
141
|
|
@@ -121,11 +145,11 @@ http://github.com/technicalpickles/jeweler
|
|
121
145
|
|
122
146
|
== Instalation notes
|
123
147
|
|
124
|
-
Rails 3.0
|
148
|
+
=== Rails 3.0
|
125
149
|
|
126
150
|
in your Gemfile
|
127
151
|
|
128
|
-
gem "extended_string"
|
152
|
+
gem "extended_string"
|
129
153
|
|
130
154
|
== Usage
|
131
155
|
|
data/VERSION
CHANGED
@@ -1 +1 @@
|
|
1
|
-
0.1.
|
1
|
+
0.1.7
|
data/extended_string.gemspec
CHANGED
metadata
CHANGED
@@ -1,13 +1,13 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: extended_string
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
hash:
|
4
|
+
hash: 21
|
5
5
|
prerelease: false
|
6
6
|
segments:
|
7
7
|
- 0
|
8
8
|
- 1
|
9
|
-
-
|
10
|
-
version: 0.1.
|
9
|
+
- 7
|
10
|
+
version: 0.1.7
|
11
11
|
platform: ruby
|
12
12
|
authors:
|
13
13
|
- "Mariusz Wyroz\xC4\x99bski"
|