acts_as_git 0.2.0 → 0.2.1
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/acts_as_git.gemspec +1 -1
- data/lib/acts_as_git.rb +2 -2
- metadata +1 -1
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA1:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: e421566e129385aa04171597fc13c53a6f666872
|
4
|
+
data.tar.gz: 80a0d9463d870f31a3782dd244ef284f03bbe09b
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 378c4ecbd9dbc88bb387505116af6a8119a782f5402af11805b4e9fa28f268e5ce6a3b88e11efd2ab13b93cfaadddf0da38e46f92ce3eb50d6d83e2f66e37c1e
|
7
|
+
data.tar.gz: 131f5dc0bafe1499e740b75394791ca3c914317fd71290b2024de3be0f416eb1b17946c3decfbde5f9cede4e9118248e4c313966e37e1bfa6a3deab5eabf700b
|
data/acts_as_git.gemspec
CHANGED
@@ -8,7 +8,7 @@ Gem::Specification.new do |s|
|
|
8
8
|
s.homepage = "https://github.com/rail44/acts_as_git"
|
9
9
|
s.summary = "Make your field act as a git repo"
|
10
10
|
s.description = "Make your field act as a git repo. Save the content to a file, and load the content from a file."
|
11
|
-
s.version = '0.2.
|
11
|
+
s.version = '0.2.1'
|
12
12
|
s.date = Time.now.strftime("%Y-%m-%d")
|
13
13
|
|
14
14
|
s.extra_rdoc_files = Dir["*.rdoc"]
|
data/lib/acts_as_git.rb
CHANGED
@@ -98,9 +98,9 @@ module ActsAsGit
|
|
98
98
|
def self.sync
|
99
99
|
cred = Rugged::Credentials::SshKeyFromAgent.new(username: 'git')
|
100
100
|
@@origin.fetch(credentials: cred)
|
101
|
-
branch = @@repo.branches["master"]
|
102
101
|
@@repo.checkout('origin/master', :strategy => :force)
|
103
|
-
@@repo.branches
|
102
|
+
branch = @@repo.branches["master"]
|
103
|
+
@@repo.branches.delete(branch) if branch
|
104
104
|
@@repo.create_branch('master')
|
105
105
|
@@repo.checkout('master', :strategy => :force)
|
106
106
|
end
|