s3gb 0.1.1 → 0.1.2
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 +1 -2
- data/VERSION +1 -1
- data/lib/s3gb/jgit.rb +3 -2
- data/s3gb.gemspec +1 -1
- metadata +2 -2
data/Readme.md
CHANGED
@@ -12,7 +12,6 @@ Enter your config: [Your S3 keys](https://www.amazon.com/ap/signin?openid.ns=htt
|
|
12
12
|
secretAccessKey: --your--key--
|
13
13
|
acl: private
|
14
14
|
strategy: jgit
|
15
|
-
cache: ~/.s3gb_cache
|
16
15
|
sync:
|
17
16
|
- ~/.ssh
|
18
17
|
- ~/bin
|
@@ -27,7 +26,7 @@ Then:
|
|
27
26
|
|
28
27
|
- create the bucket using e.g. S3Fox AND add a .git folder to it
|
29
28
|
- `sudo s3gb --install` to install dependencies for your chosen strategy
|
30
|
-
- `s3gb --backup`
|
29
|
+
- `s3gb --backup` and add it to your cron with e.g. `0 0 * * * s3gb --backup`
|
31
30
|
|
32
31
|
Author
|
33
32
|
======
|
data/VERSION
CHANGED
@@ -1 +1 @@
|
|
1
|
-
0.1.
|
1
|
+
0.1.2
|
data/lib/s3gb/jgit.rb
CHANGED
@@ -28,10 +28,11 @@ class S3gb
|
|
28
28
|
end
|
29
29
|
|
30
30
|
def ensure_jgit_repo
|
31
|
+
# this only works if a public repo already exists
|
31
32
|
return if File.exist? "#{cache_dir}/.git"
|
32
|
-
out = cmd "cd #{File.dirname(cache_dir)} && jgit clone -o s3 #{public_s3_url} #{File.basename cache_dir}
|
33
|
+
out = cmd "cd #{File.dirname(cache_dir)} && jgit clone -o s3 #{public_s3_url} #{File.basename cache_dir}"
|
33
34
|
return if out.include?('COMPLETE')
|
34
|
-
cmd "cd #{cache_dir} && git init
|
35
|
+
cmd "cd #{cache_dir} && git init ; git remote rm s3 ; git remote add s3 #{s3_url}"
|
35
36
|
end
|
36
37
|
|
37
38
|
def s3_url
|
data/s3gb.gemspec
CHANGED