jekyll-s3 2.1.2 → 2.2.0
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.md +8 -6
- data/changelog.md +7 -0
- data/jekyll-s3.gemspec +2 -1
- data/lib/jekyll-s3/uploader.rb +0 -9
- metadata +17 -1
data/README.md
CHANGED
@@ -1,8 +1,7 @@
|
|
1
1
|
# jekyll-s3
|
2
2
|
|
3
|
-
[] (http://travis-ci.org/laurilehmijoki/jekyll-s3)
|
4
|
+
[](http://badge.fury.io/rb/jekyll-s3)
|
6
5
|
|
7
6
|
Deploy your jekyll site to S3.
|
8
7
|
|
@@ -26,8 +25,11 @@ s3_secret: YOUR_AWS_S3_SECRET_ACCESS_KEY
|
|
26
25
|
s3_bucket: your.blog.bucket.com
|
27
26
|
</pre>
|
28
27
|
* Edit it with your details (you can use [ERB](http://ruby-doc.org/stdlib-1.9.3/libdoc/erb/rdoc/ERB.html) in the file)
|
29
|
-
*
|
30
|
-
|
28
|
+
* Run `configure-s3-website --config-file _jekyll_s3.yml` This will configure
|
29
|
+
your bucket to function as an S3 website. If the bucket does not exist,
|
30
|
+
`configure-s3-website` will create it for you.
|
31
|
+
|
32
|
+
* Run `jekyll-s3` to push your Jekyll blog to S3. Congratulations! You are live.
|
31
33
|
|
32
34
|
## Additional features
|
33
35
|
|
@@ -55,7 +57,7 @@ It is easy to deliver your S3-based web site via Cloudfront, the CDN of Amazon.
|
|
55
57
|
Jekyll-s3 has a headless mode, where human interactions are disabled.
|
56
58
|
|
57
59
|
In the headless mode, `jekyll-s3` will automatically delete the files on the S3
|
58
|
-
bucket that are not on your local computer.
|
60
|
+
bucket that are not on your local computer.
|
59
61
|
|
60
62
|
Enable the headless mode by adding the `--headless` or `-h` argument after
|
61
63
|
`jekyll-s3`.
|
data/changelog.md
CHANGED
@@ -1,5 +1,12 @@
|
|
1
1
|
# Changelog
|
2
2
|
|
3
|
+
## 2.2.0
|
4
|
+
|
5
|
+
* Automatically configure the S3 bucket to function as a website.
|
6
|
+
|
7
|
+
This makes it easier to start hosting a Jekyll site on S3. It removes the need
|
8
|
+
to manually configure the S3 bucket in the Amazon AWS console.
|
9
|
+
|
3
10
|
## 2.1.2
|
4
11
|
|
5
12
|
* Remove a superfluous comma from uploader.rb. The comma might have caused
|
data/jekyll-s3.gemspec
CHANGED
@@ -3,7 +3,7 @@ $:.push File.expand_path("../lib", __FILE__)
|
|
3
3
|
|
4
4
|
Gem::Specification.new do |s|
|
5
5
|
s.name = "jekyll-s3"
|
6
|
-
s.version = "2.
|
6
|
+
s.version = "2.2.0"
|
7
7
|
s.platform = Gem::Platform::RUBY
|
8
8
|
s.authors = ["Philippe Creux", "Lauri Lehmijoki"]
|
9
9
|
s.email = ["pcreux@gmail.com", "lauri.lehmijoki@iki.fi"]
|
@@ -20,6 +20,7 @@ distribution, making it easy to deliver your blog via the CDN.}
|
|
20
20
|
s.add_dependency 'simple-cloudfront-invalidator', '~> 1.0.0'
|
21
21
|
s.add_dependency 'erubis', '~> 2.7.0'
|
22
22
|
s.add_dependency 'mime-types', '= 1.19'
|
23
|
+
s.add_dependency 'configure-s3-website', '~> 1.0.0'
|
23
24
|
|
24
25
|
s.add_development_dependency 'rspec'
|
25
26
|
s.add_development_dependency 'rspec-expectations'
|
data/lib/jekyll-s3/uploader.rb
CHANGED
@@ -7,8 +7,6 @@ module Jekyll
|
|
7
7
|
s3 = AWS::S3.new(:access_key_id => config['s3_id'],
|
8
8
|
:secret_access_key => config['s3_secret'])
|
9
9
|
|
10
|
-
create_bucket_if_needed(s3, config['s3_bucket'])
|
11
|
-
|
12
10
|
new_files_count, changed_files_count, changed_files = upload_files(
|
13
11
|
s3, config, site_dir
|
14
12
|
)
|
@@ -22,13 +20,6 @@ module Jekyll
|
|
22
20
|
|
23
21
|
private
|
24
22
|
|
25
|
-
def self.create_bucket_if_needed(s3, s3_bucket_name)
|
26
|
-
unless s3.buckets.map(&:name).include?(s3_bucket_name)
|
27
|
-
puts("Creating bucket #{s3_bucket_name}")
|
28
|
-
s3.buckets.create(s3_bucket_name)
|
29
|
-
end
|
30
|
-
end
|
31
|
-
|
32
23
|
def self.upload_files(s3, config, site_dir)
|
33
24
|
changed_files, new_files = DiffHelper.resolve_files_to_upload(
|
34
25
|
s3.buckets[config['s3_bucket']], site_dir)
|
metadata
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: jekyll-s3
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 2.
|
4
|
+
version: 2.2.0
|
5
5
|
prerelease:
|
6
6
|
platform: ruby
|
7
7
|
authors:
|
@@ -92,6 +92,22 @@ dependencies:
|
|
92
92
|
- - '='
|
93
93
|
- !ruby/object:Gem::Version
|
94
94
|
version: '1.19'
|
95
|
+
- !ruby/object:Gem::Dependency
|
96
|
+
name: configure-s3-website
|
97
|
+
requirement: !ruby/object:Gem::Requirement
|
98
|
+
none: false
|
99
|
+
requirements:
|
100
|
+
- - ~>
|
101
|
+
- !ruby/object:Gem::Version
|
102
|
+
version: 1.0.0
|
103
|
+
type: :runtime
|
104
|
+
prerelease: false
|
105
|
+
version_requirements: !ruby/object:Gem::Requirement
|
106
|
+
none: false
|
107
|
+
requirements:
|
108
|
+
- - ~>
|
109
|
+
- !ruby/object:Gem::Version
|
110
|
+
version: 1.0.0
|
95
111
|
- !ruby/object:Gem::Dependency
|
96
112
|
name: rspec
|
97
113
|
requirement: !ruby/object:Gem::Requirement
|