exemplify 0.0.1

Sign up to get free protection for your applications and to get access to all the features.
@@ -0,0 +1,7 @@
1
+ ---
2
+ SHA1:
3
+ metadata.gz: 4b8942206ef1ebdcf30dd3ab5aaf3c16b27ffe9a
4
+ data.tar.gz: a1cc1a2b8a0738391d6b629441dab009ab122dac
5
+ SHA512:
6
+ metadata.gz: 827c7b09c112f7dac3af587bc8f3e55006df6637aaafba27afd80de97c09c537ec7e5b98f9a8e4eb0edb896373f4318d76b84203e6c1276dc9640be5b53ad68a
7
+ data.tar.gz: 05ba05970c55afdb96f911c41c0ef55b9e563de17d240038502913bcbe78bbc803f62e69c05fb071f684e7c7cb96208a77bc982755d696a715ce8e4d8ce2e436
@@ -0,0 +1,20 @@
1
+ Copyright 2014 YOURNAME
2
+
3
+ Permission is hereby granted, free of charge, to any person obtaining
4
+ a copy of this software and associated documentation files (the
5
+ "Software"), to deal in the Software without restriction, including
6
+ without limitation the rights to use, copy, modify, merge, publish,
7
+ distribute, sublicense, and/or sell copies of the Software, and to
8
+ permit persons to whom the Software is furnished to do so, subject to
9
+ the following conditions:
10
+
11
+ The above copyright notice and this permission notice shall be
12
+ included in all copies or substantial portions of the Software.
13
+
14
+ THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
15
+ EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
16
+ MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND
17
+ NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE
18
+ LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
19
+ OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION
20
+ WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
@@ -0,0 +1,32 @@
1
+ begin
2
+ require 'bundler/setup'
3
+ rescue LoadError
4
+ puts 'You must `gem install bundler` and `bundle install` to run rake tasks'
5
+ end
6
+
7
+ require 'rdoc/task'
8
+
9
+ RDoc::Task.new(:rdoc) do |rdoc|
10
+ rdoc.rdoc_dir = 'rdoc'
11
+ rdoc.title = 'Exemplify'
12
+ rdoc.options << '--line-numbers'
13
+ rdoc.rdoc_files.include('README.rdoc')
14
+ rdoc.rdoc_files.include('lib/**/*.rb')
15
+ end
16
+
17
+
18
+
19
+
20
+ Bundler::GemHelper.install_tasks
21
+
22
+ # require 'rake/testtask'
23
+
24
+ # Rake::TestTask.new(:test) do |t|
25
+ # t.libs << 'lib'
26
+ # t.libs << 'test'
27
+ # t.pattern = 'test/**/*_test.rb'
28
+ # t.verbose = false
29
+ # end
30
+
31
+
32
+ # task default: :test
@@ -0,0 +1,3 @@
1
+ module Exemplify
2
+ VERSION = "0.0.1"
3
+ end
@@ -0,0 +1,35 @@
1
+ ##
2
+ # Exemplify rake tasks
3
+ #
4
+ # Will help to create configuration files from their .example templates
5
+ # See https://github.com/Velid/exemplify for Readme and examples
6
+ #
7
+ namespace :exemplify do
8
+
9
+ FileList['config/**/*.example'].each do |template|
10
+ target = template.chomp('.example')
11
+
12
+ desc "Create configuration file #{target} from its .example template"
13
+ task target => template do
14
+
15
+ # Abort if target file already exists
16
+ if File.exists? target
17
+ puts "[WARNING] Specified file #{target} already exists, skipping"
18
+ else
19
+ # Proceed if example file has been found
20
+ puts "[INFO] Template file #{template} found, will exemplify now"
21
+ begin
22
+ cp template, target
23
+ puts "[OK] Created #{target} from template"
24
+ rescue Exception => error
25
+ puts "[ERROR] Failed to copy template file to #{target}: #{error}"
26
+ end
27
+ end
28
+
29
+ end
30
+ # Add generic task to load all targets
31
+ task :all => target
32
+
33
+ end
34
+
35
+ end
metadata ADDED
@@ -0,0 +1,64 @@
1
+ --- !ruby/object:Gem::Specification
2
+ name: exemplify
3
+ version: !ruby/object:Gem::Version
4
+ version: 0.0.1
5
+ platform: ruby
6
+ authors:
7
+ - Alexey Efremov
8
+ autorequire:
9
+ bindir: bin
10
+ cert_chain: []
11
+ date: 2014-07-16 00:00:00.000000000 Z
12
+ dependencies:
13
+ - !ruby/object:Gem::Dependency
14
+ name: rails
15
+ requirement: !ruby/object:Gem::Requirement
16
+ requirements:
17
+ - - "~>"
18
+ - !ruby/object:Gem::Version
19
+ version: 4.1.2
20
+ type: :runtime
21
+ prerelease: false
22
+ version_requirements: !ruby/object:Gem::Requirement
23
+ requirements:
24
+ - - "~>"
25
+ - !ruby/object:Gem::Version
26
+ version: 4.1.2
27
+ description: Exemplify eases templating of your configuration files, automatically
28
+ detecting .example files and copying them in place.
29
+ email:
30
+ - aefremov@velidit.ru
31
+ executables: []
32
+ extensions: []
33
+ extra_rdoc_files: []
34
+ files:
35
+ - MIT-LICENSE
36
+ - Rakefile
37
+ - lib/exemplify/version.rb
38
+ - lib/tasks/exemplify_tasks.rake
39
+ homepage: http://velidit.ru
40
+ licenses:
41
+ - MIT
42
+ metadata: {}
43
+ post_install_message:
44
+ rdoc_options: []
45
+ require_paths:
46
+ - lib
47
+ required_ruby_version: !ruby/object:Gem::Requirement
48
+ requirements:
49
+ - - ">="
50
+ - !ruby/object:Gem::Version
51
+ version: '0'
52
+ required_rubygems_version: !ruby/object:Gem::Requirement
53
+ requirements:
54
+ - - ">="
55
+ - !ruby/object:Gem::Version
56
+ version: '0'
57
+ requirements: []
58
+ rubyforge_project:
59
+ rubygems_version: 2.2.2
60
+ signing_key:
61
+ specification_version: 4
62
+ summary: Rake tasks to help keep your production configurations out of the source
63
+ control.
64
+ test_files: []