redcar 0.3.10.1dev → 0.4
Sign up to get free protection for your applications and to get access to all the features.
- data/CHANGES +12 -2
- data/README.md +1 -2
- data/Rakefile +1 -1
- data/bin/redcar +4 -4
- data/lib/redcar.rb +3 -3
- data/lib/redcar/installer.rb +3 -3
- data/lib/redcar/runner.rb +5 -1
- data/lib/redcar/usage.rb +2 -1
- data/plugins/application/features/step_definitions/tree_steps.rb +20 -9
- data/plugins/application/features/support/env.rb +27 -8
- data/plugins/application/lib/application/command/executor.rb +5 -1
- data/plugins/application/lib/application/menu/builder/group.rb +4 -0
- data/plugins/application/lib/application/menu/item.rb +17 -2
- data/plugins/application/spec/application/command/executor_spec.rb +5 -0
- data/plugins/application_swt/lib/application_swt/event_loop.rb +10 -5
- data/plugins/application_swt/lib/application_swt/menu.rb +30 -19
- data/plugins/application_swt/lib/application_swt/swt_wrapper.rb +2 -0
- data/plugins/application_swt/lib/application_swt/window.rb +43 -43
- data/plugins/core/lib/core/gui.rb +6 -1
- data/plugins/core/lib/core/observable.rb +1 -1
- data/plugins/core/spec/core/task_queue_spec.rb +2 -5
- data/plugins/declarations/lib/declarations.rb +5 -1
- data/plugins/declarations/lib/declarations/file.rb +1 -1
- data/plugins/declarations/lib/declarations/parser.rb +60 -16
- data/plugins/edit_view/features/step_definitions/tab_steps.rb +4 -0
- data/plugins/edit_view/features/step_definitions/window_steps.rb +1 -1
- data/plugins/edit_view/features/support/env.rb +5 -0
- data/plugins/edit_view/lib/edit_view.rb +3 -1
- data/plugins/edit_view/lib/edit_view/document.rb +10 -0
- data/plugins/edit_view/lib/edit_view/document/mirror.rb +1 -1
- data/plugins/edit_view_swt/lib/edit_view_swt.rb +3 -0
- data/plugins/find-in-project/README.md +9 -0
- data/plugins/find-in-project/TODO.md +8 -0
- data/plugins/find-in-project/lib/find_in_project.rb +58 -0
- data/plugins/find-in-project/lib/find_in_project/commands.rb +43 -0
- data/plugins/find-in-project/lib/find_in_project/controllers.rb +108 -0
- data/plugins/find-in-project/lib/find_in_project/engines/ack.rb +42 -0
- data/plugins/find-in-project/lib/find_in_project/engines/grep.rb +52 -0
- data/plugins/find-in-project/lib/find_in_project/images/collapsed.png +0 -0
- data/plugins/find-in-project/lib/find_in_project/images/expanded.png +0 -0
- data/plugins/find-in-project/lib/find_in_project/stylesheets/style.css +205 -0
- data/plugins/find-in-project/lib/find_in_project/views/_results.html.erb +50 -0
- data/plugins/find-in-project/lib/find_in_project/views/index.html.erb +120 -0
- data/plugins/find-in-project/plugin.rb +10 -0
- data/plugins/html_view/features/step_definitions/html_view_steps.rb +20 -0
- data/plugins/html_view/features/support/env.rb +0 -0
- data/plugins/html_view/lib/html_view.rb +3 -1
- data/plugins/outline_view/lib/outline_view.rb +64 -0
- data/plugins/outline_view/lib/outline_view/commands.rb +13 -0
- data/plugins/outline_view/plugin.rb +10 -0
- data/plugins/outline_view_swt/lib/icons/alias.png +0 -0
- data/plugins/outline_view_swt/lib/icons/assignment.png +0 -0
- data/plugins/outline_view_swt/lib/icons/attribute.png +0 -0
- data/plugins/outline_view_swt/lib/icons/class.png +0 -0
- data/plugins/outline_view_swt/lib/icons/interface.png +0 -0
- data/plugins/outline_view_swt/lib/icons/method.png +0 -0
- data/plugins/outline_view_swt/lib/outline_view_swt.rb +81 -0
- data/plugins/outline_view_swt/plugin.rb +7 -0
- data/plugins/pair_highlighter/lib/pair_highlighter.rb +34 -0
- data/plugins/pair_highlighter/lib/pair_highlighter/document_controller.rb +185 -0
- data/plugins/pair_highlighter/plugin.rb +9 -0
- data/plugins/project/features/open_directory_tree.feature +1 -1
- data/plugins/project/features/refresh_directory_tree.feature +8 -8
- data/plugins/project/features/step_definitions/file_steps.rb +2 -2
- data/plugins/project/lib/project.rb +8 -4
- data/plugins/project/lib/project/adapters/remote_protocols/ftp.rb +0 -4
- data/plugins/project/lib/project/adapters/remote_protocols/protocol.rb +0 -4
- data/plugins/project/lib/project/adapters/remote_protocols/sftp.rb +0 -1
- data/plugins/project/lib/project/manager.rb +0 -2
- data/plugins/project/spec/project/adapters/remote_protocols/ftp_spec.rb +4 -0
- data/plugins/project/spec/project/adapters/remote_protocols/sftp_spec.rb +3 -0
- data/plugins/redcar/plugin.rb +2 -1
- data/plugins/redcar/redcar.rb +149 -138
- data/plugins/redcar_debug/lib/redcar_debug.rb +7 -0
- data/plugins/runnables/features/command_tree.feature +25 -0
- data/plugins/runnables/features/run_command_tab.feature +46 -0
- data/plugins/runnables/features/step_definitions/runnable_steps.rb +22 -0
- data/plugins/runnables/features/support/env.rb +67 -0
- data/plugins/runnables/lib/runnables.rb +55 -18
- data/plugins/runnables/lib/runnables/command_output_controller.rb +82 -28
- data/plugins/runnables/views/command_output.html.erb +16 -37
- data/plugins/runnables/views/default.css +68 -0
- data/plugins/runnables/views/indicator.gif +0 -0
- data/plugins/runnables/views/redcar_small_icon.png +0 -0
- data/plugins/runnables/views/reset.css +53 -0
- data/plugins/runnables/views/running_test.html +41 -0
- data/plugins/runnables/views/wedgeDown.png +0 -0
- data/plugins/runnables/views/wedgeRight.png +0 -0
- data/plugins/scm/icons/ATTRIBUTION +5 -0
- data/plugins/scm/icons/folder--arrow.png +0 -0
- data/plugins/scm/icons/folder--exclamation.png +0 -0
- data/plugins/scm/icons/folder--minus.png +0 -0
- data/plugins/scm/icons/folder--pencil.png +0 -0
- data/plugins/scm/icons/folder--plus.png +0 -0
- data/plugins/scm/icons/notebook--arrow.png +0 -0
- data/plugins/scm/icons/notebook--exclamation.png +0 -0
- data/plugins/scm/icons/notebook--minus.png +0 -0
- data/plugins/scm/icons/notebook--pencil.png +0 -0
- data/plugins/scm/icons/notebook--plus.png +0 -0
- data/plugins/scm/lib/scm.rb +278 -0
- data/plugins/scm/lib/scm/commit_mirror.rb +72 -0
- data/plugins/scm/lib/scm/diff_mirror.rb +31 -0
- data/plugins/scm/lib/scm/errors.rb +8 -0
- data/plugins/scm/lib/scm/model.rb +254 -0
- data/plugins/scm/lib/scm/scm_changes_controller.rb +94 -0
- data/plugins/scm/lib/scm/scm_changes_mirror.rb +51 -0
- data/plugins/scm/lib/scm/scm_changes_mirror/change.rb +61 -0
- data/plugins/scm/lib/scm/scm_changes_mirror/changes_node.rb +47 -0
- data/plugins/scm/lib/scm/scm_changes_mirror/drag_controller.rb +78 -0
- data/plugins/scm/lib/scm/scm_commits_controller.rb +49 -0
- data/plugins/scm/lib/scm/scm_commits_mirror.rb +36 -0
- data/plugins/scm/lib/scm/scm_commits_mirror/commit.rb +26 -0
- data/plugins/scm/lib/scm/scm_commits_mirror/commits_node.rb +38 -0
- data/plugins/scm/plugin.rb +8 -0
- data/plugins/scm/spec/spec_helper.rb +5 -0
- data/plugins/scm/vendor/ruby-blockcache/LICENSE +21 -0
- data/plugins/scm/vendor/ruby-blockcache/README.md +44 -0
- data/plugins/scm/vendor/ruby-blockcache/lib/blockcache.rb +120 -0
- data/plugins/scm_git/lib/scm_git.rb +478 -0
- data/plugins/scm_git/lib/scm_git/change.rb +127 -0
- data/plugins/scm_git/lib/scm_git/commit.rb +18 -0
- data/plugins/scm_git/lib/scm_git/config_file.rb +31 -0
- data/plugins/scm_git/plugin.rb +7 -0
- data/plugins/scm_git/vendor/ruby-git/History.txt +21 -0
- data/plugins/scm_git/vendor/ruby-git/LICENSE +21 -0
- data/plugins/scm_git/vendor/ruby-git/README +240 -0
- data/plugins/scm_git/vendor/ruby-git/Rakefile +51 -0
- data/plugins/scm_git/vendor/ruby-git/TODO +27 -0
- data/plugins/scm_git/vendor/ruby-git/VERSION +1 -0
- data/plugins/scm_git/vendor/ruby-git/benchmark.rb +157 -0
- data/plugins/scm_git/vendor/ruby-git/camping/gitweb.rb +555 -0
- data/plugins/scm_git/vendor/ruby-git/git.gemspec +53 -0
- data/plugins/scm_git/vendor/ruby-git/lib/git.rb +156 -0
- data/plugins/scm_git/vendor/ruby-git/lib/git/author.rb +14 -0
- data/plugins/scm_git/vendor/ruby-git/lib/git/base.rb +479 -0
- data/plugins/scm_git/vendor/ruby-git/lib/git/branch.rb +104 -0
- data/plugins/scm_git/vendor/ruby-git/lib/git/branches.rb +48 -0
- data/plugins/scm_git/vendor/ruby-git/lib/git/diff.rb +146 -0
- data/plugins/scm_git/vendor/ruby-git/lib/git/index.rb +5 -0
- data/plugins/scm_git/vendor/ruby-git/lib/git/lib.rb +730 -0
- data/plugins/scm_git/vendor/ruby-git/lib/git/log.rb +117 -0
- data/plugins/scm_git/vendor/ruby-git/lib/git/object.rb +273 -0
- data/plugins/scm_git/vendor/ruby-git/lib/git/path.rb +27 -0
- data/plugins/scm_git/vendor/ruby-git/lib/git/remote.rb +40 -0
- data/plugins/scm_git/vendor/ruby-git/lib/git/repository.rb +4 -0
- data/plugins/scm_git/vendor/ruby-git/lib/git/stash.rb +27 -0
- data/plugins/scm_git/vendor/ruby-git/lib/git/stashes.rb +44 -0
- data/plugins/scm_git/vendor/ruby-git/lib/git/status.rb +127 -0
- data/plugins/scm_git/vendor/ruby-git/lib/git/working_directory.rb +4 -0
- data/plugins/scm_git/vendor/ruby-git/ruby-git.gemspec +15 -0
- data/plugins/scm_git/vendor/ruby-git/tests/all_tests.rb +4 -0
- data/plugins/scm_git/vendor/ruby-git/tests/files/index +0 -0
- data/plugins/scm_git/vendor/ruby-git/tests/files/working/dot_git/FETCH_HEAD +1 -0
- data/plugins/scm_git/vendor/ruby-git/tests/files/working/dot_git/HEAD +1 -0
- data/plugins/scm_git/vendor/ruby-git/tests/files/working/dot_git/config +13 -0
- data/plugins/scm_git/vendor/ruby-git/tests/files/working/dot_git/description +1 -0
- data/plugins/scm_git/vendor/ruby-git/tests/files/working/dot_git/hooks/applypatch-msg +15 -0
- data/plugins/scm_git/vendor/ruby-git/tests/files/working/dot_git/hooks/commit-msg +21 -0
- data/plugins/scm_git/vendor/ruby-git/tests/files/working/dot_git/hooks/post-commit +8 -0
- data/plugins/scm_git/vendor/ruby-git/tests/files/working/dot_git/hooks/post-receive +16 -0
- data/plugins/scm_git/vendor/ruby-git/tests/files/working/dot_git/hooks/post-update +8 -0
- data/plugins/scm_git/vendor/ruby-git/tests/files/working/dot_git/hooks/pre-applypatch +14 -0
- data/plugins/scm_git/vendor/ruby-git/tests/files/working/dot_git/hooks/pre-commit +70 -0
- data/plugins/scm_git/vendor/ruby-git/tests/files/working/dot_git/hooks/pre-rebase +150 -0
- data/plugins/scm_git/vendor/ruby-git/tests/files/working/dot_git/hooks/update +78 -0
- data/plugins/scm_git/vendor/ruby-git/tests/files/working/dot_git/index +0 -0
- data/plugins/scm_git/vendor/ruby-git/tests/files/working/dot_git/info/exclude +6 -0
- data/plugins/scm_git/vendor/ruby-git/tests/files/working/dot_git/logs/HEAD +75 -0
- data/plugins/scm_git/vendor/ruby-git/tests/files/working/dot_git/logs/refs/heads/git_grep +5 -0
- data/plugins/scm_git/vendor/ruby-git/tests/files/working/dot_git/logs/refs/heads/master +64 -0
- data/plugins/scm_git/vendor/ruby-git/tests/files/working/dot_git/logs/refs/heads/test +3 -0
- data/plugins/scm_git/vendor/ruby-git/tests/files/working/dot_git/logs/refs/heads/test_branches +1 -0
- data/plugins/scm_git/vendor/ruby-git/tests/files/working/dot_git/logs/refs/heads/test_object +2 -0
- data/plugins/scm_git/vendor/ruby-git/tests/files/working/dot_git/logs/refs/remotes/working/master +1 -0
- data/plugins/scm_git/vendor/ruby-git/tests/files/working/dot_git/objects/00/62cdf4c1e63069eececf54325535e91fd57c42 +0 -0
- data/plugins/scm_git/vendor/ruby-git/tests/files/working/dot_git/objects/00/ea60e1331b184386392037a7267dfb4a7c7d86 +0 -0
- data/plugins/scm_git/vendor/ruby-git/tests/files/working/dot_git/objects/01/0b7b79019cb510d8c5849704fd10541655916d +0 -0
- data/plugins/scm_git/vendor/ruby-git/tests/files/working/dot_git/objects/01/dd46ebe07fc30c10c85c2e926c70f2d7058a6b +0 -0
- data/plugins/scm_git/vendor/ruby-git/tests/files/working/dot_git/objects/02/b2a02844d00574c234d17bec6294e832f3c4c1 +0 -0
- data/plugins/scm_git/vendor/ruby-git/tests/files/working/dot_git/objects/06/f4e8a840d23fc0ab94895a5d16827a19f75fb7 +0 -0
- data/plugins/scm_git/vendor/ruby-git/tests/files/working/dot_git/objects/0b/2fe00801b62b7760c23d554796b05abc16af92 +0 -0
- data/plugins/scm_git/vendor/ruby-git/tests/files/working/dot_git/objects/0b/5262f6ee3552a99b7081a317e8289d6a4d8e72 +0 -0
- data/plugins/scm_git/vendor/ruby-git/tests/files/working/dot_git/objects/0b/c0d846cf80b079e763e35c3af273171bf01fca +0 -0
- data/plugins/scm_git/vendor/ruby-git/tests/files/working/dot_git/objects/0d/2c47f07277b3ea30b0884f8e3acd68440507c8 +0 -0
- data/plugins/scm_git/vendor/ruby-git/tests/files/working/dot_git/objects/0d/519ca9c2eddc44431efe135d0fc8df00e0b975 +0 -0
- data/plugins/scm_git/vendor/ruby-git/tests/files/working/dot_git/objects/0f/845a0a981bc2f61354fcdd2b6eafe2b2c55c2d +3 -0
- data/plugins/scm_git/vendor/ruby-git/tests/files/working/dot_git/objects/0f/f4a0357c3d7221a2ef1e4c6b7d5c46d97fe250 +0 -0
- data/plugins/scm_git/vendor/ruby-git/tests/files/working/dot_git/objects/12/eb889f49f1464b32a51424d7724fb16f6c3a31 +0 -0
- data/plugins/scm_git/vendor/ruby-git/tests/files/working/dot_git/objects/15/34a65657edf4e5caaa5ce35652dca5e4c7d316 +0 -0
- data/plugins/scm_git/vendor/ruby-git/tests/files/working/dot_git/objects/15/378a1f3eafe4c5ab4f890883356df917ee5539 +2 -0
- data/plugins/scm_git/vendor/ruby-git/tests/files/working/dot_git/objects/16/9e6db43d4c09cd610179a7b9826483b4d94123 +0 -0
- data/plugins/scm_git/vendor/ruby-git/tests/files/working/dot_git/objects/16/d1f96acfd92d09c4f1f56d3441ac55dd30500e +0 -0
- data/plugins/scm_git/vendor/ruby-git/tests/files/working/dot_git/objects/16/ee5335538f11b4ffcc17b051f8d5db7570a055 +0 -0
- data/plugins/scm_git/vendor/ruby-git/tests/files/working/dot_git/objects/17/9ef0e0209e90af00f544ff414e0674dfb5f5c7 +0 -0
- data/plugins/scm_git/vendor/ruby-git/tests/files/working/dot_git/objects/19/9d2f8e60fddd1bb2a1b0bddedde35e5aa8b03f +0 -0
- data/plugins/scm_git/vendor/ruby-git/tests/files/working/dot_git/objects/1c/c8667014381e2788a94777532a788307f38d26 +1 -0
- data/plugins/scm_git/vendor/ruby-git/tests/files/working/dot_git/objects/1c/fcfba04eb4e461e9f930d22f528023ab1ddefc +0 -0
- data/plugins/scm_git/vendor/ruby-git/tests/files/working/dot_git/objects/1d/7be4117ded4534789d85c42ab579644cd3fa12 +0 -0
- data/plugins/scm_git/vendor/ruby-git/tests/files/working/dot_git/objects/1d/9e4767a95047ca5e395714985afaedb186f4cd +1 -0
- data/plugins/scm_git/vendor/ruby-git/tests/files/working/dot_git/objects/1f/09f2edb9c0d9275d15960771b363ca6940fbe3 +0 -0
- data/plugins/scm_git/vendor/ruby-git/tests/files/working/dot_git/objects/1f/691b879df15cf6742502ffc59833b4a40e7aef +0 -0
- data/plugins/scm_git/vendor/ruby-git/tests/files/working/dot_git/objects/23/751ef6c1fed1304ae1d07020aa73da6f2b93b0 +1 -0
- data/plugins/scm_git/vendor/ruby-git/tests/files/working/dot_git/objects/24/5582a71306d7360e40c07cd7d849a1aa14a31e +0 -0
- data/plugins/scm_git/vendor/ruby-git/tests/files/working/dot_git/objects/26/3e3c527004e7b742ed1f747c1bfb7e11825d7a +0 -0
- data/plugins/scm_git/vendor/ruby-git/tests/files/working/dot_git/objects/27/c0c003dda3e59ba236f53f6661faaf74432b5c +0 -0
- data/plugins/scm_git/vendor/ruby-git/tests/files/working/dot_git/objects/29/1b6be488d6abc586d3ee03ca61238766625a75 +0 -0
- data/plugins/scm_git/vendor/ruby-git/tests/files/working/dot_git/objects/2a/f6f7d51b7afdd404a871581ebb3b6ac07fb8cc +0 -0
- data/plugins/scm_git/vendor/ruby-git/tests/files/working/dot_git/objects/2c/ef51480d44dcc262d16be2812c692d940d5f29 +0 -0
- data/plugins/scm_git/vendor/ruby-git/tests/files/working/dot_git/objects/2e/20132e8fd40cb3e82248919a10900d31f1816a +0 -0
- data/plugins/scm_git/vendor/ruby-git/tests/files/working/dot_git/objects/2e/939fd37bbd2da971faa27c3e3de7d5aad40507 +0 -0
- data/plugins/scm_git/vendor/ruby-git/tests/files/working/dot_git/objects/2f/53e667d1d88e75b3fa300f9ab6e2d8ffd32a15 +0 -0
- data/plugins/scm_git/vendor/ruby-git/tests/files/working/dot_git/objects/32/4968b9dc40253f2c52a8e3856398c761dea856 +0 -0
- data/plugins/scm_git/vendor/ruby-git/tests/files/working/dot_git/objects/33/8ecb0183d507498aedb669b796b4f9e8880f00 +0 -0
- data/plugins/scm_git/vendor/ruby-git/tests/files/working/dot_git/objects/33/edabb4334cbe849a477a0d2893cdb768fa3091 +0 -0
- data/plugins/scm_git/vendor/ruby-git/tests/files/working/dot_git/objects/34/a566d193dc4702f03149969a2aad1443231560 +1 -0
- data/plugins/scm_git/vendor/ruby-git/tests/files/working/dot_git/objects/36/fe213c328fd280f33abe00069c4b92eb5a88d1 +0 -0
- data/plugins/scm_git/vendor/ruby-git/tests/files/working/dot_git/objects/39/66e9fa0e0b9fe9d3ef2fdaa6933f3d0bb82bc3 +0 -0
- data/plugins/scm_git/vendor/ruby-git/tests/files/working/dot_git/objects/3a/9f195756f5bd26b67c5e1fffd92d68d61be14e +2 -0
- data/plugins/scm_git/vendor/ruby-git/tests/files/working/dot_git/objects/3a/ac4b445017a8fc07502670ec2dbf744213dd48 +0 -0
- data/plugins/scm_git/vendor/ruby-git/tests/files/working/dot_git/objects/3b/6eeed9ce43ea893cf48d263da93448edae9f1c +0 -0
- data/plugins/scm_git/vendor/ruby-git/tests/files/working/dot_git/objects/3c/644f22b9b8edb06e7e298ecac8e71b133061f1 +0 -0
- data/plugins/scm_git/vendor/ruby-git/tests/files/working/dot_git/objects/3c/c71b13d906e445da52785ddeff40dad1163d49 +2 -0
- data/plugins/scm_git/vendor/ruby-git/tests/files/working/dot_git/objects/3c/f35bd14cf5f2dd08bbeef8698d700f3a038e5c +0 -0
- data/plugins/scm_git/vendor/ruby-git/tests/files/working/dot_git/objects/3d/331db92a8ead0565679efb76f328ae69ed1b77 +0 -0
- data/plugins/scm_git/vendor/ruby-git/tests/files/working/dot_git/objects/44/88516c3c936db58ea485ec2213dab9d13e6628 +0 -0
- data/plugins/scm_git/vendor/ruby-git/tests/files/working/dot_git/objects/44/987dd95c338fb573726541f270f1a7b55c9d51 +0 -0
- data/plugins/scm_git/vendor/ruby-git/tests/files/working/dot_git/objects/45/20c29b885e9db9b0df3c7bab7870157e1d00c3 +0 -0
- data/plugins/scm_git/vendor/ruby-git/tests/files/working/dot_git/objects/45/b983be36b73c0788dc9cbcb76cbb80fc7bb057 +0 -0
- data/plugins/scm_git/vendor/ruby-git/tests/files/working/dot_git/objects/46/00557506be20eb1501a4f15a52e684d4b9ee61 +0 -0
- data/plugins/scm_git/vendor/ruby-git/tests/files/working/dot_git/objects/46/a60232117527e7b57ac0dd5ea4af2cd3fdb696 +0 -0
- data/plugins/scm_git/vendor/ruby-git/tests/files/working/dot_git/objects/47/0f6a87fa51dd25f6db0f4725ae37791d449356 +0 -0
- data/plugins/scm_git/vendor/ruby-git/tests/files/working/dot_git/objects/47/2650d42fa9454e2e61e3da9f5c158b8af6d298 +0 -0
- data/plugins/scm_git/vendor/ruby-git/tests/files/working/dot_git/objects/47/8e5ee111572790b248eaa99140c5a8f728abc7 +0 -0
- data/plugins/scm_git/vendor/ruby-git/tests/files/working/dot_git/objects/48/bbf0db7e813affab7d8dd2842b8455ff9876be +0 -0
- data/plugins/scm_git/vendor/ruby-git/tests/files/working/dot_git/objects/49/b352299735fda3a333c69c6273178b0c3dfa08 +0 -0
- data/plugins/scm_git/vendor/ruby-git/tests/files/working/dot_git/objects/4a/1e3e4500962c3631a479726bf2e40469594cba +0 -0
- data/plugins/scm_git/vendor/ruby-git/tests/files/working/dot_git/objects/4a/2bee50944e9285e8f82216c9b0b8a7d3cdd315 +0 -0
- data/plugins/scm_git/vendor/ruby-git/tests/files/working/dot_git/objects/4a/4e676afe275afecf23130390fe96d0e6d00057 +0 -0
- data/plugins/scm_git/vendor/ruby-git/tests/files/working/dot_git/objects/4a/de99433ac3e4bcc874cd7de488de29399e9096 +1 -0
- data/plugins/scm_git/vendor/ruby-git/tests/files/working/dot_git/objects/4b/7c90536eaa830d8c1f6ff49a7885b581d6acef +1 -0
- data/plugins/scm_git/vendor/ruby-git/tests/files/working/dot_git/objects/4c/411dc8e6ea6fcba0ed56e84aa7707f881d24c7 +0 -0
- data/plugins/scm_git/vendor/ruby-git/tests/files/working/dot_git/objects/4c/ce9432b2f80461324a61611f6143f8544cd80f +1 -0
- data/plugins/scm_git/vendor/ruby-git/tests/files/working/dot_git/objects/4c/e44a75510cbfe200b131fdbcc56a86f1b2dc08 +0 -0
- data/plugins/scm_git/vendor/ruby-git/tests/files/working/dot_git/objects/4d/35ba97a858072c240d327e3ce30c28b333a1b0 +0 -0
- data/plugins/scm_git/vendor/ruby-git/tests/files/working/dot_git/objects/4d/ff9ef38ef09cbf0e36031bbee22b7cf0c7a8fc +1 -0
- data/plugins/scm_git/vendor/ruby-git/tests/files/working/dot_git/objects/4e/aafb1d843aec4f8f1612d03de46a08c2143ea9 +0 -0
- data/plugins/scm_git/vendor/ruby-git/tests/files/working/dot_git/objects/4e/ebc1b62c53241b7fbf7fb33b5230362595bfdd +0 -0
- data/plugins/scm_git/vendor/ruby-git/tests/files/working/dot_git/objects/4f/4065121cb78fe6116ae7e3075f5c5a446bd08b +0 -0
- data/plugins/scm_git/vendor/ruby-git/tests/files/working/dot_git/objects/50/3d77289b054742f507d8a8ce7cc51d3841d5b9 +0 -0
- data/plugins/scm_git/vendor/ruby-git/tests/files/working/dot_git/objects/52/4038b20b297f40d78e7d83e04e38049457312b +0 -0
- data/plugins/scm_git/vendor/ruby-git/tests/files/working/dot_git/objects/53/a72df554e585e239e41cb1fc498d5aee9bb164 +0 -0
- data/plugins/scm_git/vendor/ruby-git/tests/files/working/dot_git/objects/54/0200385c3b0b299c7a87ecf59ca94c32fbbe99 +0 -0
- data/plugins/scm_git/vendor/ruby-git/tests/files/working/dot_git/objects/54/5c81a2e8d1112d5f7356f840a22e8f6abcef8f +2 -0
- data/plugins/scm_git/vendor/ruby-git/tests/files/working/dot_git/objects/54/5ffc79786f268524c35e1e05b1770c7c74faf1 +3 -0
- data/plugins/scm_git/vendor/ruby-git/tests/files/working/dot_git/objects/54/6bec6f8872efa41d5d97a369f669165ecda0de +0 -0
- data/plugins/scm_git/vendor/ruby-git/tests/files/working/dot_git/objects/54/7a4bae347658f0d9eed0d35d31b4561aea7cf8 +2 -0
- data/plugins/scm_git/vendor/ruby-git/tests/files/working/dot_git/objects/56/195ef83e9e20ca75dddef0630633fc8060ed11 +0 -0
- data/plugins/scm_git/vendor/ruby-git/tests/files/working/dot_git/objects/57/7ddd894033c46a5fcf2c6f3c4e71cc72f86909 +0 -0
- data/plugins/scm_git/vendor/ruby-git/tests/files/working/dot_git/objects/58/501cbd0fc5ce832f6b34d37243a520dc19a6cc +1 -0
- data/plugins/scm_git/vendor/ruby-git/tests/files/working/dot_git/objects/58/73a650a91eb238005444d2c637b451f687951b +0 -0
- data/plugins/scm_git/vendor/ruby-git/tests/files/working/dot_git/objects/5a/28efd2fcf55b7b58eb7cc66b5db836155bc2bb +0 -0
- data/plugins/scm_git/vendor/ruby-git/tests/files/working/dot_git/objects/5b/0be7da7cc9ecdb6c2de5f818c30a42fbd2c9fa +1 -0
- data/plugins/scm_git/vendor/ruby-git/tests/files/working/dot_git/objects/5c/16fb8b958b51f6008f9722b279b1fde0defb76 +3 -0
- data/plugins/scm_git/vendor/ruby-git/tests/files/working/dot_git/objects/5d/4606820736043f9eed2a6336661d6892c820a5 +0 -0
- data/plugins/scm_git/vendor/ruby-git/tests/files/working/dot_git/objects/5e/392652a881999392c2757cf9b783c5d47b67f7 +0 -0
- data/plugins/scm_git/vendor/ruby-git/tests/files/working/dot_git/objects/5e/53019b3238362144c2766f02a2c00d91fcc023 +2 -0
- data/plugins/scm_git/vendor/ruby-git/tests/files/working/dot_git/objects/62/70c7f48ca41e6fb41b745ddc1bffe521d83194 +2 -0
- data/plugins/scm_git/vendor/ruby-git/tests/files/working/dot_git/objects/62/7e1097cda3b2e3ad6ba4d3772c0985e1ff349c +0 -0
- data/plugins/scm_git/vendor/ruby-git/tests/files/working/dot_git/objects/62/bb94c53efae4d53fd0649d129baef4aca87af7 +3 -0
- data/plugins/scm_git/vendor/ruby-git/tests/files/working/dot_git/objects/62/c9331ffe97bb6388fb7968662b4e97d121e2da +0 -0
- data/plugins/scm_git/vendor/ruby-git/tests/files/working/dot_git/objects/63/1446ec50808846e31fff786c065e69da2c673b +0 -0
- data/plugins/scm_git/vendor/ruby-git/tests/files/working/dot_git/objects/64/d0c52ac4c061cf1705e3005dfd86fb70374a14 +0 -0
- data/plugins/scm_git/vendor/ruby-git/tests/files/working/dot_git/objects/66/80a909b0e02b297bedbe143ef789d297235358 +0 -0
- data/plugins/scm_git/vendor/ruby-git/tests/files/working/dot_git/objects/6b/790ddc5eab30f18cabdd0513e8f8dac0d2d3ed +0 -0
- data/plugins/scm_git/vendor/ruby-git/tests/files/working/dot_git/objects/6c/2d312ebd67eed4c7e97e3923b3667764e7360e +0 -0
- data/plugins/scm_git/vendor/ruby-git/tests/files/working/dot_git/objects/6d/e8fb35c2e4a69addd030f2dbb4f73fd4742b5b +0 -0
- data/plugins/scm_git/vendor/ruby-git/tests/files/working/dot_git/objects/6e/d281c757a969ffe22f3dcfa5830c532479c726 +0 -0
- data/plugins/scm_git/vendor/ruby-git/tests/files/working/dot_git/objects/70/714b02913c1a249a5ab05021742f0bc7065df7 +0 -0
- data/plugins/scm_git/vendor/ruby-git/tests/files/working/dot_git/objects/71/894b736711ea0a5def4f536009364d07ee4db3 +2 -0
- data/plugins/scm_git/vendor/ruby-git/tests/files/working/dot_git/objects/71/c9a23879ff0ac8c49b92d107f3f89c6d1b2d92 +1 -0
- data/plugins/scm_git/vendor/ruby-git/tests/files/working/dot_git/objects/73/b171450704ea4350f9f884426389fe04c6cd51 +0 -0
- data/plugins/scm_git/vendor/ruby-git/tests/files/working/dot_git/objects/74/32b657191a10587335e74ae6f0966a7eed2976 +0 -0
- data/plugins/scm_git/vendor/ruby-git/tests/files/working/dot_git/objects/79/e5b9e6ee5a1e6c52676a6332fe9163adaa92cb +0 -0
- data/plugins/scm_git/vendor/ruby-git/tests/files/working/dot_git/objects/7c/076f209839d7f910e8c84e41cc94898287ef45 +0 -0
- data/plugins/scm_git/vendor/ruby-git/tests/files/working/dot_git/objects/7c/60c6ab64c74d52f973d18cd1933318a8d9ae2e +0 -0
- data/plugins/scm_git/vendor/ruby-git/tests/files/working/dot_git/objects/7c/ac4f8d519d524ed025732ee220f6451665a770 +0 -0
- data/plugins/scm_git/vendor/ruby-git/tests/files/working/dot_git/objects/7f/5625f6b3c7213287a12c89017361248ed88936 +0 -0
- data/plugins/scm_git/vendor/ruby-git/tests/files/working/dot_git/objects/7f/86d16e0254f64f784198c6a55ef9bf7adbe7ce +0 -0
- data/plugins/scm_git/vendor/ruby-git/tests/files/working/dot_git/objects/7f/bfee9f8882ada1ec45c4925baf5649d96c4a16 +0 -0
- data/plugins/scm_git/vendor/ruby-git/tests/files/working/dot_git/objects/81/25fbe8605d2884e732a185c9a24abcc0d12a1f +0 -0
- data/plugins/scm_git/vendor/ruby-git/tests/files/working/dot_git/objects/81/d4d5e9b6db474d0f432aa31d44bf690d841e94 +0 -0
- data/plugins/scm_git/vendor/ruby-git/tests/files/working/dot_git/objects/81/f545324202466d44115656ea463a5bb114345f +0 -0
- data/plugins/scm_git/vendor/ruby-git/tests/files/working/dot_git/objects/82/d331cf4d3d4ee537c4f866cab2633b46a8d090 +0 -0
- data/plugins/scm_git/vendor/ruby-git/tests/files/working/dot_git/objects/83/c6a1f0d7d8df18a9d9bfe917707aec37868418 +0 -0
- data/plugins/scm_git/vendor/ruby-git/tests/files/working/dot_git/objects/85/8f46dd7496faf7af72102ca15cccff832b5377 +0 -0
- data/plugins/scm_git/vendor/ruby-git/tests/files/working/dot_git/objects/87/c56502c73149f006631129f85dff697e000356 +0 -0
- data/plugins/scm_git/vendor/ruby-git/tests/files/working/dot_git/objects/88/cf23d06f519bec7b824acd52b87a729555f2e7 +0 -0
- data/plugins/scm_git/vendor/ruby-git/tests/files/working/dot_git/objects/8a/3fb747983bf2a7f4ef136af4bfcf7993a19307 +0 -0
- data/plugins/scm_git/vendor/ruby-git/tests/files/working/dot_git/objects/8b/00d915a0ee5aeb32e0b166e1054c2901338c9d +0 -0
- data/plugins/scm_git/vendor/ruby-git/tests/files/working/dot_git/objects/8c/e3ee48a7e7ec697a99ee33700ec624548ad9e8 +0 -0
- data/plugins/scm_git/vendor/ruby-git/tests/files/working/dot_git/objects/8d/ae07ab9d98b5fe04d4d7ed804cc36441b68dab +0 -0
- data/plugins/scm_git/vendor/ruby-git/tests/files/working/dot_git/objects/8d/c79ae7616abf1e2d4d5d97d566f2b2f6cee043 +0 -0
- data/plugins/scm_git/vendor/ruby-git/tests/files/working/dot_git/objects/92/4dec9203af851c3b3e564697ab3004b35b3c2f +0 -0
- data/plugins/scm_git/vendor/ruby-git/tests/files/working/dot_git/objects/93/06c056ba3ef9dca6f6365af38148c71196533a +0 -0
- data/plugins/scm_git/vendor/ruby-git/tests/files/working/dot_git/objects/93/5badc874edd62a8629aaf103418092c73f0a56 +1 -0
- data/plugins/scm_git/vendor/ruby-git/tests/files/working/dot_git/objects/94/c827875e2cadb8bc8d4cdd900f19aa9e8634c7 +0 -0
- data/plugins/scm_git/vendor/ruby-git/tests/files/working/dot_git/objects/95/ef665df6ebd69842c5e74a24cb8a12225dee3e +0 -0
- data/plugins/scm_git/vendor/ruby-git/tests/files/working/dot_git/objects/98/fb6a686563963b8f7e552d747158adbc1c2bd6 +0 -0
- data/plugins/scm_git/vendor/ruby-git/tests/files/working/dot_git/objects/99/3dd9b1cdeab53e305886c91dbcbc8929eff22e +1 -0
- data/plugins/scm_git/vendor/ruby-git/tests/files/working/dot_git/objects/9a/e1fbd7636c99d34fdd395cf9bb21ad51417ce7 +1 -0
- data/plugins/scm_git/vendor/ruby-git/tests/files/working/dot_git/objects/9b/5149aa4ace4ef69461803b0ccbb21139e12626 +0 -0
- data/plugins/scm_git/vendor/ruby-git/tests/files/working/dot_git/objects/9d/3ad2f09cb7a1d4f4c91182c96f2be537fbc4ff +0 -0
- data/plugins/scm_git/vendor/ruby-git/tests/files/working/dot_git/objects/9d/6f937544dc3b936d6ee1466d6e216ba18d5686 +0 -0
- data/plugins/scm_git/vendor/ruby-git/tests/files/working/dot_git/objects/9f/a43bcd45af28e109e6f7b9a6ccd26e8e193a63 +0 -0
- data/plugins/scm_git/vendor/ruby-git/tests/files/working/dot_git/objects/a0/b3f35b3c39cfb12c4cc819bffe1cf54efb3642 +2 -0
- data/plugins/scm_git/vendor/ruby-git/tests/files/working/dot_git/objects/a1/15413501949f4f09811fd1aaecf136c012c7d7 +0 -0
- data/plugins/scm_git/vendor/ruby-git/tests/files/working/dot_git/objects/a1/a3069efcc64330fb6c66004e69b870da3d6186 +0 -0
- data/plugins/scm_git/vendor/ruby-git/tests/files/working/dot_git/objects/a3/62d30d5fe1021cabc4c90f073ba2511d5a43a1 +0 -0
- data/plugins/scm_git/vendor/ruby-git/tests/files/working/dot_git/objects/a3/c1f067074cdc9aa998cb5f3cad46a6f17aab2d +0 -0
- data/plugins/scm_git/vendor/ruby-git/tests/files/working/dot_git/objects/a3/db7143944dcfa006fefe7fb49c48793cb29ade +2 -0
- data/plugins/scm_git/vendor/ruby-git/tests/files/working/dot_git/objects/a4/4a5e945176ff31be83ffca3e7c68a8b6a45ea5 +1 -0
- data/plugins/scm_git/vendor/ruby-git/tests/files/working/dot_git/objects/a5/1546fabf88ddef5a9fd91b3989dd8ccae2edf3 +0 -0
- data/plugins/scm_git/vendor/ruby-git/tests/files/working/dot_git/objects/a6/b25c4b27ee99f93fd611154202af5f9e3c99de +2 -0
- data/plugins/scm_git/vendor/ruby-git/tests/files/working/dot_git/objects/a7/88a1cba299638a2c898fcfaae1f69a1549853d +0 -0
- data/plugins/scm_git/vendor/ruby-git/tests/files/working/dot_git/objects/a8/98e8a6b143188022863bc1cab0b5f7514624ba +0 -0
- data/plugins/scm_git/vendor/ruby-git/tests/files/working/dot_git/objects/a8/b607b221454c4cd7bc7831b2d19712bb4ff888 +0 -0
- data/plugins/scm_git/vendor/ruby-git/tests/files/working/dot_git/objects/a9/e2d9b71b616531f04a65ae5b972ba5d1f2cb93 +0 -0
- data/plugins/scm_git/vendor/ruby-git/tests/files/working/dot_git/objects/a9/e2f17562ae78a75dc855bb3dc9e87364195dcf +0 -0
- data/plugins/scm_git/vendor/ruby-git/tests/files/working/dot_git/objects/ab/16bc1812fd6226780a841300a2432dfd0c6719 +0 -0
- data/plugins/scm_git/vendor/ruby-git/tests/files/working/dot_git/objects/ac/8f48bbb7b31c945ba6a4fbe6950d009a5d8373 +0 -0
- data/plugins/scm_git/vendor/ruby-git/tests/files/working/dot_git/objects/ae/21cabd23aee99a719fc828977c0df9e8b19363 +0 -0
- data/plugins/scm_git/vendor/ruby-git/tests/files/working/dot_git/objects/b0/3003311ad3fa368b475df58390353868e13c91 +2 -0
- data/plugins/scm_git/vendor/ruby-git/tests/files/working/dot_git/objects/b0/ee249c5e5cc9464f3bc0034ab05632dcb87a23 +0 -0
- data/plugins/scm_git/vendor/ruby-git/tests/files/working/dot_git/objects/b1/288f8beeaa6cf048c3a9f578d4e266fab8820e +0 -0
- data/plugins/scm_git/vendor/ruby-git/tests/files/working/dot_git/objects/b1/5336206c9040f4c52660b3f3c76ee02ccece56 +0 -0
- data/plugins/scm_git/vendor/ruby-git/tests/files/working/dot_git/objects/b1/b18f5bea24648a1b08e5bba88728c15ec3cb50 +2 -0
- data/plugins/scm_git/vendor/ruby-git/tests/files/working/dot_git/objects/b4/5724ee906d2561901208ba924add09ab95ccb3 +0 -0
- data/plugins/scm_git/vendor/ruby-git/tests/files/working/dot_git/objects/b5/d8fc3cb740eb643c66eb5f4a97345fdb806259 +0 -0
- data/plugins/scm_git/vendor/ruby-git/tests/files/working/dot_git/objects/b6/153b8fe540288d66b974ae05113338ab1a61f0 +0 -0
- data/plugins/scm_git/vendor/ruby-git/tests/files/working/dot_git/objects/b6/987bc1201ad19774c43c0ea8078f6f51d76bcb +0 -0
- data/plugins/scm_git/vendor/ruby-git/tests/files/working/dot_git/objects/b6/9e6acd87e5f9114ce6580b095ef1057a8fe5bb +0 -0
- data/plugins/scm_git/vendor/ruby-git/tests/files/working/dot_git/objects/b9/8f4909807c8c84a1dc1b62b4a339ae1777f369 +3 -0
- data/plugins/scm_git/vendor/ruby-git/tests/files/working/dot_git/objects/ba/492c62b6227d7f3507b4dcc6e6d5f13790eabf +0 -0
- data/plugins/scm_git/vendor/ruby-git/tests/files/working/dot_git/objects/ba/c335cb9dc058a477d04cde34c07d1f70d16fb9 +0 -0
- data/plugins/scm_git/vendor/ruby-git/tests/files/working/dot_git/objects/bb/0850568bb43049031a38b01ddb60e4a487f823 +0 -0
- data/plugins/scm_git/vendor/ruby-git/tests/files/working/dot_git/objects/be/b14380ef26540efcad06bedcd0e302b6bce70e +0 -0
- data/plugins/scm_git/vendor/ruby-git/tests/files/working/dot_git/objects/c1/3142dd26a1f6f38403a17f6c411cb621b9a1cd +0 -0
- data/plugins/scm_git/vendor/ruby-git/tests/files/working/dot_git/objects/c1/8b4e9b0829411705d7fa9a1570a20d88780817 +0 -0
- data/plugins/scm_git/vendor/ruby-git/tests/files/working/dot_git/objects/c5/a3fdb33f052b8f17dac83c533b62244226f4ba +0 -0
- data/plugins/scm_git/vendor/ruby-git/tests/files/working/dot_git/objects/c6/567e2feccce3893ae0aaac2bf97807338aa8d4 +0 -0
- data/plugins/scm_git/vendor/ruby-git/tests/files/working/dot_git/objects/cb/45eef6fa1ad913137d91c6b81d2b42d69094a6 +0 -0
- data/plugins/scm_git/vendor/ruby-git/tests/files/working/dot_git/objects/cd/0d59357b36a447ff27a7c176b46e0a319b42df +0 -0
- data/plugins/scm_git/vendor/ruby-git/tests/files/working/dot_git/objects/cd/4291452a61ff8b57cf5510addc8ddc5630748e +0 -0
- data/plugins/scm_git/vendor/ruby-git/tests/files/working/dot_git/objects/cf/7135368cc3bf4920ceeaeebd083e098cfad355 +4 -0
- data/plugins/scm_git/vendor/ruby-git/tests/files/working/dot_git/objects/cf/b9952c3a28831144a0fac7ea5a2d8517f466c4 +0 -0
- data/plugins/scm_git/vendor/ruby-git/tests/files/working/dot_git/objects/d0/0491fd7e5bb6fa28c517a0bb32b8b506539d4d +0 -0
- data/plugins/scm_git/vendor/ruby-git/tests/files/working/dot_git/objects/d1/4cbc09cc34fb6450b2e96432102be51c8292b8 +0 -0
- data/plugins/scm_git/vendor/ruby-git/tests/files/working/dot_git/objects/d3/d171221e87a30e059d638f155f899595d96b71 +0 -0
- data/plugins/scm_git/vendor/ruby-git/tests/files/working/dot_git/objects/d5/b9587b65731e25216743b0caca72051a760211 +2 -0
- data/plugins/scm_git/vendor/ruby-git/tests/files/working/dot_git/objects/d6/a3aab3e38bc16688b4e636a91e462434210878 +0 -0
- data/plugins/scm_git/vendor/ruby-git/tests/files/working/dot_git/objects/d6/f31c35d7e010e50568c0d605227028aa7bac66 +0 -0
- data/plugins/scm_git/vendor/ruby-git/tests/files/working/dot_git/objects/d7/875788aeafdd8e317880c00e3372f683cad91e +0 -0
- data/plugins/scm_git/vendor/ruby-git/tests/files/working/dot_git/objects/d7/d8a71a719e2a4ca501991a66dab47df804f6ad +0 -0
- data/plugins/scm_git/vendor/ruby-git/tests/files/working/dot_git/objects/d7/e844eec32d74a3d37c4ce02d7138658e1035d6 +0 -0
- data/plugins/scm_git/vendor/ruby-git/tests/files/working/dot_git/objects/da/597fb7fba247a5b59d917e90342cf4b9695905 +0 -0
- data/plugins/scm_git/vendor/ruby-git/tests/files/working/dot_git/objects/da/7b788b1575936a4381050610a37737c70b55a0 +1 -0
- data/plugins/scm_git/vendor/ruby-git/tests/files/working/dot_git/objects/de/996da0ef3dcee1a28aef9243aa3e255eb825b5 +0 -0
- data/plugins/scm_git/vendor/ruby-git/tests/files/working/dot_git/objects/de/d54b45e4d49816f6d4256e74d45ba2bb351357 +0 -0
- data/plugins/scm_git/vendor/ruby-git/tests/files/working/dot_git/objects/e3/6f723934fd1d67c7d21538751f0b1e941141db +0 -0
- data/plugins/scm_git/vendor/ruby-git/tests/files/working/dot_git/objects/e3/ebef76525fe9e6e8dc739934a08512dff777c0 +0 -0
- data/plugins/scm_git/vendor/ruby-git/tests/files/working/dot_git/objects/e5/0fa6835cb99747346f19fea5f1ba939da4205f +2 -0
- data/plugins/scm_git/vendor/ruby-git/tests/files/working/dot_git/objects/e5/650a5c9c4b5a4415195bfb01d4d8dccbc8221b +0 -0
- data/plugins/scm_git/vendor/ruby-git/tests/files/working/dot_git/objects/e5/76bdfc9ed4627ac954f9390cf7a6151ad2a73e +0 -0
- data/plugins/scm_git/vendor/ruby-git/tests/files/working/dot_git/objects/e6/9de29bb2d1d6434b8b29ae775ad8c2e48c5391 +0 -0
- data/plugins/scm_git/vendor/ruby-git/tests/files/working/dot_git/objects/e7/ea5938f9c009d32235050bca991d0b9533e440 +0 -0
- data/plugins/scm_git/vendor/ruby-git/tests/files/working/dot_git/objects/e8/183f05f5db68b3934e93f4bf6bed2bb664e0b5 +0 -0
- data/plugins/scm_git/vendor/ruby-git/tests/files/working/dot_git/objects/e8/bd03b163f82fba4560c11839d49361a78dec85 +0 -0
- data/plugins/scm_git/vendor/ruby-git/tests/files/working/dot_git/objects/e9/0de8268373e4fd5ab13310b7745d47ec16813c +0 -0
- data/plugins/scm_git/vendor/ruby-git/tests/files/working/dot_git/objects/ec/16a327a6a98367d03369b4e998baf3db379313 +0 -0
- data/plugins/scm_git/vendor/ruby-git/tests/files/working/dot_git/objects/ec/1e3d44e160e18dbfbaa80b5b0780ccc03e678e +0 -0
- data/plugins/scm_git/vendor/ruby-git/tests/files/working/dot_git/objects/ed/551aa66cf0c6f1a078832f80899faff0ae88dc +0 -0
- data/plugins/scm_git/vendor/ruby-git/tests/files/working/dot_git/objects/f1/25480ee106989ec4d86554c0d5a1487ad4336a +1 -0
- data/plugins/scm_git/vendor/ruby-git/tests/files/working/dot_git/objects/f1/410f8735f6f73d3599eb9b5cdd2fb70373335c +3 -0
- data/plugins/scm_git/vendor/ruby-git/tests/files/working/dot_git/objects/f2/02cb755135d4263589602783b04fb32a079d88 +0 -0
- data/plugins/scm_git/vendor/ruby-git/tests/files/working/dot_git/objects/f2/ff401fb3fc81f8abb3ca15247aadc1e22b6288 +0 -0
- data/plugins/scm_git/vendor/ruby-git/tests/files/working/dot_git/objects/f5/501de98279c6454f510188873476f3ead0cee6 +4 -0
- data/plugins/scm_git/vendor/ruby-git/tests/files/working/dot_git/objects/f7/5f313ca30e534aa9c42463e85108e682d3a14a +0 -0
- data/plugins/scm_git/vendor/ruby-git/tests/files/working/dot_git/objects/f8/e9c6748331411c0d3511f90bd4e0a1a30acff0 +0 -0
- data/plugins/scm_git/vendor/ruby-git/tests/files/working/dot_git/objects/f9/bce8995109cfab475d043a7dd9156d5e574ed3 +0 -0
- data/plugins/scm_git/vendor/ruby-git/tests/files/working/dot_git/objects/fa/6312f71abb153ada6a0399ad710d21bb61e4d8 +0 -0
- data/plugins/scm_git/vendor/ruby-git/tests/files/working/dot_git/objects/fb/8e78840d79085abf50edebf5b9d6b73ee0fb4c +0 -0
- data/plugins/scm_git/vendor/ruby-git/tests/files/working/dot_git/objects/fc/b49fa99454f804799a12095292edbca48779ab +0 -0
- data/plugins/scm_git/vendor/ruby-git/tests/files/working/dot_git/objects/fe/b2ccf88397c2d93f381176067be2727eba330b +0 -0
- data/plugins/scm_git/vendor/ruby-git/tests/files/working/dot_git/refs/heads/git_grep +1 -0
- data/plugins/scm_git/vendor/ruby-git/tests/files/working/dot_git/refs/heads/master +1 -0
- data/plugins/scm_git/vendor/ruby-git/tests/files/working/dot_git/refs/heads/test +1 -0
- data/plugins/scm_git/vendor/ruby-git/tests/files/working/dot_git/refs/heads/test_branches +1 -0
- data/plugins/scm_git/vendor/ruby-git/tests/files/working/dot_git/refs/heads/test_object +1 -0
- data/plugins/scm_git/vendor/ruby-git/tests/files/working/dot_git/refs/remotes/working/master +1 -0
- data/plugins/scm_git/vendor/ruby-git/tests/files/working/dot_git/refs/tags/gitsearch1 +1 -0
- data/plugins/scm_git/vendor/ruby-git/tests/files/working/dot_git/refs/tags/v2.5 +1 -0
- data/plugins/scm_git/vendor/ruby-git/tests/files/working/dot_git/refs/tags/v2.6 +1 -0
- data/plugins/scm_git/vendor/ruby-git/tests/files/working/dot_git/refs/tags/v2.7 +1 -0
- data/plugins/scm_git/vendor/ruby-git/tests/files/working/dot_git/refs/tags/v2.8 +1 -0
- data/plugins/scm_git/vendor/ruby-git/tests/files/working/ex_dir/ex.txt +0 -0
- data/plugins/scm_git/vendor/ruby-git/tests/files/working/example.txt +1 -0
- data/plugins/scm_git/vendor/ruby-git/tests/files/working/scott/newfile +1 -0
- data/plugins/scm_git/vendor/ruby-git/tests/files/working/scott/text.txt +8 -0
- data/plugins/scm_git/vendor/ruby-git/tests/test_helper.rb +67 -0
- data/plugins/scm_git/vendor/ruby-git/tests/units/test_archive.rb +55 -0
- data/plugins/scm_git/vendor/ruby-git/tests/units/test_bare.rb +41 -0
- data/plugins/scm_git/vendor/ruby-git/tests/units/test_branch.rb +92 -0
- data/plugins/scm_git/vendor/ruby-git/tests/units/test_config.rb +31 -0
- data/plugins/scm_git/vendor/ruby-git/tests/units/test_diff.rb +88 -0
- data/plugins/scm_git/vendor/ruby-git/tests/units/test_each_conflict.rb +49 -0
- data/plugins/scm_git/vendor/ruby-git/tests/units/test_git_path.rb +45 -0
- data/plugins/scm_git/vendor/ruby-git/tests/units/test_index_ops.rb +94 -0
- data/plugins/scm_git/vendor/ruby-git/tests/units/test_init.rb +75 -0
- data/plugins/scm_git/vendor/ruby-git/tests/units/test_lib.rb +168 -0
- data/plugins/scm_git/vendor/ruby-git/tests/units/test_log.rb +69 -0
- data/plugins/scm_git/vendor/ruby-git/tests/units/test_logger.rb +38 -0
- data/plugins/scm_git/vendor/ruby-git/tests/units/test_merge.rb +104 -0
- data/plugins/scm_git/vendor/ruby-git/tests/units/test_object.rb +138 -0
- data/plugins/scm_git/vendor/ruby-git/tests/units/test_remotes.rb +85 -0
- data/plugins/scm_git/vendor/ruby-git/tests/units/test_repack.rb +30 -0
- data/plugins/scm_git/vendor/ruby-git/tests/units/test_stashes.rb +36 -0
- data/plugins/scm_git/vendor/ruby-git/tests/units/test_tags.rb +35 -0
- data/plugins/scm_git/vendor/ruby-git/tests/units/test_tree_ops.rb +121 -0
- data/plugins/scm_hg/lib/scm_hg.rb +30 -0
- data/plugins/scm_hg/plugin.rb +7 -0
- data/plugins/scm_svn/lib/scm_svn.rb +30 -0
- data/plugins/scm_svn/plugin.rb +7 -0
- data/plugins/strip_trailing_spaces/lib/strip_trailing_spaces.rb +10 -5
- data/plugins/textmate/ATTRIBUTION +4 -0
- data/plugins/textmate/features/bundle_tree.feature +23 -0
- data/plugins/textmate/features/step_definitions/tree_steps.rb +57 -0
- data/plugins/textmate/features/support/env.rb +19 -0
- data/plugins/textmate/features/support/test_bundle.tmbundle/Snippets/If.tmSnippet +18 -0
- data/plugins/textmate/features/support/test_bundle.tmbundle/Snippets/If__Else.tmSnippet +20 -0
- data/plugins/textmate/features/support/test_bundle.tmbundle/Snippets/Include.tmSnippet +16 -0
- data/plugins/textmate/features/support/test_bundle.tmbundle/Snippets/Loop.tmSnippet +18 -0
- data/plugins/textmate/features/support/test_bundle.tmbundle/Snippets/Unless.tmSnippet +18 -0
- data/plugins/textmate/features/support/test_bundle.tmbundle/Snippets/Var.tmSnippet +16 -0
- data/plugins/textmate/features/support/test_bundle.tmbundle/Snippets/next_If__Else.tmSnippet +20 -0
- data/plugins/textmate/features/support/test_bundle.tmbundle/info.plist +26 -0
- data/plugins/textmate/icons/document-snippet.png +0 -0
- data/plugins/textmate/icons/tree_mode.gif +0 -0
- data/plugins/textmate/icons/ui-menu-blue.png +0 -0
- data/plugins/textmate/lib/textmate.rb +82 -27
- data/plugins/textmate/lib/textmate/bundle.rb +32 -28
- data/plugins/textmate/lib/textmate/commands.rb +79 -0
- data/plugins/textmate/lib/textmate/tree_mirror.rb +205 -0
- data/plugins/todo_list/README.md +22 -0
- data/plugins/todo_list/lib/todo_list.rb +41 -0
- data/plugins/todo_list/lib/todo_list/file_parser.rb +54 -0
- data/plugins/todo_list/lib/todo_list/todo_controller.rb +137 -0
- data/plugins/todo_list/plugin.rb +11 -0
- data/plugins/todo_list/views/index.html.erb +22 -0
- data/plugins/tree_view_swt/lib/tree_view_swt.rb +3 -1
- metadata +4595 -4174
@@ -0,0 +1,104 @@
|
|
1
|
+
module Git
|
2
|
+
class Branch < Path
|
3
|
+
|
4
|
+
attr_accessor :full, :remote, :name
|
5
|
+
|
6
|
+
def initialize(base, name)
|
7
|
+
@remote = nil
|
8
|
+
@full = name
|
9
|
+
@base = base
|
10
|
+
@gcommit = nil
|
11
|
+
@stashes = nil
|
12
|
+
|
13
|
+
parts = name.split('/')
|
14
|
+
if parts[1]
|
15
|
+
@remote = Git::Remote.new(@base, parts[0])
|
16
|
+
@name = parts[1]
|
17
|
+
else
|
18
|
+
@name = parts[0]
|
19
|
+
end
|
20
|
+
end
|
21
|
+
|
22
|
+
def gcommit
|
23
|
+
@gcommit ||= @base.gcommit(@full)
|
24
|
+
@gcommit
|
25
|
+
end
|
26
|
+
|
27
|
+
def stashes
|
28
|
+
@stashes ||= Git::Stashes.new(@base)
|
29
|
+
end
|
30
|
+
|
31
|
+
def checkout
|
32
|
+
check_if_create
|
33
|
+
@base.checkout(@full)
|
34
|
+
end
|
35
|
+
|
36
|
+
def archive(file, opts = {})
|
37
|
+
@base.lib.archive(@full, file, opts)
|
38
|
+
end
|
39
|
+
|
40
|
+
# g.branch('new_branch').in_branch do
|
41
|
+
# # create new file
|
42
|
+
# # do other stuff
|
43
|
+
# return true # auto commits and switches back
|
44
|
+
# end
|
45
|
+
def in_branch (message = 'in branch work')
|
46
|
+
old_current = @base.lib.branch_current
|
47
|
+
checkout
|
48
|
+
if yield
|
49
|
+
@base.commit_all(message)
|
50
|
+
else
|
51
|
+
@base.reset_hard
|
52
|
+
end
|
53
|
+
@base.checkout(old_current)
|
54
|
+
end
|
55
|
+
|
56
|
+
def create
|
57
|
+
check_if_create
|
58
|
+
end
|
59
|
+
|
60
|
+
def delete
|
61
|
+
@base.lib.branch_delete(@name)
|
62
|
+
end
|
63
|
+
|
64
|
+
def current
|
65
|
+
determine_current
|
66
|
+
end
|
67
|
+
|
68
|
+
def merge(branch = nil, message = nil)
|
69
|
+
if branch
|
70
|
+
in_branch do
|
71
|
+
@base.merge(branch, message)
|
72
|
+
false
|
73
|
+
end
|
74
|
+
# merge a branch into this one
|
75
|
+
else
|
76
|
+
# merge this branch into the current one
|
77
|
+
@base.merge(@name)
|
78
|
+
end
|
79
|
+
end
|
80
|
+
|
81
|
+
def update_ref(commit)
|
82
|
+
@base.lib.update_ref(@full, commit)
|
83
|
+
end
|
84
|
+
|
85
|
+
def to_a
|
86
|
+
[@full]
|
87
|
+
end
|
88
|
+
|
89
|
+
def to_s
|
90
|
+
@full
|
91
|
+
end
|
92
|
+
|
93
|
+
private
|
94
|
+
|
95
|
+
def check_if_create
|
96
|
+
@base.lib.branch_new(@name) rescue nil
|
97
|
+
end
|
98
|
+
|
99
|
+
def determine_current
|
100
|
+
@base.lib.branch_current == @name
|
101
|
+
end
|
102
|
+
|
103
|
+
end
|
104
|
+
end
|
@@ -0,0 +1,48 @@
|
|
1
|
+
module Git
|
2
|
+
|
3
|
+
# object that holds all the available branches
|
4
|
+
class Branches
|
5
|
+
include Enumerable
|
6
|
+
|
7
|
+
def initialize(base)
|
8
|
+
@branches = {}
|
9
|
+
|
10
|
+
@base = base
|
11
|
+
|
12
|
+
@base.lib.branches_all.each do |b|
|
13
|
+
@branches[b[0]] = Git::Branch.new(@base, b[0])
|
14
|
+
end
|
15
|
+
end
|
16
|
+
|
17
|
+
def local
|
18
|
+
self.select { |b| !b.remote }
|
19
|
+
end
|
20
|
+
|
21
|
+
def remote
|
22
|
+
self.select { |b| b.remote }
|
23
|
+
end
|
24
|
+
|
25
|
+
# array like methods
|
26
|
+
|
27
|
+
def size
|
28
|
+
@branches.size
|
29
|
+
end
|
30
|
+
|
31
|
+
def each(&block)
|
32
|
+
@branches.values.each(&block)
|
33
|
+
end
|
34
|
+
|
35
|
+
def [](symbol)
|
36
|
+
@branches[symbol.to_s]
|
37
|
+
end
|
38
|
+
|
39
|
+
def to_s
|
40
|
+
out = ''
|
41
|
+
@branches.each do |k, b|
|
42
|
+
out << (b.current ? '* ' : ' ') << b.to_s << "\n"
|
43
|
+
end
|
44
|
+
out
|
45
|
+
end
|
46
|
+
|
47
|
+
end
|
48
|
+
end
|
@@ -0,0 +1,146 @@
|
|
1
|
+
module Git
|
2
|
+
|
3
|
+
# object that holds the last X commits on given branch
|
4
|
+
class Diff
|
5
|
+
include Enumerable
|
6
|
+
|
7
|
+
def initialize(base, from = nil, to = nil)
|
8
|
+
@base = base
|
9
|
+
@from = from.to_s
|
10
|
+
@to = to.to_s
|
11
|
+
|
12
|
+
@path = nil
|
13
|
+
@full_diff = nil
|
14
|
+
@full_diff_files = nil
|
15
|
+
@stats = nil
|
16
|
+
end
|
17
|
+
attr_reader :from, :to
|
18
|
+
|
19
|
+
def path(path)
|
20
|
+
@path = path
|
21
|
+
return self
|
22
|
+
end
|
23
|
+
|
24
|
+
def size
|
25
|
+
cache_stats
|
26
|
+
@stats[:total][:files]
|
27
|
+
end
|
28
|
+
|
29
|
+
def lines
|
30
|
+
cache_stats
|
31
|
+
@stats[:total][:lines]
|
32
|
+
end
|
33
|
+
|
34
|
+
def deletions
|
35
|
+
cache_stats
|
36
|
+
@stats[:total][:deletions]
|
37
|
+
end
|
38
|
+
|
39
|
+
def insertions
|
40
|
+
cache_stats
|
41
|
+
@stats[:total][:insertions]
|
42
|
+
end
|
43
|
+
|
44
|
+
def stats
|
45
|
+
cache_stats
|
46
|
+
@stats
|
47
|
+
end
|
48
|
+
|
49
|
+
# if file is provided and is writable, it will write the patch into the file
|
50
|
+
def patch(file = nil)
|
51
|
+
cache_full
|
52
|
+
@full_diff
|
53
|
+
end
|
54
|
+
alias_method :to_s, :patch
|
55
|
+
|
56
|
+
# enumerable methods
|
57
|
+
|
58
|
+
def [](key)
|
59
|
+
process_full
|
60
|
+
@full_diff_files.assoc(key)[1]
|
61
|
+
end
|
62
|
+
|
63
|
+
def each(&block) # :yields: each Git::DiffFile in turn
|
64
|
+
process_full
|
65
|
+
@full_diff_files.map { |file| file[1] }.each(&block)
|
66
|
+
end
|
67
|
+
|
68
|
+
class DiffFile
|
69
|
+
attr_accessor :patch, :path, :mode, :src, :dst, :type
|
70
|
+
@base = nil
|
71
|
+
|
72
|
+
def initialize(base, hash)
|
73
|
+
@base = base
|
74
|
+
@patch = hash[:patch]
|
75
|
+
@path = hash[:path]
|
76
|
+
@mode = hash[:mode]
|
77
|
+
@src = hash[:src]
|
78
|
+
@dst = hash[:dst]
|
79
|
+
@type = hash[:type]
|
80
|
+
@binary = hash[:binary]
|
81
|
+
end
|
82
|
+
|
83
|
+
def binary?
|
84
|
+
!!@binary
|
85
|
+
end
|
86
|
+
|
87
|
+
def blob(type = :dst)
|
88
|
+
if type == :src
|
89
|
+
@base.object(@src) if @src != '0000000'
|
90
|
+
else
|
91
|
+
@base.object(@dst) if @dst != '0000000'
|
92
|
+
end
|
93
|
+
end
|
94
|
+
end
|
95
|
+
|
96
|
+
private
|
97
|
+
|
98
|
+
def cache_full
|
99
|
+
unless @full_diff
|
100
|
+
@full_diff = @base.lib.diff_full(@from, @to, {:path_limiter => @path})
|
101
|
+
end
|
102
|
+
end
|
103
|
+
|
104
|
+
def process_full
|
105
|
+
unless @full_diff_files
|
106
|
+
cache_full
|
107
|
+
@full_diff_files = process_full_diff
|
108
|
+
end
|
109
|
+
end
|
110
|
+
|
111
|
+
def cache_stats
|
112
|
+
unless @stats
|
113
|
+
@stats = @base.lib.diff_stats(@from, @to, {:path_limiter => @path})
|
114
|
+
end
|
115
|
+
end
|
116
|
+
|
117
|
+
# break up @diff_full
|
118
|
+
def process_full_diff
|
119
|
+
final = {}
|
120
|
+
current_file = nil
|
121
|
+
@full_diff.split("\n").each do |line|
|
122
|
+
if m = /diff --git a\/(.*?) b\/(.*?)/.match(line)
|
123
|
+
current_file = m[1]
|
124
|
+
final[current_file] = {:patch => line, :path => current_file,
|
125
|
+
:mode => '', :src => '', :dst => '', :type => 'modified'}
|
126
|
+
else
|
127
|
+
if m = /index (.......)\.\.(.......)( ......)*/.match(line)
|
128
|
+
final[current_file][:src] = m[1]
|
129
|
+
final[current_file][:dst] = m[2]
|
130
|
+
final[current_file][:mode] = m[3].strip if m[3]
|
131
|
+
end
|
132
|
+
if m = /(.*?) file mode (......)/.match(line)
|
133
|
+
final[current_file][:type] = m[1]
|
134
|
+
final[current_file][:mode] = m[2]
|
135
|
+
end
|
136
|
+
if m = /^Binary files /.match(line)
|
137
|
+
final[current_file][:binary] = true
|
138
|
+
end
|
139
|
+
final[current_file][:patch] << "\n" + line
|
140
|
+
end
|
141
|
+
end
|
142
|
+
final.map { |e| [e[0], DiffFile.new(@base, e[1])] }
|
143
|
+
end
|
144
|
+
|
145
|
+
end
|
146
|
+
end
|
@@ -0,0 +1,730 @@
|
|
1
|
+
require 'tempfile'
|
2
|
+
|
3
|
+
module Git
|
4
|
+
|
5
|
+
class GitExecuteError < StandardError
|
6
|
+
end
|
7
|
+
|
8
|
+
class Lib
|
9
|
+
|
10
|
+
def initialize(base = nil, logger = nil)
|
11
|
+
@git_dir = nil
|
12
|
+
@git_index_file = nil
|
13
|
+
@git_work_dir = nil
|
14
|
+
@path = nil
|
15
|
+
|
16
|
+
if base.is_a?(Git::Base)
|
17
|
+
@git_dir = base.repo.path
|
18
|
+
@git_index_file = base.index.path if base.index
|
19
|
+
@git_work_dir = base.dir.path if base.dir
|
20
|
+
elsif base.is_a?(Hash)
|
21
|
+
@git_dir = base[:repository]
|
22
|
+
@git_index_file = base[:index]
|
23
|
+
@git_work_dir = base[:working_directory]
|
24
|
+
end
|
25
|
+
@logger = logger
|
26
|
+
end
|
27
|
+
|
28
|
+
def init
|
29
|
+
command('init')
|
30
|
+
end
|
31
|
+
|
32
|
+
# tries to clone the given repo
|
33
|
+
#
|
34
|
+
# returns {:repository} (if bare)
|
35
|
+
# {:working_directory} otherwise
|
36
|
+
#
|
37
|
+
# accepts options:
|
38
|
+
# :remote:: name of remote (rather than 'origin')
|
39
|
+
# :bare:: no working directory
|
40
|
+
# :depth:: the number of commits back to pull
|
41
|
+
#
|
42
|
+
# TODO - make this work with SSH password or auth_key
|
43
|
+
#
|
44
|
+
def clone(repository, name, opts = {})
|
45
|
+
@path = opts[:path] || '.'
|
46
|
+
clone_dir = opts[:path] ? File.join(@path, name) : name
|
47
|
+
|
48
|
+
arr_opts = []
|
49
|
+
arr_opts << "--bare" if opts[:bare]
|
50
|
+
arr_opts << "-o" << opts[:remote] if opts[:remote]
|
51
|
+
arr_opts << "--depth" << opts[:depth].to_i if opts[:depth] && opts[:depth].to_i > 0
|
52
|
+
|
53
|
+
arr_opts << '--'
|
54
|
+
arr_opts << repository
|
55
|
+
arr_opts << clone_dir
|
56
|
+
|
57
|
+
command('clone', arr_opts)
|
58
|
+
|
59
|
+
opts[:bare] ? {:repository => clone_dir} : {:working_directory => clone_dir}
|
60
|
+
end
|
61
|
+
|
62
|
+
|
63
|
+
## READ COMMANDS ##
|
64
|
+
|
65
|
+
|
66
|
+
def log_commits(opts = {})
|
67
|
+
arr_opts = ['--pretty=oneline']
|
68
|
+
arr_opts << "-#{opts[:count]}" if opts[:count]
|
69
|
+
arr_opts << "--since=#{opts[:since]}" if opts[:since].is_a? String
|
70
|
+
arr_opts << "--until=#{opts[:until]}" if opts[:until].is_a? String
|
71
|
+
arr_opts << "--grep=#{opts[:grep]}" if opts[:grep].is_a? String
|
72
|
+
arr_opts << "--author=#{opts[:author]}" if opts[:author].is_a? String
|
73
|
+
arr_opts << "#{opts[:between][0].to_s}..#{opts[:between][1].to_s}" if (opts[:between] && opts[:between].size == 2)
|
74
|
+
arr_opts << opts[:object] if opts[:object].is_a? String
|
75
|
+
arr_opts << '--' << opts[:path_limiter] if opts[:path_limiter].is_a? String
|
76
|
+
|
77
|
+
command_lines('log', arr_opts, true).map { |l| l.split.first }
|
78
|
+
end
|
79
|
+
|
80
|
+
def full_log_commits(opts = {})
|
81
|
+
arr_opts = ['--pretty=raw']
|
82
|
+
arr_opts << "-#{opts[:count]}" if opts[:count]
|
83
|
+
arr_opts << "--skip=#{opts[:skip]}" if opts[:skip]
|
84
|
+
arr_opts << "--since=#{opts[:since]}" if opts[:since].is_a? String
|
85
|
+
arr_opts << "--until=#{opts[:until]}" if opts[:until].is_a? String
|
86
|
+
arr_opts << "--grep=#{opts[:grep]}" if opts[:grep].is_a? String
|
87
|
+
arr_opts << "--author=#{opts[:author]}" if opts[:author].is_a? String
|
88
|
+
arr_opts << "#{opts[:between][0].to_s}..#{opts[:between][1].to_s}" if (opts[:between] && opts[:between].size == 2)
|
89
|
+
arr_opts << opts[:object] if opts[:object].is_a? String
|
90
|
+
arr_opts << '--' << opts[:path_limiter] if opts[:path_limiter].is_a? String
|
91
|
+
|
92
|
+
full_log = command_lines('log', arr_opts, true)
|
93
|
+
process_commit_data(full_log)
|
94
|
+
end
|
95
|
+
|
96
|
+
def revparse(string)
|
97
|
+
return string if string =~ /[A-Fa-f0-9]{40}/ # passing in a sha - just no-op it
|
98
|
+
rev = ['head', 'remotes', 'tags'].map do |d|
|
99
|
+
File.join(@git_dir, 'refs', d, string)
|
100
|
+
end.find do |path|
|
101
|
+
File.file?(path)
|
102
|
+
end
|
103
|
+
return File.read(rev).chomp if rev
|
104
|
+
command('rev-parse', string)
|
105
|
+
end
|
106
|
+
|
107
|
+
def namerev(string)
|
108
|
+
command('name-rev', string).split[1]
|
109
|
+
end
|
110
|
+
|
111
|
+
def object_type(sha)
|
112
|
+
command('cat-file', ['-t', sha])
|
113
|
+
end
|
114
|
+
|
115
|
+
def object_size(sha)
|
116
|
+
command('cat-file', ['-s', sha]).to_i
|
117
|
+
end
|
118
|
+
|
119
|
+
# returns useful array of raw commit object data
|
120
|
+
def commit_data(sha)
|
121
|
+
sha = sha.to_s
|
122
|
+
cdata = command_lines('cat-file', ['commit', sha])
|
123
|
+
process_commit_data(cdata, sha, 0)
|
124
|
+
end
|
125
|
+
|
126
|
+
def process_commit_data(data, sha = nil, indent = 4)
|
127
|
+
in_message = false
|
128
|
+
|
129
|
+
if sha
|
130
|
+
hsh = {'sha' => sha, 'message' => '', 'parent' => []}
|
131
|
+
else
|
132
|
+
hsh_array = []
|
133
|
+
end
|
134
|
+
|
135
|
+
data.each do |line|
|
136
|
+
line = line.chomp
|
137
|
+
if line == ''
|
138
|
+
in_message = !in_message
|
139
|
+
elsif in_message
|
140
|
+
hsh['message'] << line[indent..-1] << "\n"
|
141
|
+
else
|
142
|
+
data = line.split
|
143
|
+
key = data.shift
|
144
|
+
value = data.join(' ')
|
145
|
+
if key == 'commit'
|
146
|
+
sha = value
|
147
|
+
hsh_array << hsh if hsh
|
148
|
+
hsh = {'sha' => sha, 'message' => '', 'parent' => []}
|
149
|
+
end
|
150
|
+
if key == 'parent'
|
151
|
+
hsh[key] << value
|
152
|
+
else
|
153
|
+
hsh[key] = value
|
154
|
+
end
|
155
|
+
end
|
156
|
+
end
|
157
|
+
|
158
|
+
if hsh_array
|
159
|
+
hsh_array << hsh if hsh
|
160
|
+
hsh_array
|
161
|
+
else
|
162
|
+
hsh
|
163
|
+
end
|
164
|
+
end
|
165
|
+
|
166
|
+
def object_contents(sha, &block)
|
167
|
+
command('cat-file', ['-p', sha], &block)
|
168
|
+
end
|
169
|
+
|
170
|
+
def ls_tree(sha)
|
171
|
+
data = {'blob' => {}, 'tree' => {}}
|
172
|
+
|
173
|
+
command_lines('ls-tree', sha).each do |line|
|
174
|
+
(info, filenm) = line.split("\t")
|
175
|
+
(mode, type, sha) = info.split
|
176
|
+
data[type][filenm] = {:mode => mode, :sha => sha}
|
177
|
+
end
|
178
|
+
|
179
|
+
data
|
180
|
+
end
|
181
|
+
|
182
|
+
def mv(file1, file2)
|
183
|
+
command_lines('mv', ['--', file1, file2])
|
184
|
+
end
|
185
|
+
|
186
|
+
def full_tree(sha)
|
187
|
+
command_lines('ls-tree', ['-r', sha])
|
188
|
+
end
|
189
|
+
|
190
|
+
def tree_depth(sha)
|
191
|
+
full_tree(sha).size
|
192
|
+
end
|
193
|
+
|
194
|
+
def change_head_branch(branch_name)
|
195
|
+
command('symbolic-ref', ['HEAD', "refs/heads/#{branch_name}"])
|
196
|
+
end
|
197
|
+
|
198
|
+
def branches_all
|
199
|
+
arr = []
|
200
|
+
command_lines('branch', '-a').each do |b|
|
201
|
+
current = (b[0, 2] == '* ')
|
202
|
+
arr << [b.gsub('* ', '').strip, current]
|
203
|
+
end
|
204
|
+
arr
|
205
|
+
end
|
206
|
+
|
207
|
+
def list_files(ref_dir)
|
208
|
+
dir = File.join(@git_dir, 'refs', ref_dir)
|
209
|
+
files = []
|
210
|
+
Dir.chdir(dir) { files = Dir.glob('**/*').select { |f| File.file?(f) } } rescue nil
|
211
|
+
files
|
212
|
+
end
|
213
|
+
|
214
|
+
def branch_current
|
215
|
+
branches_all.select { |b| b[1] }.first[0] rescue nil
|
216
|
+
end
|
217
|
+
|
218
|
+
|
219
|
+
# returns hash
|
220
|
+
# [tree-ish] = [[line_no, match], [line_no, match2]]
|
221
|
+
# [tree-ish] = [[line_no, match], [line_no, match2]]
|
222
|
+
def grep(string, opts = {})
|
223
|
+
opts[:object] ||= 'HEAD'
|
224
|
+
|
225
|
+
grep_opts = ['-n']
|
226
|
+
grep_opts << '-i' if opts[:ignore_case]
|
227
|
+
grep_opts << '-v' if opts[:invert_match]
|
228
|
+
grep_opts << '-e'
|
229
|
+
grep_opts << string
|
230
|
+
grep_opts << opts[:object] if opts[:object].is_a?(String)
|
231
|
+
grep_opts << '--' << opts[:path_limiter] if opts[:path_limiter].is_a? String
|
232
|
+
|
233
|
+
hsh = {}
|
234
|
+
command_lines('grep', grep_opts).each do |line|
|
235
|
+
if m = /(.*)\:(\d+)\:(.*)/.match(line)
|
236
|
+
hsh[m[1]] ||= []
|
237
|
+
hsh[m[1]] << [m[2].to_i, m[3]]
|
238
|
+
end
|
239
|
+
end
|
240
|
+
hsh
|
241
|
+
end
|
242
|
+
|
243
|
+
def diff_full(obj1 = 'HEAD', obj2 = nil, opts = {})
|
244
|
+
diff_opts = ['-p']
|
245
|
+
diff_opts << '--cached' if opts[:cached]
|
246
|
+
diff_opts << obj1 if obj1.is_a?(String)
|
247
|
+
diff_opts << obj2 if obj2.is_a?(String)
|
248
|
+
diff_opts << '--' << opts[:path_limiter] if opts[:path_limiter].is_a? String
|
249
|
+
|
250
|
+
command('diff', diff_opts)
|
251
|
+
end
|
252
|
+
|
253
|
+
def diff_stats(obj1 = 'HEAD', obj2 = nil, opts = {})
|
254
|
+
diff_opts = ['--numstat']
|
255
|
+
diff_opts << obj1
|
256
|
+
diff_opts << obj2 if obj2.is_a?(String)
|
257
|
+
diff_opts << '--' << opts[:path_limiter] if opts[:path_limiter].is_a? String
|
258
|
+
|
259
|
+
hsh = {:total => {:insertions => 0, :deletions => 0, :lines => 0, :files => 0}, :files => {}}
|
260
|
+
|
261
|
+
command_lines('diff', diff_opts).each do |file|
|
262
|
+
(insertions, deletions, filename) = file.split("\t")
|
263
|
+
hsh[:total][:insertions] += insertions.to_i
|
264
|
+
hsh[:total][:deletions] += deletions.to_i
|
265
|
+
hsh[:total][:lines] = (hsh[:total][:deletions] + hsh[:total][:insertions])
|
266
|
+
hsh[:total][:files] += 1
|
267
|
+
hsh[:files][filename] = {:insertions => insertions.to_i, :deletions => deletions.to_i}
|
268
|
+
end
|
269
|
+
|
270
|
+
hsh
|
271
|
+
end
|
272
|
+
|
273
|
+
# compares the index and the working directory
|
274
|
+
def diff_files
|
275
|
+
hsh = {}
|
276
|
+
command_lines('diff-files').each do |line|
|
277
|
+
(info, file) = line.split("\t")
|
278
|
+
(mode_src, mode_dest, sha_src, sha_dest, type) = info.split
|
279
|
+
hsh[file] = {:path => file, :mode_file => mode_src.to_s[1, 7], :mode_index => mode_dest,
|
280
|
+
:sha_file => sha_src, :sha_index => sha_dest, :type => type}
|
281
|
+
end
|
282
|
+
hsh
|
283
|
+
end
|
284
|
+
|
285
|
+
# compares the index and the repository
|
286
|
+
def diff_index(treeish)
|
287
|
+
hsh = {}
|
288
|
+
command_lines('diff-index', treeish).each do |line|
|
289
|
+
(info, file) = line.split("\t")
|
290
|
+
(mode_src, mode_dest, sha_src, sha_dest, type) = info.split
|
291
|
+
hsh[file] = {:path => file, :mode_repo => mode_src.to_s[1, 7], :mode_index => mode_dest,
|
292
|
+
:sha_repo => sha_src, :sha_index => sha_dest, :type => type}
|
293
|
+
end
|
294
|
+
hsh
|
295
|
+
end
|
296
|
+
|
297
|
+
def ls_files(location=nil)
|
298
|
+
hsh = {}
|
299
|
+
command_lines('ls-files', ['--stage', location]).each do |line|
|
300
|
+
(info, file) = line.split("\t")
|
301
|
+
(mode, sha, stage) = info.split
|
302
|
+
file = eval(file) if file =~ /^\".*\"$/ # This takes care of quoted strings returned from git
|
303
|
+
hsh[file] = {:path => file, :mode_index => mode, :sha_index => sha, :stage => stage}
|
304
|
+
end
|
305
|
+
hsh
|
306
|
+
end
|
307
|
+
|
308
|
+
|
309
|
+
def ignored_files
|
310
|
+
command_lines('ls-files', ['--others', '-i', '--exclude-standard'])
|
311
|
+
end
|
312
|
+
|
313
|
+
|
314
|
+
def config_remote(name)
|
315
|
+
hsh = {}
|
316
|
+
config_list.each do |key, value|
|
317
|
+
if /remote.#{name}/.match(key)
|
318
|
+
hsh[key.gsub("remote.#{name}.", '')] = value
|
319
|
+
end
|
320
|
+
end
|
321
|
+
hsh
|
322
|
+
end
|
323
|
+
|
324
|
+
def config_get(name)
|
325
|
+
do_get = lambda do
|
326
|
+
command('config', ['--get', name])
|
327
|
+
end
|
328
|
+
|
329
|
+
if @git_dir
|
330
|
+
Dir.chdir(@git_dir, &do_get)
|
331
|
+
else
|
332
|
+
build_list.call
|
333
|
+
end
|
334
|
+
end
|
335
|
+
|
336
|
+
def global_config_get(name)
|
337
|
+
command('config', ['--global', '--get', name], false)
|
338
|
+
end
|
339
|
+
|
340
|
+
def config_list
|
341
|
+
build_list = lambda do |path|
|
342
|
+
parse_config_list command_lines('config', ['--list'])
|
343
|
+
end
|
344
|
+
|
345
|
+
if @git_dir
|
346
|
+
Dir.chdir(@git_dir, &build_list)
|
347
|
+
else
|
348
|
+
build_list.call
|
349
|
+
end
|
350
|
+
end
|
351
|
+
|
352
|
+
def global_config_list
|
353
|
+
parse_config_list command_lines('config', ['--global', '--list'], false)
|
354
|
+
end
|
355
|
+
|
356
|
+
def parse_config_list(lines)
|
357
|
+
hsh = {}
|
358
|
+
lines.each do |line|
|
359
|
+
(key, *values) = line.split('=')
|
360
|
+
hsh[key] = values.join('=')
|
361
|
+
end
|
362
|
+
hsh
|
363
|
+
end
|
364
|
+
|
365
|
+
def parse_config(file)
|
366
|
+
hsh = {}
|
367
|
+
parse_config_list command_lines('config', ['--list', '--file', file], false)
|
368
|
+
#hsh = {}
|
369
|
+
#file = File.expand_path(file)
|
370
|
+
#if File.file?(file)
|
371
|
+
# current_section = nil
|
372
|
+
# File.readlines(file).each do |line|
|
373
|
+
# if m = /\[(\w+)\]/.match(line)
|
374
|
+
# current_section = m[1]
|
375
|
+
# elsif m = /\[(\w+?) "(.*?)"\]/.match(line)
|
376
|
+
# current_section = "#{m[1]}.#{m[2]}"
|
377
|
+
# elsif m = /(\w+?) = (.*)/.match(line)
|
378
|
+
# key = "#{current_section}.#{m[1]}"
|
379
|
+
# hsh[key] = m[2]
|
380
|
+
# end
|
381
|
+
# end
|
382
|
+
#end
|
383
|
+
#hsh
|
384
|
+
end
|
385
|
+
|
386
|
+
## WRITE COMMANDS ##
|
387
|
+
|
388
|
+
def config_set(name, value)
|
389
|
+
command('config', [name, value])
|
390
|
+
end
|
391
|
+
|
392
|
+
def global_config_set(name, value)
|
393
|
+
command('config', ['--global', name, value], false)
|
394
|
+
end
|
395
|
+
|
396
|
+
def status
|
397
|
+
command_lines('status', ['--porcelain'])
|
398
|
+
end
|
399
|
+
|
400
|
+
def full_status
|
401
|
+
command('status')
|
402
|
+
end
|
403
|
+
|
404
|
+
def add(path = '.')
|
405
|
+
arr_opts = ['--']
|
406
|
+
if path.is_a?(Array)
|
407
|
+
arr_opts += path
|
408
|
+
else
|
409
|
+
arr_opts << path
|
410
|
+
end
|
411
|
+
command('add', arr_opts)
|
412
|
+
end
|
413
|
+
|
414
|
+
def remove(path = '.', opts = {})
|
415
|
+
arr_opts = ['-f'] # overrides the up-to-date check by default
|
416
|
+
arr_opts << ['-r'] if opts[:recursive]
|
417
|
+
arr_opts << '--'
|
418
|
+
if path.is_a?(Array)
|
419
|
+
arr_opts += path
|
420
|
+
else
|
421
|
+
arr_opts << path
|
422
|
+
end
|
423
|
+
|
424
|
+
command('rm', arr_opts)
|
425
|
+
end
|
426
|
+
|
427
|
+
def commit(message, opts = {})
|
428
|
+
arr_opts = ['-m', message]
|
429
|
+
arr_opts << '-a' if opts[:add_all]
|
430
|
+
arr_opts << '--allow-empty' if opts[:allow_empty]
|
431
|
+
arr_opts << "--author" << opts[:author] if opts[:author]
|
432
|
+
command('commit', arr_opts)
|
433
|
+
end
|
434
|
+
|
435
|
+
def reset(commit, opts = {})
|
436
|
+
arr_opts = []
|
437
|
+
arr_opts << '--hard' if opts[:hard]
|
438
|
+
arr_opts << commit if commit
|
439
|
+
arr_opts << '-q' << '--' << opts[:file] if opts[:file]
|
440
|
+
command('reset', arr_opts)
|
441
|
+
end
|
442
|
+
|
443
|
+
def apply(patch_file)
|
444
|
+
arr_opts = []
|
445
|
+
arr_opts << '--' << patch_file if patch_file
|
446
|
+
command('apply', arr_opts)
|
447
|
+
end
|
448
|
+
|
449
|
+
def apply_mail(patch_file)
|
450
|
+
arr_opts = []
|
451
|
+
arr_opts << '--' << patch_file if patch_file
|
452
|
+
command('am', arr_opts)
|
453
|
+
end
|
454
|
+
|
455
|
+
def stashes_all
|
456
|
+
arr = []
|
457
|
+
filename = File.join(@git_dir, 'logs/refs/stash')
|
458
|
+
if File.exist?(filename)
|
459
|
+
File.open(filename).each_with_index { |line, i|
|
460
|
+
m = line.match(/:(.*)$/)
|
461
|
+
arr << [i, m[1].strip]
|
462
|
+
}
|
463
|
+
end
|
464
|
+
arr
|
465
|
+
end
|
466
|
+
|
467
|
+
def stash_save(message)
|
468
|
+
output = command('stash save', ['--', message])
|
469
|
+
output =~ /HEAD is now at/
|
470
|
+
end
|
471
|
+
|
472
|
+
def stash_apply(id = nil)
|
473
|
+
if id
|
474
|
+
command('stash apply', [id])
|
475
|
+
else
|
476
|
+
command('stash apply')
|
477
|
+
end
|
478
|
+
end
|
479
|
+
|
480
|
+
def stash_clear
|
481
|
+
command('stash clear')
|
482
|
+
end
|
483
|
+
|
484
|
+
def stash_list
|
485
|
+
command('stash list')
|
486
|
+
end
|
487
|
+
|
488
|
+
def branch_new(branch)
|
489
|
+
command('branch', branch)
|
490
|
+
end
|
491
|
+
|
492
|
+
def branch_delete(branch)
|
493
|
+
command('branch', ['-D', branch])
|
494
|
+
end
|
495
|
+
|
496
|
+
def checkout(branch, opts = {})
|
497
|
+
arr_opts = []
|
498
|
+
arr_opts << '-f' if opts[:force]
|
499
|
+
arr_opts << '-b' << opts[:new_branch] if opts[:new_branch]
|
500
|
+
arr_opts << branch
|
501
|
+
|
502
|
+
command('checkout', arr_opts)
|
503
|
+
end
|
504
|
+
|
505
|
+
def checkout_file(version, file)
|
506
|
+
arr_opts = []
|
507
|
+
arr_opts << version
|
508
|
+
arr_opts << file
|
509
|
+
command('checkout', arr_opts)
|
510
|
+
end
|
511
|
+
|
512
|
+
def merge(branch, message = nil)
|
513
|
+
arr_opts = []
|
514
|
+
arr_opts << '-m' << message if message
|
515
|
+
arr_opts += [branch]
|
516
|
+
command('merge', arr_opts)
|
517
|
+
end
|
518
|
+
|
519
|
+
def unmerged
|
520
|
+
unmerged = []
|
521
|
+
command_lines('diff', ["--cached"]).each do |line|
|
522
|
+
unmerged << $1 if line =~ /^\* Unmerged path (.*)/
|
523
|
+
end
|
524
|
+
unmerged
|
525
|
+
end
|
526
|
+
|
527
|
+
def conflicts # :yields: file, your, their
|
528
|
+
self.unmerged.each do |f|
|
529
|
+
your = Tempfile.new("YOUR-#{File.basename(f)}").path
|
530
|
+
command('show', ":2:#{f}", true, "> #{escape your}")
|
531
|
+
|
532
|
+
their = Tempfile.new("THEIR-#{File.basename(f)}").path
|
533
|
+
command('show', ":3:#{f}", true, "> #{escape their}")
|
534
|
+
yield(f, your, their)
|
535
|
+
end
|
536
|
+
end
|
537
|
+
|
538
|
+
def remote_add(name, url, opts = {})
|
539
|
+
arr_opts = ['add']
|
540
|
+
arr_opts << '-f' if opts[:with_fetch]
|
541
|
+
arr_opts << '--'
|
542
|
+
arr_opts << name
|
543
|
+
arr_opts << url
|
544
|
+
|
545
|
+
command('remote', arr_opts)
|
546
|
+
end
|
547
|
+
|
548
|
+
# this is documented as such, but seems broken for some reason
|
549
|
+
# i'll try to get around it some other way later
|
550
|
+
def remote_remove(name)
|
551
|
+
command('remote', ['rm', '--', name])
|
552
|
+
end
|
553
|
+
|
554
|
+
def remotes
|
555
|
+
command_lines('remote')
|
556
|
+
end
|
557
|
+
|
558
|
+
def tags
|
559
|
+
command_lines('tag')
|
560
|
+
end
|
561
|
+
|
562
|
+
def tag(tag)
|
563
|
+
command('tag', tag)
|
564
|
+
end
|
565
|
+
|
566
|
+
|
567
|
+
def fetch(remote)
|
568
|
+
command('fetch', remote)
|
569
|
+
end
|
570
|
+
|
571
|
+
def push(remote, branch = 'master', tags = false)
|
572
|
+
command('push', [remote, branch])
|
573
|
+
command('push', ['--tags', remote]) if tags
|
574
|
+
end
|
575
|
+
|
576
|
+
def tag_sha(tag_name)
|
577
|
+
head = File.join(@git_dir, 'refs', 'tags', tag_name)
|
578
|
+
return File.read(head).chomp if File.exists?(head)
|
579
|
+
|
580
|
+
command('show-ref', ['--tags', '-s', tag_name])
|
581
|
+
end
|
582
|
+
|
583
|
+
def repack
|
584
|
+
command('repack', ['-a', '-d'])
|
585
|
+
end
|
586
|
+
|
587
|
+
def gc
|
588
|
+
command('gc', ['--prune', '--aggressive', '--auto'])
|
589
|
+
end
|
590
|
+
|
591
|
+
# reads a tree into the current index file
|
592
|
+
def read_tree(treeish, opts = {})
|
593
|
+
arr_opts = []
|
594
|
+
arr_opts << "--prefix=#{opts[:prefix]}" if opts[:prefix]
|
595
|
+
arr_opts += [treeish]
|
596
|
+
command('read-tree', arr_opts)
|
597
|
+
end
|
598
|
+
|
599
|
+
def write_tree
|
600
|
+
command('write-tree')
|
601
|
+
end
|
602
|
+
|
603
|
+
def commit_tree(tree, opts = {})
|
604
|
+
opts[:message] ||= "commit tree #{tree}"
|
605
|
+
t = Tempfile.new('commit-message')
|
606
|
+
t.write(opts[:message])
|
607
|
+
t.close
|
608
|
+
|
609
|
+
arr_opts = []
|
610
|
+
arr_opts << tree
|
611
|
+
arr_opts << '-p' << opts[:parent] if opts[:parent]
|
612
|
+
arr_opts += [opts[:parents]].map { |p| ['-p', p] }.flatten if opts[:parents]
|
613
|
+
command('commit-tree', arr_opts, true, "< #{escape t.path}")
|
614
|
+
end
|
615
|
+
|
616
|
+
def update_ref(branch, commit)
|
617
|
+
command('update-ref', [branch, commit])
|
618
|
+
end
|
619
|
+
|
620
|
+
def checkout_index(opts = {})
|
621
|
+
arr_opts = []
|
622
|
+
arr_opts << "--prefix=#{opts[:prefix]}" if opts[:prefix]
|
623
|
+
arr_opts << "--force" if opts[:force]
|
624
|
+
arr_opts << "--all" if opts[:all]
|
625
|
+
arr_opts << '--' << opts[:path_limiter] if opts[:path_limiter].is_a? String
|
626
|
+
|
627
|
+
command('checkout-index', arr_opts)
|
628
|
+
end
|
629
|
+
|
630
|
+
# creates an archive file
|
631
|
+
#
|
632
|
+
# options
|
633
|
+
# :format (zip, tar)
|
634
|
+
# :prefix
|
635
|
+
# :remote
|
636
|
+
# :path
|
637
|
+
def archive(sha, file = nil, opts = {})
|
638
|
+
opts[:format] ||= 'zip'
|
639
|
+
|
640
|
+
if opts[:format] == 'tgz'
|
641
|
+
opts[:format] = 'tar'
|
642
|
+
opts[:add_gzip] = true
|
643
|
+
end
|
644
|
+
|
645
|
+
file ||= Tempfile.new('archive').path
|
646
|
+
|
647
|
+
arr_opts = []
|
648
|
+
arr_opts << "--format=#{opts[:format]}" if opts[:format]
|
649
|
+
arr_opts << "--prefix=#{opts[:prefix]}" if opts[:prefix]
|
650
|
+
arr_opts << "--remote=#{opts[:remote]}" if opts[:remote]
|
651
|
+
arr_opts << sha
|
652
|
+
arr_opts << '--' << opts[:path] if opts[:path]
|
653
|
+
command('archive', arr_opts, true, (opts[:add_gzip] ? '| gzip' : '') + " > #{escape file}")
|
654
|
+
return file
|
655
|
+
end
|
656
|
+
|
657
|
+
# returns the current version of git, as an Array of Fixnums.
|
658
|
+
def current_command_version
|
659
|
+
output = command('version', [], false)
|
660
|
+
version = output[/\d+\.\d+(\.\d+)+/]
|
661
|
+
version.split('.').collect {|i| i.to_i}
|
662
|
+
end
|
663
|
+
|
664
|
+
def required_command_version
|
665
|
+
[1, 6, 0, 0]
|
666
|
+
end
|
667
|
+
|
668
|
+
def meets_required_version?
|
669
|
+
current_version = self.current_command_version
|
670
|
+
required_version = self.required_command_version
|
671
|
+
|
672
|
+
return current_version[0] >= required_version[0] &&
|
673
|
+
current_version[1] >= required_version[1] &&
|
674
|
+
(current_version[2] ? current_version[2] >= required_version[2] : true) &&
|
675
|
+
(current_version[3] ? current_version[3] >= required_version[3] : true)
|
676
|
+
end
|
677
|
+
|
678
|
+
|
679
|
+
private
|
680
|
+
|
681
|
+
def command_lines(cmd, opts = [], chdir = true, redirect = '')
|
682
|
+
command(cmd, opts, chdir).split("\n")
|
683
|
+
end
|
684
|
+
|
685
|
+
def command(cmd, opts = [], chdir = true, redirect = '', &block)
|
686
|
+
ENV['GIT_DIR'] = @git_dir
|
687
|
+
ENV['GIT_INDEX_FILE'] = @git_index_file
|
688
|
+
ENV['GIT_WORK_TREE'] = @git_work_dir
|
689
|
+
path = @git_work_dir || @git_dir || @path
|
690
|
+
|
691
|
+
opts = [opts].flatten.map {|s| escape(s) }.join(' ')
|
692
|
+
git_cmd = "git #{cmd} #{opts} #{redirect} 2>&1"
|
693
|
+
#p git_cmd
|
694
|
+
|
695
|
+
out = nil
|
696
|
+
if chdir && (Dir.getwd != path)
|
697
|
+
Dir.chdir(path) { out = run_command(git_cmd, &block) }
|
698
|
+
else
|
699
|
+
out = run_command(git_cmd, &block)
|
700
|
+
end
|
701
|
+
|
702
|
+
if @logger
|
703
|
+
@logger.info(git_cmd)
|
704
|
+
@logger.debug(out)
|
705
|
+
end
|
706
|
+
|
707
|
+
if $?.exitstatus > 0
|
708
|
+
if $?.exitstatus == 1 && out == ''
|
709
|
+
return ''
|
710
|
+
end
|
711
|
+
raise Git::GitExecuteError.new(git_cmd + ':' + out.to_s)
|
712
|
+
end
|
713
|
+
out
|
714
|
+
end
|
715
|
+
|
716
|
+
def run_command(git_cmd, &block)
|
717
|
+
if block_given?
|
718
|
+
IO.popen(git_cmd, &block)
|
719
|
+
else
|
720
|
+
`#{git_cmd}`.chomp
|
721
|
+
end
|
722
|
+
end
|
723
|
+
|
724
|
+
def escape(s)
|
725
|
+
escaped = s.to_s.gsub(%q{'}, %q{'"'"'})
|
726
|
+
%Q{'#{escaped}'}
|
727
|
+
end
|
728
|
+
|
729
|
+
end
|
730
|
+
end
|