gritano 0.5.0 → 0.5.1

Sign up to get free protection for your applications and to get access to all the features.
@@ -1,4 +1,4 @@
1
- = Gritano v0.5.0
1
+ = Gritano v0.5.1
2
2
 
3
3
  Gritano is the simplest way to configure a git server over ssh. You can create repositories and manage user access using this practical tool.
4
4
 
@@ -85,9 +85,9 @@ Starting from Gritano 0.3.0, administrators can execute commands via ssh:
85
85
 
86
86
  $ ssh git@hot.com admin:repo:list
87
87
 
88
- For more information, execute
88
+ == For more Information
89
89
 
90
- $ ssh git@host.com admin:help
90
+ http://igorbonadio.com.br/gritano/
91
91
 
92
92
  == Contributing to Gritano
93
93
 
data/Rakefile CHANGED
@@ -15,7 +15,7 @@ require 'jeweler'
15
15
  Jeweler::Tasks.new do |gem|
16
16
  # gem is a Gem::Specification... see http://docs.rubygems.org/read/chapter/20 for more options
17
17
  gem.name = "gritano"
18
- gem.homepage = "http://github.com/igorbonadio/gritano"
18
+ gem.homepage = "http://igorbonadio.com.br/gritano"
19
19
  gem.license = "MIT"
20
20
  gem.summary = %Q{Gritano is a tool to configure your git server over ssh}
21
21
  gem.description = %Q{Gritano is the simplest way to configure your git server over ssh. You can create repositories and manage user access.}
data/TODO CHANGED
@@ -1,4 +1,5 @@
1
- v1.0.0
1
+ v0.6.0
2
+ - renomear gritano-check
2
3
  - melhorar o instalador/updater
3
4
  - escolha de db
4
5
  - escolha de pasta dos repos
data/VERSION CHANGED
@@ -1 +1 @@
1
- 0.5.0
1
+ 0.5.1
@@ -3,4 +3,4 @@ $:.unshift File.join(File.dirname(__FILE__), *%w[.. lib])
3
3
 
4
4
  require 'gritano'
5
5
 
6
- puts Gritano::CLI::check(ENV['SSH_ORIGINAL_COMMAND'].split(' '), ARGV[0])
6
+ puts Gritano::CLI::check((ENV['SSH_ORIGINAL_COMMAND'] || '').split(' '), ARGV[0])
@@ -58,7 +58,7 @@ Feature: Console operations
58
58
  Then CLI should return "<result>"
59
59
  Examples:
60
60
  | command | result |
61
- | version | v0.4.1 |
61
+ | version | v0.5.0 |
62
62
  | user:add jose | User jose added. |
63
63
  | user:key:add igorbonadio marvin | Key added successfully. |
64
64
  | user:key:rm igorbonadio eva | Key removed successfully. |
@@ -99,7 +99,7 @@ Feature: Console operations
99
99
  Then CLI should return "<result>"
100
100
  Examples:
101
101
  | command | result |
102
- | version | v0.4.1 |
102
+ | version | v0.5.0 |
103
103
  | key:add keyname | Key added successfully. |
104
104
  | key:rm eva | Key removed successfully. |
105
105
  | key:rm keyname | error: Key could not be removed. |
@@ -143,7 +143,7 @@ Feature: Console operations
143
143
  Then CLI should return "<result>"
144
144
  Examples:
145
145
  | command | result |
146
- | version | v0.4.1 |
146
+ | version | v0.5.0 |
147
147
  | key:add keyname | Key added successfully. |
148
148
  | key:rm hal | Key removed successfully. |
149
149
  | key:rm keyname | error: Key could not be removed. |
@@ -10,4 +10,4 @@
10
10
  ssh git@host.com admin:help
11
11
 
12
12
  --
13
- v0.4.1
13
+ v0.5.0
@@ -24,4 +24,4 @@
24
24
  test repo:write:rm reponame.git username
25
25
 
26
26
  --
27
- v0.4.1
27
+ v0.5.0
@@ -24,4 +24,4 @@
24
24
  gritano repo:write:rm reponame.git username
