git-multirepo 1.0.0.beta4 → 1.0.0.beta5

Sign up to get free protection for your applications and to get access to all the features.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA1:
3
- metadata.gz: bc4fcacdeda46d9bd6dbaf5f70cfdfd1e9a42752
4
- data.tar.gz: de1ffba314e943dcd1357dd7c23c8a0a5f9c4138
3
+ metadata.gz: 2a385cf0508d894743f411951c9c59f299339ff0
4
+ data.tar.gz: c87ad0b8f432703830a3c6355f216b9b053e9fc2
5
5
  SHA512:
6
- metadata.gz: 4d06277c5724ddd505c7d41219ac947111e6c3184def6b05b7069ffe85378e0c77e4d267fdefdf81df366a2f55190a1ec318ef6b10701e55cd47acfcedaeaf69
7
- data.tar.gz: e66429331d6bdd52a8c86010685fa803a20ff2cf261acba1679b4fc84f1f979c5ca3f0d1d53eaeae6b28d3b4ab136e7f8a8074e2d1ac95e0f9603f995293319e
6
+ metadata.gz: df7eab33e7bbd773aeb420fee0e752e650876531e685b15e7aba5b3d738be2eef119af3a11dfc3c8970b4fc18b7baee13a4fa92807ba817fce8c7d6b4d3879bf
7
+ data.tar.gz: 9c7f99a04596b8055b2437c6b207a2e89137459783350b61069df695dc6b4938f5250d487cb8bd0090c310ac28767cb6ef29c17fe61d955cc23b2bd3a577d123
data/README.md CHANGED
@@ -1,3 +1,5 @@
1
+ ![git-multirepo](images/logo.png)
2
+
1
3
  # git-multirepo
2
4
 
3
5
  Track multiple Git repositories side-by-side.
data/images/logo.png ADDED
Binary file
data/lib/info.rb CHANGED
@@ -1,5 +1,5 @@
1
1
  module MultiRepo
2
2
  NAME = "git-multirepo"
3
- VERSION = "1.0.0.beta4"
3
+ VERSION = "1.0.0.beta5"
4
4
  DESCRIPTION = "Track multiple Git repositories side-by-side."
5
5
  end
@@ -11,6 +11,11 @@ module MultiRepo
11
11
  super
12
12
  end
13
13
 
14
+ def validate!
15
+ super
16
+ help! "You must specify a branch or commit id to checkout" unless @ref
17
+ end
18
+
14
19
  def run
15
20
  super
16
21
  ensure_multirepo_initialized
@@ -21,7 +26,7 @@ module MultiRepo
21
26
  Console.log_step("Checking out #{@ref} and its dependencies...")
22
27
 
23
28
  unless main_repo.is_clean?
24
- raise "Can't checkout #{@ref} because the main repo contains uncommitted changes"
29
+ raise MultiRepoException, "Can't checkout #{@ref} because the main repo contains uncommitted changes"
25
30
  end
26
31
 
27
32
  unless main_repo.checkout(@ref)
@@ -37,7 +42,7 @@ module MultiRepo
37
42
 
38
43
  if Utils.warn_of_uncommitted_changes(ConfigFile.load)
39
44
  main_repo.checkout(initial_revision)
40
- raise "'#{e.path}' contains uncommitted changes. Checkout reverted."
45
+ raise MultiRepoException, "'#{e.path}' contains uncommitted changes. Checkout reverted."
41
46
  end
42
47
 
43
48
  config_entries = ConfigFile.load # Load the post-checkout config entries, which might be different than pre-checkout
@@ -13,7 +13,7 @@ module MultiRepo
13
13
  editor = `echo ${FCEDIT:-${VISUAL:-${EDITOR:-vi}}}`.strip
14
14
  system(editor, ".multirepo")
15
15
  elsif OS.windows?
16
- raise "The edit command is not implemented on Window yet."
16
+ raise MultiRepoException, "The edit command is not implemented on Window yet."
17
17
  end
18
18
  rescue MultiRepoException => e
19
19
  Console.log_error(e.message)
@@ -32,8 +32,8 @@ module MultiRepo
32
32
  end
33
33
 
34
34
  def self.is_inside_git_repo(path)
35
- Dir.exist?("#{path}/.git")
36
- #return (Git.run_in_working_dir(path, "rev-parse --is-inside-work-tree", false).strip == "true") # Can't silence output?
35
+ return false unless Dir.exist?("#{path}/.git")
36
+ return Git.run_in_working_dir(path, "rev-parse --is-inside-work-tree", false).strip == "true"
37
37
  end
38
38
  end
39
39
  end
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: git-multirepo
3
3
  version: !ruby/object:Gem::Version
4
- version: 1.0.0.beta4
4
+ version: 1.0.0.beta5
5
5
  platform: ruby
6
6
  authors:
7
7
  - Michaël Fortin
@@ -119,6 +119,7 @@ files:
119
119
  - Rakefile
120
120
  - bin/multi
121
121
  - git-multirepo.gemspec
122
+ - images/logo.png
122
123
  - lib/commands.rb
123
124
  - lib/git-multirepo.rb
124
125
  - lib/info.rb