pik 0.1.1 → 0.2.0
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/History.txt +13 -0
- data/Manifest.txt +35 -1
- data/README.rdoc +99 -39
- data/Rakefile +49 -8
- data/bin/pik_install +23 -0
- data/features/add_command.feature +28 -0
- data/features/checkup_command.feature +0 -0
- data/features/config_command.feature +12 -0
- data/features/default_command.feature +12 -0
- data/features/env.rb +52 -0
- data/features/gemsync_command.feature +0 -0
- data/features/help_command.feature +13 -0
- data/features/implode_command.feature +12 -0
- data/features/install_command.feature +13 -0
- data/features/list_command.feature +18 -0
- data/features/remove_command.feature +18 -0
- data/features/run_command.feature +22 -0
- data/features/step_definitions/pik_commands.rb +140 -0
- data/features/switch_command.feature +35 -0
- data/features/tag_command.feature +18 -0
- data/features/version.feature +9 -0
- data/lib/pik.rb +17 -3
- data/lib/pik/commands/add_command.rb +6 -6
- data/lib/pik/commands/batch_file_editor.rb +22 -8
- data/lib/pik/commands/checkup_command.rb +5 -2
- data/lib/pik/commands/command.rb +30 -26
- data/lib/pik/commands/config_command.rb +54 -2
- data/lib/pik/commands/default_command.rb +19 -5
- data/lib/pik/commands/help_command.rb +1 -1
- data/lib/pik/commands/implode_command.rb +12 -1
- data/lib/pik/commands/install_command.rb +182 -0
- data/lib/pik/commands/list_command.rb +3 -2
- data/lib/pik/commands/remove_command.rb +6 -6
- data/lib/pik/commands/run_command.rb +70 -10
- data/lib/pik/commands/switch_command.rb +10 -10
- data/lib/pik/commands/tag_command.rb +56 -0
- data/lib/pik/config_file.rb +26 -2
- data/lib/pik/contrib/progressbar.rb +237 -0
- data/lib/pik/contrib/unzip.rb +14 -0
- data/lib/pik/contrib/uri_ext.rb +296 -0
- data/lib/pik/contrib/zip/ioextras.rb +155 -0
- data/lib/pik/contrib/zip/stdrubyext.rb +111 -0
- data/lib/pik/contrib/zip/tempfile_bugfixed.rb +195 -0
- data/lib/pik/contrib/zip/zip.rb +1846 -0
- data/lib/pik/contrib/zip/zipfilesystem.rb +609 -0
- data/lib/pik/contrib/zip/ziprequire.rb +90 -0
- data/lib/pik/core_ext/pathname.rb +20 -7
- data/lib/pik/search_path.rb +21 -13
- data/lib/pik/which.rb +52 -0
- data/lib/pik/windows_env.rb +64 -25
- data/spec/add_command_spec.rb +0 -2
- data/spec/batch_file_spec.rb +3 -3
- data/spec/command_spec.rb +0 -7
- data/spec/gemsync_command_spec.rb +1 -1
- data/spec/help_command_spec.rb +1 -1
- data/spec/list_command_spec.rb +1 -1
- data/spec/pathname_spec.rb +30 -0
- data/spec/remove_command_spec.rb +6 -6
- data/spec/run_command_spec.rb +2 -30
- data/spec/search_path_spec.rb +9 -0
- data/spec/switch_command_spec.rb +14 -2
- data/spec/which_spec.rb +7 -0
- data/tools/pik.bat +2 -0
- data/tools/pik/pik +45 -0
- data/tools/pik/pik.exe +0 -0
- data/tools/pik/pik.exy +198 -0
- metadata +50 -21
- data/bin/pik +0 -33
data/bin/pik
DELETED
@@ -1,33 +0,0 @@
|
|
1
|
-
#!/usr/bin/env ruby
|
2
|
-
require File.join(File.dirname(__FILE__), '..', 'lib', 'pik')
|
3
|
-
|
4
|
-
include Pik
|
5
|
-
|
6
|
-
args = ARGV
|
7
|
-
|
8
|
-
Command.clean_gem_batch
|
9
|
-
|
10
|
-
begin
|
11
|
-
config = ConfigFile.new
|
12
|
-
|
13
|
-
args << 'help' if args.empty?
|
14
|
-
|
15
|
-
command = if Command.choose_from(args, config)
|
16
|
-
Switch
|
17
|
-
elsif (cmd = Commands.find(args.shift))
|
18
|
-
cmd
|
19
|
-
else
|
20
|
-
Help
|
21
|
-
end
|
22
|
-
|
23
|
-
cmd = command.new(args, config)
|
24
|
-
cmd.execute
|
25
|
-
rescue QuitError
|
26
|
-
puts "\nQuitting..."
|
27
|
-
rescue => e
|
28
|
-
puts "\nThere was an error"
|
29
|
-
puts " Error: #{e.message}\n\n"
|
30
|
-
puts e.backtrace
|
31
|
-
ensure
|
32
|
-
cmd.close if cmd
|
33
|
-
end
|