gito 0.4.11 → 0.4.12

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: d1b89b0d99b76e03a3c147e7fcbb18c7c4183746
4
- data.tar.gz: 04cde5b4dd4a9ede46f467a92d83ed3a44bb8945
3
+ metadata.gz: 55cdd09aa85faa95b08298e5d0f50ffd9e429b2d
4
+ data.tar.gz: 2987b85e6cfe4f323c1092f5d00b85c9fa54fbf7
5
5
  SHA512:
6
- metadata.gz: d656ca79d2bed0ec63ae3a57738a6c338823d71508385831b4ce057f07435b72c9de34564640eddd0306e25300f37ac38b7180680800023e775acefe0bdebe59
7
- data.tar.gz: ff916ae892e62d49b04a6150b1f25865b5ef41736eac8961fd3c8ca73f4835bcebffba8603ba21b6a1fa4759fd6da9fa89421249e1186057e3b4ef95a6b9e454
6
+ metadata.gz: 022cd0ec94dedc1003ad9e0e8821fe884172f2661d77b295be4a7db02e9b05d5ac047b8f6e7131130747647c85d4b2e388f6f4be84d95a83eb64f3f2c4d38137
7
+ data.tar.gz: ed49f4328a8c73245b5ce8ad2e6ac3d51af3a1c83a75f771a4646b63deb790507266b38a09bbb773fbaf7c30d7b887787d28d09212da338aab616d3e1d489e12
@@ -119,8 +119,8 @@ class MainApp
119
119
  project.open_folder
120
120
  end
121
121
 
122
+ # Install dependencies
122
123
  unless @options[:dryrun]
123
- # Install dependencies
124
124
  project.install_dependencies
125
125
  end
126
126
 
@@ -74,11 +74,15 @@ class Project
74
74
  starts_with_git = @base_url.split(//).first(4).join.eql? 'git@'
75
75
  ends_with_git = @base_url.split(//).last(4).join.eql? '.git'
76
76
 
77
+ return "git@github.com:#{@base_url}.git" if @base_url.split('/').length == 2
78
+
77
79
  # ends with git but doesnt start with git
78
80
  return @base_url if ends_with_git && !starts_with_git
79
81
 
82
+ user_repo_pair = @base_url.split('https://github.com/').last
83
+
80
84
  # ends with git but doesnt start with git
81
- return "#{@base_url}.git" if !ends_with_git && !starts_with_git
85
+ return "git@github.com:#{user_repo_pair}.git" if !ends_with_git && !starts_with_git
82
86
 
83
87
  @base_url
84
88
  end
@@ -1,3 +1,3 @@
1
1
  module Gito
2
- VERSION = '0.4.11'
2
+ VERSION = '0.4.12'
3
3
  end
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: gito
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.4.11
4
+ version: 0.4.12
5
5
  platform: ruby
6
6
  authors:
7
7
  - cesar ferreira
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2017-05-28 00:00:00.000000000 Z
11
+ date: 2017-07-26 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: rake
@@ -128,7 +128,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
128
128
  version: '0'
129
129
  requirements: []
130
130
  rubyforge_project:
131
- rubygems_version: 2.6.12
131
+ rubygems_version: 2.6.11
132
132
  signing_key:
133
133
  specification_version: 4
134
134
  summary: git helper tool to clone/open/auto-install/edit a git project with a one-liner