middleman-dotenv 0.0.1 → 0.0.2

Sign up to get free protection for your applications and to get access to all the features.
checksums.yaml CHANGED
@@ -1,15 +1,7 @@
1
1
  ---
2
- !binary "U0hBMQ==":
3
- metadata.gz: !binary |-
4
- NGQ3NGEwMzFmNTUyZjhkNjdlODVhOThmOWJhM2FkNDc2MTI5MmFlZQ==
5
- data.tar.gz: !binary |-
6
- ZTdiNDBmZjYwM2RiZjllYWEwNWNkMWFmOTYwYmE1YjcxYzFkYTc1NA==
7
- !binary "U0hBNTEy":
8
- metadata.gz: !binary |-
9
- YTgxNjI5ZTgzYmEzYWU0ZWE0YWM2ZmVhMWZiN2ZmMjhiODI0MzI2MTJmZjU1
10
- ZTg3NjRhNWFhMmJhNGRmNzNmYzMwMTY5ZjUxMjQxMzcyZGFkZjM4NWU3NzIy
11
- YWNlOWU2ZGNmZjA3MDkzNDk0NzZlNTUzNzJjYTllZGNmNGFiOTE=
12
- data.tar.gz: !binary |-
13
- YzAwMjE4NmQyNjk3NzBjNDVmOGYzYTkwNDg0ZDc5NTM3MzZiYjVhNTcxMGFj
14
- NDgyNTY4MWY1NzMxM2M0N2U4ZTQ3YmI3ZTBiMzc2Y2FmZjQyMzA4OGEwZmI2
15
- NTE1NmU4YTAyMGUzMjZlZjc4NWRjNzFhMjYzMTMxZjA2M2E4OTY=
2
+ SHA1:
3
+ metadata.gz: 10fc82284945fd1a4b71220b38c5e958989f7bb9
4
+ data.tar.gz: 36aed4d80a65778cf92acef6ce3c8a66f8868ff1
5
+ SHA512:
6
+ metadata.gz: ea78d87df587d8d2250cbe5ad416f82950aac1f55829fcf8eed905c13eda876714209b7ef05bd08110afbeec5ee305b50a7dfe2015a9cbf37098d8fd1a0352d8
7
+ data.tar.gz: 050ccbcc9f51ef6dd0fcce4c42ef22a0debc13a89669de5e949c26c49df0e9ec703d45f043ad76c5e2d974678d023b2671cf9cb7a6e4269957f2fb055d808c67
data/README.md CHANGED
@@ -1,9 +1,55 @@
1
- ## Middleman Dotenv ( WIP ) [![Gem Version](https://badge.fury.io/rb/middleman-dotenv.png)][gem] [![Build Status](https://travis-ci.org/karlfreeman/middleman-dotenv.png?branch=feature/3-1-rewrite)][travis] [![Dependency Status](https://gemnasium.com/karlfreeman/middleman-dotenv.png?travis)][gemnasium] [![Coverage Status](https://coveralls.io/repos/karlfreeman/middleman-dotenv/badge.png?branch=feature/3-1-rewrite)][coveralls] [![Code Climate](https://codeclimate.com/github/karlfreeman/middleman-dotenv.png)][codeclimate]
1
+ # Middleman Dotenv
2
2
 