25
25
 
26
26
  --
27
- v0.4.1
27
+ v0.5.0
@@ -1,7 +1,7 @@
1
1
  Given /^I start the gritano\-check console with "(.*?)"$/ do |login|
2
2
  stdin = double()
3
3
  stdin.stub(:read).and_return("Your SSHKEY here...")
4
- @console = Gritano::Console::Check.new(stdin, '.', 'tmp')
4
+ @console = Gritano::Console::Remote.new(stdin, '.', 'tmp')
5
5
  @login = login
6
6
  end
7
7
 
@@ -5,11 +5,11 @@
5
5
 
6
6
  Gem::Specification.new do |s|
7
7
  s.name = "gritano"
8
- s.version = "0.5.0"
8
+ s.version = "0.5.1"
9
9
 
10
10
  s.required_rubygems_version = Gem::Requirement.new(">= 0") if s.respond_to? :required_rubygems_version=
11
11
  s.authors = ["Igor Bonadio"]
12
- s.date = "2012-12-22"
12
+ s.date = "2012-12-29"
13
13
  s.description = "Gritano is the simplest way to configure your git server over ssh. You can create repositories and manage user access."
14
14
  s.email = "igorbonadio@gmail.com"
15
15
  s.executables = ["gritano", "gritano-check"]
@@ -63,10 +63,10 @@ Gem::Specification.new do |s|
63
63
  "lib/gritano/cli.rb",
64
64
  "lib/gritano/console.rb",
65
65
  "lib/gritano/console/base.rb",
66
- "lib/gritano/console/check.rb",
67
66
  "lib/gritano/console/executor.rb",
68
67
  "lib/gritano/console/gritano.rb",
69
68
  "lib/gritano/console/installer.rb",
69
+ "lib/gritano/console/remote.rb",
70
70
  "lib/gritano/models.rb",
71
71
  "lib/gritano/models/key.rb",
72
72
  "lib/gritano/models/permission.rb",
@@ -80,7 +80,7 @@ Gem::Specification.new do |s|
80
80
  "spec/model_user_spec.rb",
81
81
  "spec/spec_helper.rb"
82
82
  ]
83
- s.homepage = "http://github.com/igorbonadio/gritano"
83
+ s.homepage = "http://igorbonadio.com.br/gritano"
84
84
  s.licenses = ["MIT"]
85
85
  s.require_paths = ["lib"]
86
86
  s.rubygems_version = "1.8.24"
@@ -1,8 +1,7 @@
1
1
  module Gritano
2
2
  module CLI
3
- def CLI.execute(cmd, stdin = STDIN, home_dir = Etc.getpwuid.dir, repo_dir = Etc.getpwuid.dir)
4
- Gritano::Console.remote_console(false)
5
- console = Gritano::Console::Gritano.new(stdin, home_dir, repo_dir)
3
+
4
+ def CLI._execute(cmd, console)
6
5
  begin
7
6
  output = console.execute(cmd)
8
7
  if output[0]
@@ -15,19 +14,14 @@ module Gritano
15
14
  end
16
15
  end
17
16
 
17
+ def CLI.execute(cmd, stdin = STDIN, home_dir = Etc.getpwuid.dir, repo_dir = Etc.getpwuid.dir)
18
+ Gritano::Console.remote_console(false)
19
+ _execute(cmd, Gritano::Console::Gritano.new(stdin, home_dir, repo_dir))
20
+ end
21
+
18
22
  def CLI.check(cmd, login, stdin = STDIN, home_dir = Etc.getpwuid.dir, repo_dir = Etc.getpwuid.dir)
19
23
  Gritano::Console.remote_console(true)
20
- console = Gritano::Console::Check.new(stdin, home_dir, repo_dir)
21
- begin
22
- output = console.execute(cmd + [login])
23
- if output[0]
24
- output[1]
25
- else
26
- "error: #{output[1]}"
27
- end
28
- rescue
29
- console.execute(["help"])[1]
30
- end
24
+ _execute(cmd + [login], Gritano::Console::Remote.new(stdin, home_dir, repo_dir))
31
25
  end
