enzyme 1.0.0.beta02 → 1.0.0.beta03
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/VERSION +1 -1
- data/lib/commands/config.rb +26 -12
- data/lib/commands/create.rb +36 -21
- data/lib/commands/join.rb +27 -12
- data/lib/commands/sync.rb +77 -28
- data/lib/enzyme.rb +25 -22
- data/lib/errors.rb +3 -0
- data/lib/setup.rb +1 -1
- metadata +13 -13
data/VERSION
CHANGED
@@ -1 +1 @@
|
|
1
|
-
1.0.0.
|
1
|
+
1.0.0.beta03
|
data/lib/commands/config.rb
CHANGED
@@ -3,7 +3,7 @@ require 'enzyme'
|
|
3
3
|
module Config extend self
|
4
4
|
|
5
5
|
def run()
|
6
|
-
file = ['--global', '--organisation', '--project'].
|
6
|
+
file = ARGV.delete((ARGV & ['--global', '--organisation', '--project']).first)
|
7
7
|
ARGV.each { |x| raise UnknownOption.new(x) if x.start_with?("-") }
|
8
8
|
key = ARGV.shift
|
9
9
|
value = ARGV.shift
|
@@ -12,7 +12,7 @@ module Config extend self
|
|
12
12
|
if file.nil?
|
13
13
|
file = $system_settings.config.project.exists ? "project" : "global"
|
14
14
|
else
|
15
|
-
file = file.to_s
|
15
|
+
file = file.to_s[/[a-z]+$/]
|
16
16
|
end
|
17
17
|
|
18
18
|
raise ConfigFileNotFound.new($system_settings.config[file].path) unless $system_settings.config[file].exists
|
@@ -24,20 +24,21 @@ module Config extend self
|
|
24
24
|
puts "Set '#{key}' to '#{value}' in '#{path}'."
|
25
25
|
else
|
26
26
|
val = get(key, path)
|
27
|
-
if val.
|
27
|
+
if val.nil?
|
28
|
+
puts "<nil>"
|
29
|
+
elsif val.is_a?(Array) || val.is_a?(Hash)
|
28
30
|
puts val.to_hash.to_yaml
|
29
31
|
else
|
30
32
|
puts val.to_s
|
31
33
|
end
|
32
34
|
end
|
33
|
-
puts
|
34
35
|
end
|
35
36
|
|
36
37
|
# Gets the value of a given setting.
|
37
38
|
# - key: The setting to get.
|
38
39
|
# - path: The path to the config file to get the setting from.
|
39
40
|
def get(key, path)
|
40
|
-
s =
|
41
|
+
s = path ? (YAML.load_file(path) || {}) : $settings
|
41
42
|
key.to_s.split('.').each do |o|
|
42
43
|
return nil if s[o].nil?
|
43
44
|
s = s[o]
|
@@ -82,17 +83,30 @@ end
|
|
82
83
|
|
83
84
|
Enzyme.register('config', Config) do
|
84
85
|
puts "#{$format.bold}SYNOPSIS#{$format.normal}"
|
85
|
-
puts '
|
86
|
+
puts ' enzyme config [--global|--organisation|--project]'
|
87
|
+
puts ' enzyme config <key> [--global|--organisation|--project]'
|
88
|
+
puts ' enzyme config <key> <value> [--global|--organisation|--project]'
|
89
|
+
puts
|
90
|
+
puts "#{$format.bold}DESCRIPTION#{$format.normal}"
|
91
|
+
puts " In its first form the config command dumps the settings."
|
92
|
+
puts
|
93
|
+
puts " In its second form the config command prints the value of a given key."
|
94
|
+
puts
|
95
|
+
puts " In its third form the config command sets the value of a given key."
|
86
96
|
puts
|
87
97
|
puts "#{$format.bold}EXAMPLES#{$format.normal}"
|
88
|
-
puts
|
98
|
+
puts " 1. Get the value of the 'short_name' setting:"
|
99
|
+
puts
|
100
|
+
puts " $ enzyme config short_name"
|
101
|
+
puts " dave"
|
89
102
|
puts
|
90
|
-
puts
|
91
|
-
puts ' > dave'
|
103
|
+
puts " 2. Set the value of the 'short_name' setting:"
|
92
104
|
puts
|
93
|
-
puts
|
105
|
+
puts " $ enzyme config short_name jill"
|
106
|
+
puts " Set 'short_name' to 'jill' in '/Users/jill/.enzyme.yml'."
|
94
107
|
puts
|
95
|
-
puts '
|
96
|
-
puts ' > my_project'
|
108
|
+
puts " 3. Get the value of the 'sync.projects_directory' setting in the organisation config file:"
|
97
109
|
puts
|
110
|
+
puts " $ enzyme config sync.projects_directory --organisation"
|
111
|
+
puts " Projects"
|
98
112
|
end
|
data/lib/commands/create.rb
CHANGED
@@ -26,75 +26,90 @@ module Create extend self
|
|
26
26
|
# If the project already exists, raise an error.
|
27
27
|
raise ProjectAlreadyExists.new(directory) if File.directory?(directory)
|
28
28
|
|
29
|
+
puts "Creating remote project at '#{directory}'..."
|
30
|
+
|
29
31
|
create_repo directory, [ "*", "!.enzyme.yml", "!.gitignore" ]
|
32
|
+
print "."
|
30
33
|
Config.write("#{directory}/.enzyme.yml", { "project_name" => project_name })
|
34
|
+
print "."
|
31
35
|
commit_repo directory
|
36
|
+
print "."
|
32
37
|
detach_repo directory
|
38
|
+
print "."
|
33
39
|
|
34
40
|
create_repo "#{directory}/resources"
|
41
|
+
print "."
|
35
42
|
commit_repo "#{directory}/resources"
|
43
|
+
print "."
|
36
44
|
detach_repo "#{directory}/resources"
|
45
|
+
print "."
|
37
46
|
|
38
47
|
create_repo "#{directory}/production"
|
48
|
+
print "."
|
39
49
|
commit_repo "#{directory}/production"
|
50
|
+
print "."
|
40
51
|
detach_repo "#{directory}/production"
|
41
|
-
|
42
|
-
puts "Created remote project at:"
|
43
|
-
puts
|
44
|
-
puts " #{directory}"
|
45
52
|
puts
|
53
|
+
|
54
|
+
puts "Done."
|
46
55
|
end
|
47
56
|
|
48
57
|
def create_repo(path, gitignore=[])
|
49
58
|
# Create the project's directory.
|
50
|
-
system "mkdir -p #{path}
|
59
|
+
system "mkdir -p #{path} &> /dev/null"
|
51
60
|
|
52
61
|
# Change into the directory.
|
53
|
-
system "cd #{path}
|
62
|
+
system "cd #{path} &> /dev/null"
|
54
63
|
Dir.chdir(path)
|
55
64
|
|
56
65
|
# Gitify.
|
57
|
-
system "git init
|
66
|
+
system "git init &> /dev/null"
|
58
67
|
system "echo '#{gitignore.join("\n")}' > .gitignore"
|
59
68
|
end
|
60
69
|
|
61
70
|
def commit_repo(path)
|
62
71
|
# Create the project's directory.
|
63
|
-
system "mkdir -p #{path}
|
72
|
+
system "mkdir -p #{path} &> /dev/null"
|
64
73
|
|
65
74
|
# Change into the directory.
|
66
|
-
system "cd #{path}
|
75
|
+
system "cd #{path} &> /dev/null"
|
67
76
|
Dir.chdir(path)
|
68
77
|
|
69
78
|
# Gitify.
|
70
|
-
system "git add .
|
71
|
-
system "git commit -m 'Initial commit.'
|
79
|
+
system "git add . &> /dev/null"
|
80
|
+
system "git commit -m 'Initial commit.' &> /dev/null"
|
72
81
|
end
|
73
82
|
|
74
83
|
def detach_repo(path)
|
75
84
|
# Create the project's directory.
|
76
|
-
system "mkdir -p #{path}
|
85
|
+
system "mkdir -p #{path} &> /dev/null"
|
77
86
|
|
78
87
|
# Change into the directory.
|
79
|
-
system "cd #{path}
|
88
|
+
system "cd #{path} &> /dev/null"
|
80
89
|
Dir.chdir(path)
|
81
90
|
|
82
91
|
# Gitify.
|
83
|
-
system "git checkout -q --detach
|
92
|
+
system "git checkout -q --detach &> /dev/null"
|
84
93
|
end
|
85
94
|
|
86
95
|
end
|
87
96
|
|
88
97
|
Enzyme.register('create', Create) do
|
89
98
|
puts "#{$format.bold}SYNOPSIS#{$format.normal}"
|
90
|
-
puts
|
99
|
+
puts " enzyme create <project_name> [--skip-join]"
|
100
|
+
puts
|
101
|
+
puts "#{$format.bold}DESCRIPTION#{$format.normal}"
|
102
|
+
puts " Creates a project on the sync server and (if --skip-join hasn't been passed) joins the"
|
103
|
+
puts " project using the `enzyme join` command."
|
91
104
|
puts
|
92
105
|
puts "#{$format.bold}EXAMPLES#{$format.normal}"
|
93
|
-
puts
|
94
|
-
puts ' '
|
95
|
-
puts ' Created local project at:'
|
96
|
-
puts ' '
|
97
|
-
puts ' `/Users/jane/Projects/example-project`'
|
98
|
-
puts ' '
|
106
|
+
puts " Creating a project called 'abc':"
|
99
107
|
puts
|
108
|
+
puts " $ enzyme create abc"
|
109
|
+
puts " Creating remote project at '/Volumes/Shared/Projects/abc'..."
|
110
|
+
puts " ........"
|
111
|
+
puts " Done."
|
112
|
+
puts " Joining the 'abc' project at '/Volumes/Shared/Projects/abc'..."
|
113
|
+
puts " ......"
|
114
|
+
puts " Done."
|
100
115
|
end
|
data/lib/commands/join.rb
CHANGED
@@ -30,30 +30,45 @@ module Join extend self
|
|
30
30
|
# If the remote project directory doesn't exists, raise an error.
|
31
31
|
raise CannotFindProject.new(remote_directory) unless File.directory?(remote_directory)
|
32
32
|
|
33
|
+
puts "Joining the '#{project_name}' project at '#{local_directory}'..."
|
34
|
+
|
33
35
|
# Clone the resources and production directories.
|
34
|
-
system "git clone -q #{remote_directory} #{local_directory}"
|
35
|
-
|
36
|
-
system "git
|
37
|
-
|
38
|
-
system "git clone -q #{remote_directory}/
|
39
|
-
|
36
|
+
system "git clone -q #{remote_directory} #{local_directory} &> /dev/null"
|
37
|
+
print "."
|
38
|
+
system "cd #{local_directory}; git checkout -q master &> /dev/null;"
|
39
|
+
print "."
|
40
|
+
system "git clone -q #{remote_directory}/resources #{local_directory}/resources &> /dev/null"
|
41
|
+
print "."
|
42
|
+
system "cd #{local_directory}/resources; git checkout -q master &> /dev/null;"
|
43
|
+
print "."
|
44
|
+
system "git clone -q #{remote_directory}/production #{local_directory}/production &> /dev/null"
|
45
|
+
print "."
|
46
|
+
system "cd #{local_directory}/production; git checkout -q master &> /dev/null;"
|
47
|
+
print "."
|
40
48
|
|
41
49
|
# Create the user's production directory unless it's already there.
|
42
50
|
system "mkdir #{local_directory}/production/#{$settings.short_name}" unless File.directory?("#{local_directory}/production/#{$settings.short_name}")
|
43
|
-
|
44
|
-
|
45
|
-
puts
|
46
|
-
puts " #{local_directory}"
|
51
|
+
print "."
|
52
|
+
system "touch #{local_directory}/production/#{$settings.short_name}/.gitkeep" unless File.exists?("#{local_directory}/production/#{$settings.short_name}/.gitkeep")
|
47
53
|
puts
|
54
|
+
|
55
|
+
puts "Done."
|
48
56
|
end
|
49
57
|
|
50
58
|
end
|
51
59
|
|
52
60
|
Enzyme.register('join', Join) do
|
53
61
|
puts "#{$format.bold}SYNOPSIS#{$format.normal}"
|
54
|
-
puts
|
62
|
+
puts " enzyme join <project_name>"
|
63
|
+
puts
|
64
|
+
puts "#{$format.bold}DESCRIPTION#{$format.normal}"
|
65
|
+
puts " Joins a project by creating a local version of a project from the sync server."
|
55
66
|
puts
|
56
67
|
puts "#{$format.bold}EXAMPLES#{$format.normal}"
|
57
|
-
puts
|
68
|
+
puts " Joining a project called 'abc':"
|
58
69
|
puts
|
70
|
+
puts " $ enzyme join abc"
|
71
|
+
puts " Joining the 'abc' project at '/Volumes/Shared/Projects/abc'..."
|
72
|
+
puts " ......"
|
73
|
+
puts " Done."
|
59
74
|
end
|
data/lib/commands/sync.rb
CHANGED
@@ -11,67 +11,116 @@ module Sync extend self
|
|
11
11
|
|
12
12
|
raise ArgumentOrSettingMissing.new("project_name", "project_name") unless project_name
|
13
13
|
raise SettingMissing.new("projects_directory") unless $settings.projects_directory
|
14
|
+
raise SettingMissing.new("short_name") unless $settings.short_name
|
14
15
|
|
15
16
|
directory = "#{$settings.projects_directory}/#{project_name}"
|
16
17
|
|
17
18
|
raise CannotFindProject.new(directory) unless File.directory?(directory)
|
18
19
|
|
20
|
+
puts "Syncing project '#{project_name}' at '#{directory}'..."
|
21
|
+
|
19
22
|
# BASE
|
20
23
|
|
21
24
|
system "cd #{directory}"
|
22
25
|
Dir.chdir("#{directory}")
|
26
|
+
print "."
|
23
27
|
|
24
|
-
system "git add .enzyme.yml
|
25
|
-
|
26
|
-
system "git
|
27
|
-
|
28
|
+
system "git add .enzyme.yml &> /dev/null"
|
29
|
+
print "."
|
30
|
+
system "git commit -q -m 'Enzyme sync.' &> /dev/null"
|
31
|
+
print "."
|
32
|
+
system "git pull -q &> /dev/null"
|
33
|
+
print "."
|
34
|
+
system "git push -q &> /dev/null"
|
35
|
+
puts
|
28
36
|
|
29
37
|
# RESOURCES
|
30
38
|
|
31
39
|
unless skip_resources
|
40
|
+
# TODO: Check if the directory exists.
|
41
|
+
|
42
|
+
puts "Syncing resources directory..."
|
43
|
+
|
32
44
|
system "cd #{directory}/resources"
|
33
45
|
Dir.chdir("#{directory}/resources")
|
34
|
-
|
35
|
-
|
36
|
-
system "git
|
37
|
-
|
38
|
-
system "git
|
39
|
-
|
46
|
+
print "."
|
47
|
+
|
48
|
+
system "git checkout -q . &> /dev/null"
|
49
|
+
print "."
|
50
|
+
system "git add . &> /dev/null"
|
51
|
+
print "."
|
52
|
+
system "git commit -q -m 'Enzyme sync.' &> /dev/null"
|
53
|
+
print "."
|
54
|
+
system "git pull -q &> /dev/null"
|
55
|
+
print "."
|
56
|
+
system "git push -q &> /dev/null"
|
57
|
+
puts
|
40
58
|
end
|
41
59
|
|
42
60
|
# PRODUCTION
|
43
61
|
|
44
|
-
|
45
|
-
|
62
|
+
unless skip_production
|
63
|
+
# TODO: Check if the directory exists.
|
64
|
+
|
65
|
+
puts "Syncing production directory..."
|
66
|
+
|
67
|
+
system "cd #{directory}/production"
|
68
|
+
Dir.chdir("#{directory}/production")
|
69
|
+
print "."
|
70
|
+
|
71
|
+
system "git add #{$settings.short_name} &> /dev/null"
|
72
|
+
print "."
|
73
|
+
system "git add -u &> /dev/null"
|
74
|
+
print "."
|
75
|
+
system "git commit -q -a -m 'Enzyme sync.' &> /dev/null"
|
76
|
+
print "."
|
77
|
+
system "git clean -fd &> /dev/null"
|
78
|
+
print "."
|
79
|
+
system "git pull -q &> /dev/null"
|
80
|
+
print "."
|
81
|
+
system "git push -q &> /dev/null"
|
82
|
+
puts
|
83
|
+
end
|
46
84
|
|
47
|
-
|
48
|
-
system "git add -u > /dev/null"
|
49
|
-
system "git commit -a -m 'Enzyme sync.'"
|
50
|
-
system "git clean -fd > /dev/null"
|
51
|
-
system "git pull > /dev/null"
|
52
|
-
system "git push > /dev/null"
|
85
|
+
puts "Done."
|
53
86
|
end
|
54
87
|
|
55
88
|
end
|
56
89
|
|
57
90
|
Enzyme.register('sync', Sync) do
|
58
91
|
puts "#{$format.bold}SYNOPSIS#{$format.normal}"
|
59
|
-
puts
|
92
|
+
puts " enzyme sync [<project_name>] [--skip-resources] [--skip-production]"
|
60
93
|
puts
|
61
94
|
puts "#{$format.bold}DESCRIPTION#{$format.normal}"
|
62
|
-
puts
|
95
|
+
puts " Sync either the current project or a specified project with the sync server."
|
96
|
+
puts
|
97
|
+
puts " Any changes in the production directory outside of the current user's production directory"
|
98
|
+
puts " will be discarded."
|
63
99
|
puts
|
64
|
-
puts "
|
65
|
-
puts
|
100
|
+
puts " Only additions to the the resources directory will be kept. Any modifications to exsiting"
|
101
|
+
puts " references will be lost."
|
66
102
|
puts
|
67
103
|
puts "#{$format.bold}EXAMPLES#{$format.normal}"
|
68
|
-
puts
|
104
|
+
puts " 1. Syncing a specific project:"
|
69
105
|
puts
|
70
|
-
puts
|
71
|
-
puts
|
106
|
+
puts " $ enzyme sync abc"
|
107
|
+
puts " Syncing project 'abc' at '/Users/jane/Projects/abc'..."
|
108
|
+
puts " ...."
|
109
|
+
puts " Syncing resources directory..."
|
110
|
+
puts " ....."
|
111
|
+
puts " Syncing production directory..."
|
112
|
+
puts " ......"
|
113
|
+
puts " Done."
|
72
114
|
puts
|
73
|
-
puts
|
74
|
-
puts ' enzyme sync'
|
75
|
-
puts ' When the production directory is the root of a project you can run sync without any arguments.'
|
115
|
+
puts " 2. Syncing the current project:"
|
76
116
|
puts
|
117
|
+
puts " $ cd /Users/jane/Projects/abc"
|
118
|
+
puts " $ enzyme sync"
|
119
|
+
puts " Syncing project 'abc' at '/Users/jane/Projects/abc'..."
|
120
|
+
puts " ...."
|
121
|
+
puts " Syncing resources directory..."
|
122
|
+
puts " ....."
|
123
|
+
puts " Syncing production directory..."
|
124
|
+
puts " ......"
|
125
|
+
puts " Done."
|
77
126
|
end
|
data/lib/enzyme.rb
CHANGED
@@ -5,17 +5,13 @@ module Enzyme extend self
|
|
5
5
|
@@commands = {}
|
6
6
|
|
7
7
|
def run
|
8
|
-
#
|
9
|
-
|
10
|
-
|
11
|
-
puts
|
8
|
+
# If "-h" or "--help" was passed, delete the first one found and set the command to "help".
|
9
|
+
# Otherwise, assume the command is the first argument passed.
|
10
|
+
command = ARGV.delete((ARGV & [ "-h", "--help" ]).first) ? 'help' : ARGV.shift
|
12
11
|
|
13
12
|
# Show info, help or run the requested command if it has been registered.
|
14
13
|
begin
|
15
|
-
if command.nil?
|
16
|
-
info
|
17
|
-
help
|
18
|
-
elsif command.eql?('info')
|
14
|
+
if command.nil? || command.eql?('info')
|
19
15
|
info
|
20
16
|
elsif command.eql?('help')
|
21
17
|
help
|
@@ -32,6 +28,9 @@ module Enzyme extend self
|
|
32
28
|
end
|
33
29
|
|
34
30
|
def info
|
31
|
+
ARGV.each { |x| raise UnknownOption.new(x) if x.start_with?("-") }
|
32
|
+
ARGV.each { |x| raise UnknownArgument.new(x) }
|
33
|
+
|
35
34
|
puts '+-------------------------------------------------+'
|
36
35
|
puts '| ##### ## ## ###### ## ## ## ## ##### |'
|
37
36
|
puts '| ## ### ## ## ## ## ### ### ## |'
|
@@ -41,16 +40,21 @@ module Enzyme extend self
|
|
41
40
|
puts '+-------------------------------------------------+'
|
42
41
|
puts
|
43
42
|
puts "#{$format.bold}DESCRIPTION#{$format.normal}"
|
44
|
-
puts '
|
43
|
+
puts ' Katalyst\'s project collaboration tool.'
|
45
44
|
puts
|
46
45
|
puts "#{$format.bold}VERSION#{$format.normal}"
|
47
|
-
puts "
|
46
|
+
puts " #{$system_settings.version}"
|
47
|
+
puts
|
48
|
+
puts "#{$format.bold}HELP#{$format.normal}"
|
49
|
+
puts " Run this command to get help:"
|
48
50
|
puts
|
51
|
+
puts " $ enzyme help"
|
49
52
|
end
|
50
53
|
|
51
54
|
def help
|
52
|
-
ARGV.
|
55
|
+
ARGV.each { |x| raise UnknownOption.new(x) if x.start_with?("-") }
|
53
56
|
command = ARGV.shift
|
57
|
+
ARGV.each { |x| raise UnknownArgument.new(x) }
|
54
58
|
|
55
59
|
if command
|
56
60
|
if @@commands.include?(command.to_s.downcase)
|
@@ -60,22 +64,21 @@ module Enzyme extend self
|
|
60
64
|
end
|
61
65
|
else
|
62
66
|
puts "#{$format.bold}SYNOPSIS#{$format.normal}"
|
63
|
-
puts '
|
67
|
+
puts ' enzyme <command> [<options>]'
|
64
68
|
puts
|
65
69
|
puts "#{$format.bold}HELP#{$format.normal}"
|
66
|
-
puts '
|
67
|
-
puts '
|
68
|
-
puts '
|
70
|
+
puts ' enzyme help [<command>]'
|
71
|
+
puts ' enzyme [<command>] --help'
|
72
|
+
puts ' enzyme [<command>] -h'
|
69
73
|
puts
|
70
74
|
puts "#{$format.bold}COMMANDS#{$format.normal}"
|
71
75
|
|
72
|
-
([ "info" ]+@@commands.keys).sort.each { |command| puts "
|
76
|
+
([ "info" ]+@@commands.keys).sort.each { |command| puts " #{command}" }
|
73
77
|
|
74
78
|
puts
|
75
79
|
puts "#{$format.bold}DEBUGGING#{$format.normal}"
|
76
|
-
puts '
|
77
|
-
puts '
|
78
|
-
puts
|
80
|
+
puts ' Use `--trace` at anytime to get full stacktraces.'
|
81
|
+
puts ' Use `--skip-sync-server` to prevent the sync server from mounting automatically.'
|
79
82
|
end
|
80
83
|
end
|
81
84
|
|
@@ -83,10 +86,10 @@ module Enzyme extend self
|
|
83
86
|
if $system_settings.trace_errors
|
84
87
|
raise error
|
85
88
|
else
|
86
|
-
puts "#{$format.bold}ERROR
|
87
|
-
puts
|
88
|
-
puts ' Run `enzyme help` for help or use the `--trace` option to get a full stacktrace.'
|
89
|
+
puts "#{$format.bold}ERROR#{$format.normal}"
|
90
|
+
puts " #{error}"
|
89
91
|
puts
|
92
|
+
puts " Run `enzyme help` for help or use the `--trace` option to get a full stacktrace."
|
90
93
|
end
|
91
94
|
end
|
92
95
|
|
data/lib/errors.rb
CHANGED
@@ -33,6 +33,7 @@ end
|
|
33
33
|
class ConfigFileNotFound < StandardError
|
34
34
|
|
35
35
|
def initialize(path)
|
36
|
+
path = File.expand_path(path)
|
36
37
|
super("Config file could not be found at '#{path}'.")
|
37
38
|
end
|
38
39
|
|
@@ -49,6 +50,7 @@ end
|
|
49
50
|
class ProjectAlreadyExists < StandardError
|
50
51
|
|
51
52
|
def initialize(path)
|
53
|
+
path = File.expand_path(path)
|
52
54
|
super("A project already exists at '#{path}'.")
|
53
55
|
end
|
54
56
|
|
@@ -57,6 +59,7 @@ end
|
|
57
59
|
class CannotFindProject < StandardError
|
58
60
|
|
59
61
|
def initialize(path)
|
62
|
+
path = File.expand_path(path)
|
60
63
|
super("Cannot find a project at '#{path}'.")
|
61
64
|
end
|
62
65
|
|
data/lib/setup.rb
CHANGED
@@ -59,7 +59,7 @@ if !$system_settings.sync_server.skip && $settings.sync.host_name && $settings.s
|
|
59
59
|
# Mount the sync server if it isn't already there.
|
60
60
|
unless File.directory?($system_settings.sync_server.path)
|
61
61
|
`mkdir #{$system_settings.sync_server.path}`
|
62
|
-
`mount -t afp #{afp_url} #{$system_settings.sync_server.path}
|
62
|
+
`mount -t afp #{afp_url} #{$system_settings.sync_server.path} &> /dev/null`
|
63
63
|
`rm -r \"/Volumes/#{$settings.sync.share_name}\"` if $? != 0
|
64
64
|
end
|
65
65
|
|
metadata
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: enzyme
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 1.0.0.
|
4
|
+
version: 1.0.0.beta03
|
5
5
|
prerelease: 6
|
6
6
|
platform: ruby
|
7
7
|
authors:
|
@@ -9,11 +9,11 @@ authors:
|
|
9
9
|
autorequire:
|
10
10
|
bindir: bin
|
11
11
|
cert_chain: []
|
12
|
-
date: 2012-
|
12
|
+
date: 2012-08-01 00:00:00.000000000Z
|
13
13
|
dependencies:
|
14
14
|
- !ruby/object:Gem::Dependency
|
15
15
|
name: rake
|
16
|
-
requirement: &
|
16
|
+
requirement: &2152427040 !ruby/object:Gem::Requirement
|
17
17
|
none: false
|
18
18
|
requirements:
|
19
19
|
- - =
|
@@ -21,10 +21,10 @@ dependencies:
|
|
21
21
|
version: 0.9.2
|
22
22
|
type: :runtime
|
23
23
|
prerelease: false
|
24
|
-
version_requirements: *
|
24
|
+
version_requirements: *2152427040
|
25
25
|
- !ruby/object:Gem::Dependency
|
26
26
|
name: shoulda
|
27
|
-
requirement: &
|
27
|
+
requirement: &2152425680 !ruby/object:Gem::Requirement
|
28
28
|
none: false
|
29
29
|
requirements:
|
30
30
|
- - ! '>='
|
@@ -32,10 +32,10 @@ dependencies:
|
|
32
32
|
version: '0'
|
33
33
|
type: :development
|
34
34
|
prerelease: false
|
35
|
-
version_requirements: *
|
35
|
+
version_requirements: *2152425680
|
36
36
|
- !ruby/object:Gem::Dependency
|
37
37
|
name: bundler
|
38
|
-
requirement: &
|
38
|
+
requirement: &2152424900 !ruby/object:Gem::Requirement
|
39
39
|
none: false
|
40
40
|
requirements:
|
41
41
|
- - ~>
|
@@ -43,10 +43,10 @@ dependencies:
|
|
43
43
|
version: 1.0.0
|
44
44
|
type: :development
|
45
45
|
prerelease: false
|
46
|
-
version_requirements: *
|
46
|
+
version_requirements: *2152424900
|
47
47
|
- !ruby/object:Gem::Dependency
|
48
48
|
name: jeweler
|
49
|
-
requirement: &
|
49
|
+
requirement: &2152424060 !ruby/object:Gem::Requirement
|
50
50
|
none: false
|
51
51
|
requirements:
|
52
52
|
- - ~>
|
@@ -54,10 +54,10 @@ dependencies:
|
|
54
54
|
version: 1.5.2
|
55
55
|
type: :development
|
56
56
|
prerelease: false
|
57
|
-
version_requirements: *
|
57
|
+
version_requirements: *2152424060
|
58
58
|
- !ruby/object:Gem::Dependency
|
59
59
|
name: rcov
|
60
|
-
requirement: &
|
60
|
+
requirement: &2152422860 !ruby/object:Gem::Requirement
|
61
61
|
none: false
|
62
62
|
requirements:
|
63
63
|
- - ! '>='
|
@@ -65,7 +65,7 @@ dependencies:
|
|
65
65
|
version: '0'
|
66
66
|
type: :development
|
67
67
|
prerelease: false
|
68
|
-
version_requirements: *
|
68
|
+
version_requirements: *2152422860
|
69
69
|
description: Enzyme is a tool to make collaborating on projects easier. Developed
|
70
70
|
by Katalyst Interactive.
|
71
71
|
email: haydn@katalyst.com.au
|
@@ -106,7 +106,7 @@ required_ruby_version: !ruby/object:Gem::Requirement
|
|
106
106
|
version: '0'
|
107
107
|
segments:
|
108
108
|
- 0
|
109
|
-
hash:
|
109
|
+
hash: 4011783646053326161
|
110
110
|
required_rubygems_version: !ruby/object:Gem::Requirement
|
111
111
|
none: false
|
112
112
|
requirements:
|