3
- Dotenv for Middleman
3
+ Integrates [Dotenv][dotenv] into [Middleman][middleman]
4
+
5
+ ## Features / Usage Examples
6
+
7
+ ## Installation
8
+
9
+ Add `middleman-dotenv` to your `Gemfile`, open your `config.rb` and add the following right at the top of the file
10
+
11
+ ```ruby
12
+ activate :dotenv
13
+ ```
14
+
15
+ ```ruby
16
+ # Use environment specific .env files
17
+ configure :development do
18
+ activate :dotenv, :env => '.env.development'
19
+ end
20
+
21
+ configure :build do
22
+ activate :dotenv, :env => '.env.build'
23
+ end
24
+ ```
25
+
26
+ ## Badges
27
+
28
+ [![Gem Version](https://badge.fury.io/rb/middleman-dotenv.png)][gem]
29
+ [![Build Status](https://travis-ci.org/karlfreeman/middleman-dotenv.png)][travis]
30
+ [![Code Quality](https://codeclimate.com/github/karlfreeman/middleman-dotenv.png)][codeclimate]
31
+ [![Coverage Status](https://coveralls.io/repos/karlfreeman/middleman-dotenv/badge.png?branch=master)][coveralls]
32
+ [![Gittip](http://img.shields.io/gittip/karlfreeman.png)][gittip]
33
+
34
+ ## Supported Ruby Versions
35
+
36
+ This library aims to support and is [tested against][travis] the following Ruby
37
+ implementations:
38
+
39
+ * Ruby 1.9.3
40
+ * Ruby 2.0.0
41
+ * [JRuby][]
42
+ * [Rubinius][]
43
+
44
+ # Credits
4
45
 
5
46
  [gem]: https://rubygems.org/gems/middleman-dotenv
6
47
  [travis]: http://travis-ci.org/karlfreeman/middleman-dotenv
7
- [gemnasium]: https://gemnasium.com/karlfreeman/middleman-dotenv
8
48
  [coveralls]: https://coveralls.io/r/karlfreeman/middleman-dotenv
9
49
  [codeclimate]: https://codeclimate.com/github/karlfreeman/middleman-dotenv
50
+ [gittip]: https://www.gittip.com/karlfreeman
51
+ [jruby]: http://www.jruby.org
52
+ [rubinius]: http://rubini.us
53
+
54
+ [dotenv]: https://github.com/bkeepers/dotenv
55
+ [middleman]: http://middlemanapp.com
data/Rakefile CHANGED
@@ -1,6 +1,7 @@
1
1
  require 'bundler'
2
2
  Bundler::GemHelper.install_tasks
3
3
 
4
+ require 'cucumber'
4
5
  require 'cucumber/rake/task'
5
6
  Cucumber::Rake::Task.new(:cucumber, 'Run features that should pass') do |t|
6
7
  ENV["TEST"] = "true"
@@ -16,4 +17,4 @@ task :test => ["cucumber"]
16
17
  desc "Build HTML documentation"
17
18
  task :doc do
18
19
  sh 'bundle exec yard'
19
- end
20
+ end
@@ -1,7 +1,6 @@
1
- require "middleman-core"
2
- require "middleman-dotenv/version"
1
+ require 'middleman-core'
3
2
 
4
3
  ::Middleman::Extensions.register(:dotenv) do
5
- require "middleman-dotenv/extension"
4
+ require 'middleman-dotenv/extension'
6
5
  ::Middleman::Dotenv
7
- end
6
+ end
@@ -2,13 +2,14 @@ module Middleman
2
2
  module Dotenv
3
3
  class << self
4
4
  def registered(app, options_hash={})
5
- require 'dotenv'
6
- ::Dotenv.load File.join(Dir.pwd, ".env")
5
+ env = options_hash[:env] || '.env'
6
+ require 'dotenv' unless defined?(::Dotenv)
7
+ ::Dotenv.load File.join(Dir.pwd, env)
7
8
  app.before do
8
- ::Dotenv.load File.join(self.class.inst.root, ".env")
9
+ ::Dotenv.load File.join(self.class.inst.root, env)
9
10
  end
10
11
  end
11
12
  alias :included :registered
12
13
  end
13
14
  end
14
- end
15
+ end
@@ -1,5 +1,5 @@
1
1
  module Middleman
2
2
  module Dotenv
3
- VERSION = "0.0.1"
3
+ VERSION = '0.0.2' unless defined?(Middleman::Dotenv::VERSION)
4
4
  end
5
5
  end
@@ -0,0 +1 @@
1
+ require 'middleman-dotenv'
@@ -8,8 +8,8 @@ Gem::Specification.new do |s|
8
8
  s.authors = ["Karl Freeman"]
9
9
  s.email = ["karlfreeman@gmail.com"]
10
10
  s.homepage = "https://github.com/karlfreeman/middleman-dotenv"
11
- s.summary = %q{}
12
- s.description = %q{}
11
+ s.summary = %q{Dotenv for Middleman}
12
+ s.description = %q{Dotenv for Middleman}
13
13
 
14
14
  s.files = `git ls-files -z`.split("\0")
15
15
  s.test_files = `git ls-files -z -- {fixtures,features}/*`.split("\0")
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: middleman-dotenv
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.0.1
4
+ version: 0.0.2
5
5
  platform: ruby
6
6
  authors:
7
7
  - Karl Freeman
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2013-05-16 00:00:00.000000000 Z
11
+ date: 2013-12-14 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: middleman-core
@@ -38,7 +38,7 @@ dependencies:
38
38
  - - ~>
39
39
  - !ruby/object:Gem::Version
40
40
  version: 0.7.0
41
- description: ''
41
+ description: Dotenv for Middleman
42
42
  email:
43
43
  - karlfreeman@gmail.com
44
44
  executables: []
@@ -60,8 +60,8 @@ files:
60
60
  - fixtures/envless-app/source/test.html.erb
61
61
  - lib/middleman-dotenv.rb
62
62
  - lib/middleman-dotenv/extension.rb
63
- - lib/middleman-dotenv/middleman_extension.rb
64
63
  - lib/middleman-dotenv/version.rb
64
+ - lib/middleman_extension.rb
65
65
  - middleman-dotenv.gemspec
66
66
  homepage: https://github.com/karlfreeman/middleman-dotenv
67
67
  licenses: []
@@ -72,20 +72,20 @@ require_paths:
72
72
  - lib
73
73
  required_ruby_version: !ruby/object:Gem::Requirement
74
74
  requirements:
75
- - - ! '>='
75
+ - - '>='
76
76
  - !ruby/object:Gem::Version
77
77
  version: '0'
78
78
  required_rubygems_version: !ruby/object:Gem::Requirement
79
79
  requirements:
80
- - - ! '>='
80
+ - - '>='
81
81
  - !ruby/object:Gem::Version
82
82
  version: '0'
83
83
  requirements: []
84
84
  rubyforge_project:
85
- rubygems_version: 2.0.1
85
+ rubygems_version: 2.0.3
86
86
  signing_key:
87
87
  specification_version: 4
88
- summary: ''
88
+ summary: Dotenv for Middleman
89
89
  test_files:
90
90
  - features/dotenv.feature
91
91
  - features/support/env.rb
@@ -1 +0,0 @@
1
- require 'middleman-dotenv'