32
26
  end
33
27
  end
@@ -2,20 +2,20 @@ require File.join(ROOT_PATH, 'gritano/console/base')
2
2
  require File.join(ROOT_PATH, 'gritano/console/executor')
3
3
  require File.join(ROOT_PATH, 'gritano/console/installer')
4
4
  require File.join(ROOT_PATH, 'gritano/console/gritano')
5
- require File.join(ROOT_PATH, 'gritano/console/check')
5
+ require File.join(ROOT_PATH, 'gritano/console/remote')
6
6
 
7
7
  module Gritano
8
8
  module Console
9
9
  def Console.remote_console(remote)
10
10
  if remote
11
11
  Base.bin_name = "ssh git@host.com admin:"
12
- Check.bin_name = "ssh git@host.com "
12
+ Remote.bin_name = "ssh git@host.com "
13
13
  Executor.bin_name = "ssh git@host.com admin:"
14
14
  Gritano.bin_name = "ssh git@host.com admin:"
15
15
  Installer.bin_name = "ssh git@host.com admin:"
16
16
  else
17
17
  Base.bin_name = "gritano "
18
- Check.bin_name = "gritano "
18
+ Remote.bin_name = "gritano "
19
19
  Executor.bin_name = "gritano "
20
20
  Gritano.bin_name = "gritano "
21
21
  Installer.bin_name = "gritano "
@@ -1,6 +1,6 @@
1
1
  module Gritano
2
2
  module Console
3
- class Check < Base
3
+ class Remote < Base
4
4
 
5
5
  def initialize(stdin = STDIN, home_dir = Etc.getpwuid.dir, repo_path = Etc.getpwuid.dir)
6
6
  @stdin = stdin
@@ -24,7 +24,7 @@ module Gritano
24
24
  end
25
25
 
26
26
  add_command "help" do |args|
27
- [true, Check.help]
27
+ [true, Remote.help]
28
28
  end
29
29
 
30
30
  add_command "repo:list" do |args|
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: gritano
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.5.0
4
+ version: 0.5.1
5
5
  prerelease:
6
6
  platform: ruby
7
7
  authors:
@@ -9,7 +9,7 @@ authors:
9
9
  autorequire:
10
10
  bindir: bin
11
11
  cert_chain: []
12
- date: 2012-12-22 00:00:00.000000000 Z
12
+ date: 2012-12-29 00:00:00.000000000 Z
13
13
  dependencies:
14
14
  - !ruby/object:Gem::Dependency
15
15
  name: activerecord
@@ -243,10 +243,10 @@ files:
243
243
  - lib/gritano/cli.rb
244
244
  - lib/gritano/console.rb
245
245
  - lib/gritano/console/base.rb
246
- - lib/gritano/console/check.rb
247
246
  - lib/gritano/console/executor.rb
248
247
  - lib/gritano/console/gritano.rb
249
248
  - lib/gritano/console/installer.rb
249
+ - lib/gritano/console/remote.rb
250
250
  - lib/gritano/models.rb
251
251
  - lib/gritano/models/key.rb
252
252
  - lib/gritano/models/permission.rb
@@ -260,7 +260,7 @@ files:
260
260
  - spec/model_user_spec.rb
261
261
  - spec/spec_helper.rb
262
262
  - TODO
263
- homepage: http://github.com/igorbonadio/gritano
263
+ homepage: http://igorbonadio.com.br/gritano
264
264
  licenses:
265
265
  - MIT
266
266
  post_install_message:
@@ -275,7 +275,7 @@ required_ruby_version: !ruby/object:Gem::Requirement
275
275
  version: '0'
276
276
  segments:
277
277
  - 0
278
- hash: 1372008296266253540
278
+ hash: 3374500696150512185
279
279
  required_rubygems_version: !ruby/object:Gem::Requirement
280
280
  none: false
281
281
  requirements: