Commit Graph

701 Commits

Author SHA1 Message Date
Roland Walker 787b471618 isolate ErrorDuringExecution rescue
it only should be rescued for the `curl` invocation
2014-06-03 11:39:58 -04:00
Roland Walker 9797d2770f doc: improve Cask-source-resolution debug message 2014-06-03 10:39:18 -04:00
Roland Walker f24b4ba05a show resolved Cask source file or URI w/ --debug
references #4641
2014-06-03 10:38:49 -04:00
Roland Walker f8c9567a66 Don't prefer Cask files in the cwd
Fixes #4641.  Cask files in the cwd are still permitted, but
at the very lowest priority, below Tapped Cask names.
2014-06-03 10:33:19 -04:00
Roland Walker 290d1ccb38 ChecksumMismatchError is ordinary exception
not a bug
2014-06-02 23:26:19 -04:00
Roland Walker 1b9df93e20 no need to catch CaskAlreadyInstalledError
separately; it is already descended from CaskError
2014-06-02 23:24:59 -04:00
Roland Walker d4fb446830 Merge pull request #4603 from rolandwalker/doctor_homebrew_origin
show Homebrew repo & origin in doctor
2014-05-31 15:19:37 -04:00
Roland Walker 9fdc5b3fd9 show Homebrew repo & origin in doctor
references: #4581, #4571
2014-05-31 07:58:22 -04:00
Roland Walker f71ed25ee0 rescue download failure; don't show traceback
instead, give a more specific error message.  Closes #4556.
2014-05-26 15:56:35 -04:00
Roland Walker 5b2e9d1466 doc/comment: known performance issues 2014-05-15 16:52:41 -04:00
Roland Walker 3c40e82c18 generate installed list only once during list cmd 2014-05-15 16:52:17 -04:00
Roland Walker c3e514defe optimize Cask.installed by guessing full paths 2014-05-15 16:50:42 -04:00
Roland Walker 598f53ba48 memoize all_tapped_cask_dirs 2014-05-15 16:49:43 -04:00
Roland Walker 03af4f45a1 make cask_titles hold Pathnames, not strings 2014-05-15 16:38:35 -04:00
Roland Walker d0db956d69 refactor `brew cask doctor`
Output remains the same (except in the case of error).
Wrap all calculations in begin blocks for safety, provide fallback
values for all variables, don't use ohai+puts when ohai is
sufficient
2014-05-15 12:55:23 -04:00
Roland Walker abd66acba1 Merge pull request #4370 from rolandwalker/uninstall_signal
add `:signal` directive for `uninstall`
2014-05-14 06:26:49 -04:00
Roland Walker d4c89509c2 Merge pull request #4382 from rolandwalker/no_doubledash_launchctl_remove
don't use doubledash on launchctl remove
2014-05-14 06:26:27 -04:00
Roland Walker 6815ef272e don't use doubledash on launchctl remove
it appears to be incorrect here: removal of jobs is hindered
2014-05-13 18:52:35 -04:00
Roland Walker b38d6a6977 add `:signal` directive for `uninstall`
to send arbitrary Unix signals.  Per discussion in #4328, some
processes are resistant to the `:quit` directive, and can be
made to shut down via a signal.
2014-05-13 13:04:10 -04:00
Roland Walker 5101d363ab append the .rb extension on Cask::Source::Path
Unless `.rb` is already present on the query string.  Failure
to append the extension caused confusing effects, including
selective failure of "brew cask list" when invoked from
`/usr/local/bin` working directory.  Fixes #4077 .
Credit to @mroth on the detective work.
2014-05-13 09:04:14 -04:00
Roland Walker cfc6ae7a13 Merge pull request #4264 from rolandwalker/retire_sha1
Retire support for `sha1` stanza.
2014-05-08 18:37:00 -04:00
Roland Walker 0808c0f3f9 handle Tap read error in `brew cask doctor` 2014-05-08 14:53:30 -04:00
Roland Walker 34df5309d4 Retire support for `sha1` stanza.
We haven't received new submissions using `sha1` for quite
some time.
2014-05-08 12:01:32 -04:00
Roland Walker c436ddc5fd transition docs/tests/messages to sha256 :no_check
`sha256 :no_check` has been supported syntax for a couple of months,
and now is being transitioned to the preferred syntax, replacing
the `no_checksum` stanza (which will still be supported, but
deprecated)
2014-05-08 08:42:44 -04:00
Roland Walker 89082904c4 cut v0.35.0 2014-05-08 07:48:34 -04:00
Roland Walker dd5d767b18 Merge pull request #4244 from rolandwalker/toplevel_dir_permissions
special case permissions when creating `/opt`
2014-05-07 22:36:42 -04:00
Roland Walker 4f82dda065 Merge pull request #4242 from rolandwalker/cat_documentation
update docs and messages for `brew cask cat`
2014-05-07 22:34:07 -04:00
Atsushi Nagase 186e2592df Moved garmin-express.rb to correct location 2014-05-08 00:47:23 +09:00
Roland Walker 1fe644f84f special case permissions when creating `/opt`
or any other toplevel directory. Closes #4187
2014-05-07 10:56:04 -04:00
Roland Walker e910467b39 update docs and messages for `brew cask cat` 2014-05-07 10:32:15 -04:00
Roland Walker e9f6c196f8 Merge pull request #4229 from rolandwalker/defend_unusual_homebrew
Defend against unusual Homebrew setups
2014-05-07 10:12:58 -04:00
Roland Walker 0153c19f7a Defend against unusual Homebrew setups
To aid in Tap transition.  Require Homebrew 0.9.5, rescue
`rename_tags_dir_if_necessary` (`respond_to?` won't work there
because `rename_tags_dir_if_necessary` is a private method.

References: #4192, @Jackiebo in #4096
2014-05-07 09:50:42 -04:00
Roland Walker 89bf98ce6d Merge pull request #4241 from rolandwalker/cat_tweaks
light changes to "brew cask cat"
2014-05-07 09:33:52 -04:00
Roland Walker 31ce4bd4cd light changes to "brew cask cat"
tone down strident comment imported from Homebrew, whitespace, misc
2014-05-07 09:18:03 -04:00
Roland Walker fe99823d84 Merge pull request #4226 from rolandwalker/handle_nil_in_checklinks
handle `nil` `@response_status`
2014-05-07 08:38:24 -04:00
Roland Walker e1ee7b118d Merge pull request #4200 from linc01n/cli_cat
Add `brew cask cat` command
2014-05-07 08:29:30 -04:00
Roland Walker f80afb8684 handle nil @response_status
fixes #4212
2014-05-06 09:13:49 -04:00
Atsushi Nagase 4e1d4cbd0e Added Garmin Express 2014-05-06 06:28:37 +09:00
Lincoln Lee 227ac512bc Add `brew cask cat` command mentioned in #4018 2014-05-05 22:46:28 +08:00
Paul Hinze 767be2b4b0 cut v0.34.0 2014-05-04 18:53:58 -05:00
Paul Hinze 9e2641b851 Merge pull request #2427 from rolandwalker/checksum_error_help
Give the user help on checksum errors
2014-05-04 18:27:20 -05:00
Roland Walker fb1300366e automatically transition to new Tap name/location
At every command execution
- invoke `rename_taps_dir_if_necessary` to help with Homebrew's Tap migration.
  (Homebrew's migration seems to sometimes fail to fire, see #4096)
- untap `phinze/cask`, and tap `caskroom/cask`, to help with our own move
  to a GitHub organization
After a few months, this can be reverted.
2014-05-03 16:24:00 -04:00
Paul Hinze f54eaf7082 update all references to new caskroom org home
global replace of:
  'phinze/homebrew-cask' -> 'caskroom/homebrew-cask'
  'phinze/cask' -> 'caskroom/cask'
  'phinze/homebrew-testcasks' -> 'caskroom/homebrew-testcasks'

and various other specific places that needed updates

<3 the homebrew-cask community!
2014-05-03 10:29:17 -05:00
Roland Walker 90bba2cf00 cut v0.33.1 2014-04-29 09:49:12 -04:00
Roland Walker d73b8089c6 Merge pull request #4095 from rolandwalker/doctor_tap_paths
add Tap path info to `brew cask doctor`
2014-04-29 09:39:36 -04:00
Roland Walker c7ec83c068 add Tap path info to `brew cask doctor` 2014-04-29 09:30:06 -04:00
Roland Walker 75d6859195 better handle renamed Casks in `brew cask info`
Fixes #4058
2014-04-29 08:57:44 -04:00
Lincoln Lee 5faa850690 Remove ISSUES_URL from cli commands
When user run `brew cask` it will list all commands out.
There is a blank help command call issues_url which caused by the newly
introduced constant from #2971
2014-04-27 17:49:01 +08:00
Roland Walker 1f69c04cd6 cut v0.33.0 2014-04-26 09:59:40 -04:00
Roland Walker f7a209d133 Merge pull request #4042 from rolandwalker/tap_location_change
Adapt to homebrew's move of the tap directory
2014-04-26 09:47:03 -04:00
Roland Walker 400433be20 Adapt to homebrew's move of the tap directory
Closes #4035. Closes #4029. Closes #4026.
2014-04-26 09:42:16 -04:00
Roland Walker 836b3ce699 avoid exit code with no Casks are installed
and no argument is give to `brew cask list`.  Fixes #3881.
2014-04-25 10:56:45 -04:00
Võ Anh Duy 0fb893027d Redirect user to cask issues page, fixes #1251 2014-04-19 20:21:48 +07:00
Roland Walker af3fe61ae5 cut v0.32.0 2014-03-29 09:04:25 -04:00
Roland Walker 5bc2b62b25 Merge pull request #3667 from rolandwalker/artifacts_in_info
display artifact summary in `brew cask info`
2014-03-28 09:33:23 -04:00
Roland Walker 0652a39eb8 Merge pull request #3700 from rolandwalker/assistive_devices_caveat
add `assistive_devices` to `caveats` DSL
2014-03-28 09:33:00 -04:00
Roland Walker af103f1486 add `zsh_path_helper` to `caveats` DSL
Per discussion in #3597 and Homebrew/homebrew#25719
2014-03-27 09:42:33 -04:00
Roland Walker 9554b58245 add `assistive_devices` to `caveats` DSL
Inspired by #3695
2014-03-27 09:41:20 -04:00
Roland Walker 5c8640d6fe Merge pull request #2706 from rolandwalker/install_suggest
suggest replacements on "brew cask install" fail
2014-03-27 08:51:13 -04:00
Roland Walker 421eafaec8 display artifact summary in `brew cask info`
Per discussion with @drew-gross in closed issue #3280.
Limitation: does not show link targets.
2014-03-26 08:55:58 -04:00
Roland Walker f1620a56f5 make `brew cask audit` return error code on fail
Per report in #3655
2014-03-25 09:09:49 -04:00
Roland Walker 0938a9d862 cut v0.31.1 2014-03-17 10:11:50 -04:00
Roland Walker 266718d047 don't downcase a Pathname object
Fixes #3572.
2014-03-17 09:56:22 -04:00
Roland Walker 008b96353d cut v0.31.0 2014-03-15 10:30:37 -04:00
Roland Walker be255dcdbc Merge pull request #3515 from rolandwalker/unload_service
explicitly unload :launchctl service before remove
2014-03-14 21:12:14 -04:00
Roland Walker e8bd3465fe respect digits in search strings
Fixes #3533
2014-03-14 08:48:43 -04:00
Roland Walker ba8473a766 explicitly unload :launchctl service before remove 2014-03-14 08:41:18 -04:00
Roland Walker f5318395eb Merge pull request #3518 from rolandwalker/casecmp_fixes
fix some erroneous uses of `casecmp`
2014-03-12 19:15:37 -04:00
Roland Walker ba8d9ba4b5 fix some erroneous uses of `casecmp`
`casecmp` returns -1/0/1, never false or nil
2014-03-12 10:40:11 -04:00
Roland Walker 21e18b8a37 only set filesystem metadata if :target != source
fixing a bug in the implementation of #3073 which caused
metadata to be set in all cases.
2014-03-12 10:26:38 -04:00
Roland Walker a8acf3de1a bugfix: preserve resource forks when unzipping
Use the unarchiving ability built into the `ditto` utility,
rather explicitly calling the `unzip` utility.  Fixes
caskroom/homebrew-fonts#90.
2014-03-11 08:46:38 -04:00
Pedro Silva e58f3f89ca add new CurlPostDownloadStrategy
- lib/cask/url.rb: initialize(): add new `:data` attribute to hold post parameters
- lib/cask/download.rb: perform(): dispatch to new class based on `:using => :post`
- lib/cask/download_strategy.rb: Cask::CurlPostDownloadStrategy:
  			extend curl_args with x-www-form-urlencoded data
- doc/CASK_LANGUAGE_REFERENCE.md: HTTP URLs: document new strategy
- test/cask/test_download_strategy.rb: Cask::CurlPostDownloadStrategy: test new strategy
2014-03-07 20:51:35 +01:00
Roland Walker 726a650ebd Merge pull request #3106 from rolandwalker/emojii
Emoji and disk usage stats at install success
2014-03-06 21:40:37 -05:00
Roland Walker bf6ce149cf Merge pull request #3217 from rolandwalker/multiple_args_to_pkgutil
accept multiple arguments to uninstall/:pkgutil
2014-03-04 10:30:00 -05:00
Roland Walker 96dfc573b1 Merge pull request #2672 from rolandwalker/lsb_no_delete_safety
BUGFIX: don't try autocleanup inside system dirs
2014-03-03 09:30:09 -05:00
Roland Walker 655f50b064 cut v0.30.1 2014-03-02 10:30:23 -05:00
Roland Walker 15a4ca92e9 test if lsar is nil before attempting split
fixes #3332
2014-03-02 10:22:03 -05:00
Roland Walker c95a7f2534 suggest replacements on "brew cask install" fail 2014-03-01 15:04:12 -05:00
Roland Walker 8feb7e8495 cut v0.30.0 2014-03-01 12:30:17 -05:00
Paul Hinze c0f470cd55 Merge pull request #3011 from rolandwalker/force_container_type
ability to specify container type, not detect
2014-02-28 09:23:01 -06:00
Ko-Chih Wu 59e3b183e2 Fix broken `brew cask alfred link`
- Remove quotes from `defaults write` args. With quotes the value is
  written as a string instead of a dictionary, which breaks the search
  scope in alfred.
- Make the default scope consistent with alfred default
2014-02-28 01:00:00 -08:00
Roland Walker a25469434d accept multiple arguments to uninstall/:pkgutil
We may as well do so, the previous behavior was a bug:
multiple elements were silently concatenated into a single
regexp.
2014-02-26 07:21:18 -05:00
Roland Walker 020aaca082 Merge pull request #3013 from rolandwalker/accept_trailing_rb
accept and ignore trailing `.rb` on CL arguments
2014-02-25 18:31:37 -05:00
Roland Walker 36cd9e4d72 accept and ignore trailing `.rb` on CL arguments
"Be conservative in what you do, be liberal in what you accept."
2014-02-25 18:24:58 -05:00
muescha d7341a79b5 better error message (same like at cabextract) 2014-02-26 00:08:18 +01:00
Roland Walker bf49dc9fa8 ability to specify container type, not detect
Fixes #2997.  Interface is optional DSL stanza `container_type`.
This should only be used in rare instances.  It is needed for the
case of a naked executable which should not be unpacked.
2014-02-25 16:39:12 -05:00
Roland Walker c7e0e5b2e5 support Bzip2 containers
bzips of tarballs are already supported via `tar`.  This
adds support for a single file asset within a bzip2 container.
2014-02-25 16:36:36 -05:00
Roland Walker 9fa39c2681 add support for RAR containers
this will not pass Travis until #2744 is merged
2014-02-25 16:29:24 -05:00
Roland Walker 76eab0ad8a Merge pull request #3040 from rolandwalker/stuffit_containers
add support for Stuffit containers
2014-02-25 16:27:16 -05:00
Roland Walker fe90e266f5 Merge pull request #2705 from rolandwalker/search_exact
Divide search output into sections
2014-02-25 12:59:53 -05:00
Roland Walker b90633d92a add support for Stuffit containers
This will not pass Travis until #2744 is merged
2014-02-25 12:54:49 -05:00
Roland Walker 76602af5cf Merge pull request #2744 from rolandwalker/sevenzip_containers
Add 7z container support
2014-02-25 12:51:21 -05:00
Võ Anh Duy 33a97a1a5f CLI - Fetch
Add `fetch` command to cli like suggestion at the end of #2528
2014-02-26 00:44:22 +07:00
Roland Walker a75a4840cf Add 7z container support
relevant Casks must use `depends_on_formula unar`
2014-02-25 12:32:37 -05:00
Roland Walker 297cd6382a Merge pull request #3058 from rolandwalker/exception_objects
raise exception objects
2014-02-25 12:30:30 -05:00
Roland Walker cb627e463c Merge pull request #3073 from rolandwalker/add_target_metadata
add extended attributes for `:target` links
2014-02-25 12:30:15 -05:00
Roland Walker f3bbecb029 Merge pull request #3105 from rolandwalker/appcast_dsl
add optional appcast stanza to DSL
2014-02-25 12:30:08 -05:00
Roland Walker abe1f175ca Merge pull request #3107 from rolandwalker/dsl_no_check_syntax
`sha256 :no_check` as synonym for `no_checksum`
2014-02-25 12:29:48 -05:00
Roland Walker 22e24ea5c5 Merge pull request #3131 from rolandwalker/cmd_aliases
provide command aliases to match Homebrew
2014-02-25 12:29:22 -05:00
Roland Walker a7647426ce Merge pull request #2467 from vmrob/adobe-air-apps
Add support for Adobe Air app container
2014-02-25 12:23:08 -05:00
Roland Walker 45d72b8838 Merge pull request #3079 from rolandwalker/brew_cask_update
make `brew cask update` synonym for `brew update`
2014-02-24 19:08:02 -05:00
Roland Walker 4fcdab0583 provide command aliases to match Homebrew
fixes #2969
2014-02-24 08:15:52 -05:00
Roland Walker 6f6a07fc0f mass whitespace cleanup 2014-02-22 21:13:52 -05:00
Roland Walker 4e920d4f19 Give the user help on checksum errors 2014-02-22 20:03:12 -05:00
Roland Walker 3623d13e85 `sha256 :no_check` as synonym for `no_checksum` 2014-02-22 19:47:43 -05:00
Roland Walker fe2ff07f2e add optional appcast stanza to DSL
Appcasts are a standard way for applications to publish
information about available updates via RSS.  Sparkle and
other update frameworks are built upon appcasts.

In a quick test, appcasts were found for 188/360 Casks examined.

This PR adds an optional `appcast` stanza, but does not add
`appcast` to any Cask or make use of the info in any way.  It is
intentionally left undocumented.
2014-02-22 19:31:33 -05:00
Roland Walker d40195e8d4 Emoji and disk usage stats at install success
- consistent with Homebrew output
- respects Homebrew environment variables
- does not add any Homebrew code dependency
- really just for fun
2014-02-22 18:24:56 -05:00
Roland Walker 605003228f Merge pull request #2931 from rolandwalker/remove_md5
remove md5 checksum support
2014-02-22 15:31:26 -05:00
Roland Walker 55e9cfc39d make `brew cask update` synonym for `brew update`
for convenience/typo
2014-02-21 10:23:16 -05:00
Roland Walker 3ded5898b6 more reliable way to look up username
`ENV` is manipulable.  `getpwuid` is reliable.
2014-02-21 09:30:37 -05:00
Roland Walker 3ad2d6c31c create target directories on-demand
closes #2996.  Moves the logic for creating target directores
from init-time in cask.rb to install-time within the artifact
classes.  Removes the need for special-case mkpath for each
new artifact type.
2014-02-21 09:22:37 -05:00
Roland Walker 066d58d336 add extended attributes for :target links
fixes #2847.  This PR adds OS X-specific extended attributes
(metadata) whenever :target is used on an artifact.  The
extended attributes are available for search software such
as Spotlight or Alfred to discover the artifact under the
:target name.

Limitations: Spotlight specifically chooses to ignore this
attribute for App bundles.  Alfred will also ignore this
attribute until the upcoming 2.2 release.
2014-02-21 08:49:07 -05:00
Roland Walker 43624e6fcb Merge pull request #3057 from rolandwalker/caveat_method_spelling
bugfix: caveats DSL `os_version_only` spelling
2014-02-20 07:45:52 -05:00
Roland Walker 707b9091b0 Merge pull request #3042 from rolandwalker/curl_feedback_message
improve debug message from curl
2014-02-19 20:21:51 -05:00
Roland Walker 664bcb3c4e caveats DSL os_version_only spelling
change method name to follow documentation
2014-02-19 18:51:45 -05:00
Roland Walker 113518e8cb make checksum-missing message match Cask semantics
for copy/paste
2014-02-19 18:48:21 -05:00
Roland Walker 60378bcc7e CaskError objects instead of strings, better msgs 2014-02-19 18:47:39 -05:00
Roland Walker b81ea45d06 use new CaskInvalidError, improve messages 2014-02-19 18:46:55 -05:00
Roland Walker 330671dc03 Merge pull request #3025 from rolandwalker/no_font_search_hack
temporary hack: suppress searching the font tap
2014-02-19 17:23:58 -05:00
Roland Walker 7ed8cbf3bc cut v0.29.2 2014-02-19 11:51:31 -05:00
Roland Walker 2e2364e5e9 BUGFIX: Homebrew chg, 3 args for checksum mismatch
Homebrew changed underneath us, requiring 3 arguments to
`ChecksumMismatchError.new`.  This is causing total failure
on Travis, and probably a number of issues will be filed
until we merge and cut a bugfix release.
2014-02-19 11:03:07 -05:00
Roland Walker f05990eccb improve debug message from curl 2014-02-19 10:42:08 -05:00
Roland Walker d2b779e509 temporary hack: suppress searching the font tap
this is needed to reduce noise on searches until search
can be made more configurable
2014-02-19 09:21:30 -05:00
謝致邦 0a93634416 Add strip to link_checker. 2014-02-19 00:52:47 +08:00
Roland Walker 21e8f49a27 Merge pull request #2994 from rolandwalker/symlink_artifact_simplify
further cleanup/refactor of link-derived artifacts
2014-02-18 07:57:05 -05:00
Roland Walker cb4adbe3bd Merge pull request #2991 from rolandwalker/defensive_abv_method
fork `abv` method with better odd-filename defense
2014-02-17 21:05:59 -05:00
Victor Robertson 026ca0c6e1 Add support for Adobe Air app installations
Adobe Air applications take the form of a .air file that the Adobe Air
runtime then installs and creates a .app -- typically in
/Applications.  This patch provides a new container for those .air
files which the Adobe Air runtime installs to the Caskroom as well as
tests for Adobe Air app installations.

Presently, if homebrew-cask doesn't detect the Adobe Air runtime, it
will provide an informative error message and instructions to obtain
it via `brew cask install adobe-air`.  This is obviously not ideal and
the installation process for the runtime should be automated in the
future.
2014-02-17 11:36:01 -06:00
Roland Walker 40ad897da8 further cleanup/refactor of link artifacts
Following up on #2874, we should no longer need `linked_path`,
but instead simply refer to `target`.

This also fixes a bug in which some links were not removed
during `uninstall`.  Example:
  binary 'oclint-0.7-x86_64-apple-darwin-10/lib/oclint', :target => '/usr/local/lib/oclint'
2014-02-17 12:33:38 -05:00
Roland Walker 21702f5dfe Merge pull request #2961 from rolandwalker/system_command_followups
System command followups
2014-02-17 11:35:01 -05:00
Roland Walker 6096cc8d57 fork `abv` method with better odd-filename defense
Fixes #2917.  New method is named `cabv`. The original `abv`
method is in Homebrew at `Library/Homebrew/extend/pathname.rb`
2014-02-17 11:13:39 -05:00
Roland Walker 4ffb624e87 cut v0.29.1 2014-02-15 12:31:59 -05:00
Roland Walker 660b4b08bf enforce valid values for :stderr on command.run 2014-02-15 12:21:27 -05:00
Roland Walker 5ab9c712e4 typo: :stderr accepts :silence 2014-02-15 12:04:49 -05:00
Roland Walker e4554a170a force consistent timestamps for SVN downloads
to make checksumming work correctly
2014-02-15 12:04:00 -05:00
Roland Walker ee29d1ee4a cut v0.29.0 2014-02-15 08:50:49 -05:00
Roland Walker fbcbcd21be Merge pull request #2761 from rolandwalker/private_eye_followups
sleep during uninstall, allow `:must_succeed`
2014-02-15 07:44:33 -05:00
Roland Walker b67b2c53f2 make clear that only Alfred 2.x is supported
fixes #2891
2014-02-14 19:39:45 -05:00
Roland Walker 15f437ed7b remove md5 checksum support
Following up on #2719.  MD5 checksums are
* nowhere mentioned in our docs
* not used in any existing Cask
* deprecated in Homebrew
Therefore it seems sensible to delete this code.
2014-02-14 19:15:55 -05:00
Roland Walker 82452b3181 Merge pull request #2822 from rolandwalker/svn_download_strategy
add Cask::SubversionDownloadStrategy
2014-02-14 13:27:13 -05:00
Roland Walker 82b9d30a57 Merge pull request #2742 from rolandwalker/before_install
add `before_install` and `before_uninstall`
2014-02-13 11:19:33 -05:00
Roland Walker aae522966e Merge pull request #2875 from rolandwalker/caveats_formatting_2
trailing blank lines so caveats don't run together
2014-02-12 18:29:39 -05:00
Paul Hinze 9dc6fd9562 Merge pull request #2734 from rolandwalker/sort_predictability
make order consistent across Ruby vsns w/sort
2014-02-12 15:26:56 -06:00
Roland Walker d12acbdf9d Merge pull request #2739 from rolandwalker/allow_untrusted
add `:allow_untrusted` modifier on `install`
2014-02-12 09:39:45 -05:00
Roland Walker eb7f9eb078 trailing blank lines so caveats don't run together 2014-02-12 09:27:49 -05:00
Roland Walker 48accc49c6 list/target refactor
This follows up #2532 and #2392 abstracting out some duplicated
code.  Still not perfect, but better.
2014-02-12 08:39:11 -05:00
Roland Walker 18a92caf57 Merge pull request #2392 from rolandwalker/list_managed_links
Show managed links in "brew cask list"
2014-02-12 08:11:44 -05:00
Roland Walker 298d98d204 fixup #2872 2014-02-12 08:03:07 -05:00
Roland Walker c5dd610f2a make criteria work again when cabextract missing
addresses an incidental report in #2467
2014-02-12 07:55:43 -05:00
Roland Walker 45ed67c64f add :allow_untrusted modifier on install 2014-02-11 14:40:16 -05:00
Roland Walker 0700813da7 Merge pull request #2851 from rolandwalker/system_command_followups
System command followups
2014-02-11 10:13:46 -05:00
Roland Walker d0970948ce Merge pull request #2759 from rolandwalker/cleanup_cmd
add command `brew cask cleanup`
2014-02-11 06:25:21 -05:00
Roland Walker 5548bc4756 test valid keys in _process_options
add monkeypatch on Hash in utils.rb for `assert_valid_keys` method
2014-02-10 10:57:55 -05:00
Roland Walker 545fc276dc allow command.run without arguments
ie only an exectuable
2014-02-10 10:53:38 -05:00
Roland Walker 7d8abee751 don't choke when :args is not present
in _process_options
2014-02-10 10:53:30 -05:00
Paul Hinze 9fd35a9a04 Merge pull request #2841 from phinze/version-namespace
restrict visibility of Cask namespace in Formula
2014-02-09 23:39:50 -05:00
Paul Hinze 753bc59dcb restrict visibility of Cask namespace in Formula
we had collision issues with homebrew's 'cask' formula (for the emacs
package manager project).

this keeps the in-project and in-formula visibility of the version
number via the old "namespaced global" strategy that keeps a `Cask`
constant out of view of the formula.
2014-02-09 14:14:07 -05:00
Lucas Garron 3c00e22dc1 Report SHA-256 hash (instead of SHA-1) if checksum is missing.
I accidentally missed this in #2719.
2014-02-09 04:23:00 -08:00
Roland Walker 8450a29a6a Show managed links in "brew cask list"
Fixes #2261
2014-02-08 16:26:23 -05:00
Roland Walker de78b0f359 sleep during uninstall, allow :must_succeed
on script directives. followups from #1802. amend private-eye Cask.
2014-02-08 16:15:15 -05:00
Roland Walker d6c8a6917d add command `brew cask cleanup`
plus new option --outdated
2014-02-08 14:40:53 -05:00
Roland Walker b55f1804f0 add Cask::SubversionDownloadStrategy
abstract out module `Cask::DownloadStrategy`, add some commentary
2014-02-08 13:30:21 -05:00
Paul Hinze 1f5cc4e1e8 Merge pull request #2719 from lgarron/sha256
Change the template hash function to SHA-256.
2014-02-08 12:20:33 -06:00
Paul Hinze 9faa44e6cc Merge pull request #1992 from rolandwalker/core_fonts
CAB containers
2014-02-08 12:14:18 -06:00
Roland Walker 65292780aa exit with errorcode 1 when a list error occurs
Fixes #2817.  This is now more consistent with Homebrew's
`list`, though not completely, because Homebrew's `list`
refuses to give any output when there is an invalid Formula
argument.  Our `list` stumbles forward instead, giving such
output as is possible based on valid args, but still exiting
with error when invalid args are seen.
2014-02-08 10:03:26 -05:00
Roland Walker 895b838d1d Merge pull request #2748 from rolandwalker/only_once
enforce: certain DSL elements may appear only 1x
2014-02-07 07:48:44 -05:00
Victor Robertson 7f5fbf448c Process SystemCommand arguments in list format
Previously, SystemCommand commands and arguments were processed as
strings which caused problems during shell interpretation if the
arguments were not escaped properly.  Now all commands are expressed
as arrays and no longer require their arguments to be escaped.
Additionally, stderr and stdout could have been interleaved in the
past and now they are always separated.
2014-02-07 06:27:05 -06:00
Roland Walker 50864dc4b3 add `before_install` and `before_uninstall` 2014-02-06 08:32:12 -05:00
Roland Walker 320f8a46d8 Merge pull request #2637 from rolandwalker/version_caveats
add os_version_only to caveats DSL
2014-02-06 08:25:40 -05:00
Roland Walker 34f38caf3e add os_version_only to caveats DSL 2014-02-06 08:25:17 -05:00
Roland Walker f3803afa49 Merge pull request #2741 from rolandwalker/after_block
make sure "after" blocks really run last
2014-02-06 08:22:41 -05:00
Roland Walker 90d6fa675c Merge pull request #2760 from rolandwalker/mkpath_casks_cache
add missing `HOMEBREW_CACHE_CASKS.mkpath`
2014-02-06 08:22:03 -05:00
Lucas Garron 913f3e6f76 Change default hash to SHA-256. 2014-02-05 18:16:18 -08:00
Roland Walker 9df14ceb4f rename class to `Cask::CurlDownloadStrategy`
To make room to use some of the other download strategies
classes provided by Homebrew, be explicit that we are currently
using only the curl class.
2014-02-05 10:30:58 -05:00
Roland Walker 379f3e7c88 add missing `HOMEBREW_CACHE_CASKS.mkpath`
If `mkpath` must be done for the parent dir, then it certainly
must also be done for the child dir.
2014-02-05 09:57:35 -05:00
Roland Walker a530a9005c enforce: certain DSL elements may appear only 1x
add CaskInvalidError exception, which ought to be used in
several other places as well
2014-02-04 08:27:12 -05:00
Roland Walker 9a0751b33a realpath hygiene for external commands
For external commands which do not support the doubledash convention
(#2613), wrap file arguments in Pathname.new(file).realpath at the
very last minute.  This provides a guarantee against surprises caused
by unusual filenames which might be misinterpreted as flags.
2014-02-03 20:02:34 -05:00
Roland Walker 15d1fe8bbf Merge pull request #2613 from rolandwalker/double_dash
Doubledash hygiene for external commands
2014-02-03 17:00:29 -08:00
Roland Walker 36ce20a4ee support CAB archives 2014-02-03 18:37:20 -05:00
Roland Walker 7476fcbfdf Merge pull request #2743 from rolandwalker/screen_saver_followups
tiny nits on new Screen Saver artifact
2014-02-03 10:22:39 -08:00
Roland Walker d03239e3c1 make sure "after" blocks really run last
and make it self-documenting by changing class name
2014-02-03 11:22:22 -05:00
Roland Walker 9445b05c4d tiny nits on new Screen Saver artifact
whitespace, filenames, orthography to be consistent with
other artifacts. No functional change.
2014-02-03 11:21:09 -05:00
Roland Walker 935ae52eb8 make order consistent across Ruby vsns w/sort
Fixes #2635.  In particular, link and cookie order differ
between Ruby 1.8.7 and 2.x, causing the test suite to fail
under 1.8.7.
2014-02-01 14:24:32 -05:00
Roland Walker b737ff758d add new method depends_on_formula to odumpcask 2014-02-01 12:44:09 -05:00
Roland Walker 3a1c9484a3 Divide search output into sections
typically "Exact Match" and "Partial Matches"
2014-01-31 20:20:30 -05:00
Roland Walker 288805e6ea doubledash hygiene for external cmd: file 2014-01-31 13:05:10 -05:00
Roland Walker 061483571c doubledash hygiene for external cmd: kextunload 2014-01-31 13:05:10 -05:00
Roland Walker 4b87101f1f doubledash hygiene for external cmd: chmod 2014-01-31 13:05:09 -05:00
Roland Walker 0b1814979e doubledash hygiene for external cmd: launchctl 2014-01-31 13:05:09 -05:00
Roland Walker d8a7e5aad9 doubledash hygiene for external cmd: rmdir 2014-01-31 13:05:09 -05:00
Roland Walker 06395054d6 doubledash hygiene for external cmd: open 2014-01-31 13:05:09 -05:00
Roland Walker 6038fd221d doubledash hygiene for external cmd: ditto 2014-01-31 13:05:09 -05:00
Roland Walker a7f1bc6693 doubledash hygiene for external cmd: rm 2014-01-31 13:05:09 -05:00
Roland Walker b2de57cf0f doubledash hygiene for external cmd: ln 2014-01-31 13:02:15 -05:00
Roland Walker 3cc22374f9 doubledash hygiene for external cmd: sudo, AND
also includes doubledash hygiene for any child commands following each sudo
2014-01-31 12:58:39 -05:00
Roland Walker 7d34e7b9cc cut v0.28.0 2014-01-30 11:56:34 -05:00
Roland Walker 99f0c4827e Merge pull request #2697 from rolandwalker/req_cask_version
make version number available within brew-cask
2014-01-30 07:58:35 -08:00
Roland Walker 28a84baf92 Merge pull request #2545 from rolandwalker/search_followups
search docs/test/fix tapname-search
2014-01-29 09:14:26 -08:00
Roland Walker 2a450c3a07 make version number available within brew-cask
brew cask doctor was showing 1.8.7 as the homebrew-cask software version
2014-01-29 10:00:13 -05:00
Roland Walker 98f93c45bc Merge pull request #2670 from rolandwalker/relative_readlink_safety
BUGFIX: readlink requires chdir for relative links
2014-01-29 06:27:44 -08:00
Roland Walker 82504947e9 BUGFIX: readlink requires chdir for relative links
Fixes #2650 (although there is more work to be done).  The issue is that
path.readlink.exist? returned false for all relative links, because readlink
reads relative to the current working directory.  This caused relative
symlinks such as /usr/bin/tar to be deleted, because package mosh identified
/usr/bin as one of its container directories.

The simplest fix is not to use readlink at all, because path.exist?
will tell us what we want to know, independent of current dir.
2014-01-29 09:23:42 -05:00
Roland Walker ad31b17316 Merge pull request #2647 from jedahan/screensaver
initial screensaver work
2014-01-28 08:21:19 -08:00
Jonathan Dahan ca61dfdd81 Add support for screensaver artifact 2014-01-28 10:17:50 -05:00
Roland Walker 216444849e Add copious debugging with --debug
- add new file "cask/utils.rb" analogous to "utils.rb" in Homebrew
- define odebug and odumpcask, analogs of ohai and friends, but
  which only give output when --debug is in effect
- move the debug setting from an instance variable in Cask::CLI
  to a method Cask.debug, defined in "lib/cask/options.rb", which
  was added in #2276. (Perhaps options.rb should be merged back
  into Cask::CLI).
- sprinkle odebug statements liberally throughout the codebase
- update tests
2014-01-28 10:15:43 -05:00
Paul Hinze a45c118807 Merge pull request #2594 from rolandwalker/brewcask_external_commands
Support external commands beneath `brew cask`
2014-01-28 06:39:16 -08:00
Paul Hinze 36bd6f7554 Merge pull request #2576 from rolandwalker/project_homepage
`brew cask home` with no args opens project page
2014-01-28 06:30:15 -08:00
Paul Hinze ae2d5822e1 Merge pull request #2592 from rolandwalker/arch_caveats
add arch_only to caveats mini-DSL
2014-01-28 06:29:16 -08:00
Paul Hinze 3179a55e71 Merge pull request #2391 from rolandwalker/uninstall_script_order
Defer :script uninstall, add :early_script
2014-01-28 06:20:43 -08:00
Roland Walker fabb5cfd9c Merge pull request #2618 from rolandwalker/launchctl_careful_unload
carefully unload launchctl services at uninstall
2014-01-28 03:21:07 -08:00
Roland Walker 73a7ea3cc2 Merge pull request #2593 from rolandwalker/doctor_arch
add architecture to `brew cask doctor`
2014-01-27 18:13:45 -08:00
Roland Walker 1efe356038 BUGFIX: don't try autocleanup inside system dirs
This safety feature addresses #2650 somewhat indirectly.
A list of system directories is defined.  When the uninstall
process encounters a "system directory" it does not touch that
directory at all
- no chmod on that dir
- no search for broken symlinks in that dir
- no cleanup of .DS_Store files in that dir
Explictly listed files from a pkg receipts are not affected by
this change.  Individual files will still be removed, even if
those files are in a special "system directory"
2014-01-27 19:18:14 -05:00
Roland Walker 2f2865f6b6 carefully unload lanchctl services at uninstall
Fixes #2601
- do a soft test to see if the service is loaded before attempting remove
- test/unload as both superuser and user as the service can be installed
  differently according to the original packags
- add tests for uninstall :launchctl; there were none previously
2014-01-27 08:26:45 -05:00
Paul Hinze a9aabf4f22 Merge pull request #2305 from rolandwalker/depends_on_brew
add dependencies for Homebrew formulae
2014-01-26 12:49:38 -08:00
Roland Walker c59ba39c91 Merge pull request #2532 from voanhduy1512/symlinked
Allow customizing the application symlink
2014-01-25 09:03:51 -08:00
Võ Anh Duy 2835172641 Allow customizing the application symlink 2014-01-25 23:43:12 +07:00
Roland Walker 768b21eae8 always submit external commands in list form
For safety.
- This is a step toward reworking system_command.rb so that
invocations are done in list form on the back end, avoiding
surprises from quoting and shell metacharacters.
- There is one transitional hack here: the _quote method in
Cask::SystemCommand is modified to avoid double-quoting.  The
_quote method itself will go away in a future revision when
only list-forms are used.
- Casks using system are not touched. It seems natural to
address that when creating the DSL for after_install/before_install.
2014-01-24 20:58:03 -05:00
Roland Walker 43362e4b3e Support external commands beneath `brew cask` 2014-01-24 12:07:42 -05:00
Roland Walker eaadc663be add architecture to `brew cask doctor` 2014-01-24 10:58:07 -05:00
Paul Hinze ce615d54b9 Merge pull request #2418 from rolandwalker/doctor_version
Numerous additions to "brew cask doctor"
2014-01-24 07:50:22 -08:00
Roland Walker 9d2d6e3575 add arch_only to caveats mini-DSL
Relevant to points raised by @goxberry in #2581
2014-01-24 10:43:00 -05:00
Roland Walker a5ce3cdbd8 search docs/test/fix tapname-search
This is the promised followup to #2496
- docs
- test
- bugfix: search string was being tested against fully-qualified
  Cask name including Tap, so "brew cask search phinze" would
  (confusingly) return all Casks.
2014-01-23 17:50:45 -05:00
Roland Walker e42f0f8dc1 Merge pull request #2546 from rolandwalker/indenting
indent to two spaces
2014-01-23 14:45:16 -08:00
Roland Walker 19f4ce3cfb `brew cask home` with no args opens project page
- in duplication of similar functionality in Homebrew
- in celebration of proposed design by @ndr-qef
2014-01-23 17:17:33 -05:00
Roland Walker 7a0f9ef37f always use full path to external utilities
per #2029
2014-01-23 12:20:32 -05:00
Roland Walker 9d439510d3 add dependencies for Homebrew Formulae
new DSL key `depends_on_formula`
2014-01-22 16:22:07 -05:00
Roland Walker da520b82f0 Numerous additions to "brew cask doctor"
New versions, paths, environment variables, and tests.
Side effect: release version must be stored in two locations.
2014-01-22 15:20:05 -05:00
Roland Walker 9b54342e42 indent to two spaces
This patch contains only whitespace changes, plus a short
addition to CONTRIBUTING.md on the project-wide indent style
2014-01-22 13:08:34 -05:00
Roland Walker e59dc2efcb cut v0.27.1 2014-01-22 11:50:20 -05:00
Roland Walker 619e4d7187 Merge pull request #2496 from rolandwalker/search_only_alpha
ignore non-alpha search chars; accept multi terms
2014-01-22 08:29:44 -08:00
Roland Walker 68108ce408 add missing ".undent"s 2014-01-20 15:14:43 -05:00
Roland Walker 6e111dec20 cut v0.27.0 2014-01-20 13:54:52 -05:00
Roland Walker 329c48298a caveats first-class in DSL, gets own mini-DSL
Make caveats a first-class member of the Cask DSL.  It no longer has to
be specified with "def caveats", but can be given as "caveats do ... end"
as with after_install blocks.

In addition, create a mini-DSL which can be used within caveats blocks,
providing standard messages when manual installers must be used,
reboot-required, etc.

Add alternate form: caveats can also accept a compile-time string for
simple cases.

This is 99% compatible with old Casks, as it still works by defining
a caveats method.  However, all Casks containing caveats are cleaned
up and adapted according to the new DSL.

Full docs in CONTRIBUTING.md.
2014-01-20 11:54:46 -05:00
Roland Walker 98fc7bfde2 Merge pull request #2416 from linc01n/input-method
Implement `input_method` artifact
2014-01-20 08:44:02 -08:00
Paul Hinze 3f8d9b0ffe move project version to idomatic location
gives project-internal visibility of the version constant for use in
displaying to the user.

the formula now does a targeted require to get the version constant from
the new location.
2014-01-20 10:26:13 -06:00
Roland Walker 212dc25941 ignore non-alpha search chars; accept multi terms 2014-01-20 00:14:50 -05:00
Roland Walker 283160b1e7 search.rb cleanups
- whitespace
- variable names: in particular, "casks" is a poor name for a
  variable that does not hold instances of Cask
2014-01-20 00:02:12 -05:00
Võ Anh Duy 38688aa755 Improve cash search
Ignore all the hyphens in cask title and search term

make "brew cask search" ignore case like #2461

restore search by regular expression feature
2014-01-20 11:47:56 +07:00
Roland Walker 4d2e520089 Defer :script uninstall, add :early_script
fixes #2254
2014-01-18 18:24:10 -05:00
Paul Hinze 9ab582e8ad Merge pull request #2329 from karbassi/checklinks
Added check for 'HTTP/1.1 302 Found'
2014-01-18 09:01:17 -08:00
Lincoln Lee cc14ebdb55 Implement `input_method` artifact 2014-01-19 00:40:56 +08:00
Roland Walker b58dd3e568 make "brew cask search" ignore case 2014-01-17 21:49:20 -05:00
Paul Hinze 9dbd309ba6 Merge pull request #2445 from rolandwalker/uninstall_messages
add missing user feedback during pkg uninstall
2014-01-17 16:48:18 -08:00
Paul Hinze bbc5bbe95e Merge pull request #2456 from rolandwalker/instance_methods_in_blocks
Allow cask instance methods within blocks
2014-01-17 16:47:11 -08:00
Roland Walker 3337ed8406 Add artifact caskroom_only
The difference between specifying caskroom_only and specifying
no install artifact at all is: caskroom_only respects the
uninstall stanza.  Obviously this is not the best implementation:
uninstall support should be refactored into the base class.
2014-01-17 18:57:32 -05:00
Roland Walker 15435e0357 Allow cask instance methods within blocks
This covers after_install and after_uninstall.  The caveats
stanza is treated separately.
2014-01-17 17:53:55 -05:00
Roland Walker 4e4d6027fe add missing user feedback during pkg uninstall
Consistent between uninstall keys.  Also give initial feedback
first, before any other action.
2014-01-16 10:15:11 -05:00
Roland Walker 81744a038d bugfix: make uninstall :script accept a hash
The indentation in CONTRIBUTING.md implies that :script accepts a hash.
But that is not the case. Instead :script accesses the entire hash defined
by uninstall.  Unrelated install keys such as :quit leak through to
@command.run! when attempting to exec :script.  Result: contrary to docs,
:script cannot be combined with other uninstall keys.

This PR makes uninstall :script accept a hash.  When :args or :input are not
needed, :script can still accept a plain string, so many Casks require no
alteration.

In addition
- adds key :executable, required when using hash argument to :script
- keys to :script are validated and sanitized before being passed to
  @command.run!
- adds :quit to with-installable.rb test to protect against regression
  on leaky keys
2014-01-11 12:20:59 -05:00
Fernando Paredes 3093e5a111 Merge pull request #2370 from troter/coteditor
Coteditor
2014-01-10 13:14:31 -08:00
Paul Hinze 6786f336e8 Merge pull request #2303 from rolandwalker/qualified_cask_names
handle fully-qualified cask names, fixes #2235
2014-01-10 11:23:43 -08:00
Paul Hinze fead909887 Merge pull request #2263 from rolandwalker/faster_uninstall
uninstall files in chunks of 500.
2014-01-10 11:09:06 -08:00
Paul Hinze 9135ff5730 Merge pull request #2258 from rolandwalker/hardlink_fonts
use hard links for fonts instead of symlinks
2014-01-10 11:06:17 -08:00
Paul Hinze 2412bfebbb Merge pull request #2360 from jfb/master
chown can only be run as root
2014-01-10 11:02:56 -08:00
Paul Hinze b850d78427 Merge pull request #2240 from linc01n/audit
Check no_checksum if version is latest in audit
2014-01-10 10:59:36 -08:00
Paul Hinze 9bd923fafa Merge pull request #2152 from Dillon-Benson/patch-2
shows that there are no casks matching a search term that did not result...
2014-01-10 10:58:45 -08:00
Paul Hinze 0967e4dd51 try forcing a require of homebrew's download_strategy
working on fixing #2275
2014-01-10 10:42:18 -06:00
Takumi IINO 4670d25369 Allow download url of sourceforge.jp 2014-01-10 14:59:25 +09:00
James Felix Black 83d5e7dfe4 chown can only be run as root
The logic here was flawed -- my caskroom.parent was writeable, but chown
was called regardless, causing an error.
2014-01-08 11:22:32 -08:00
Paul Hinze ec85054cb2 Merge pull request #2342 from rolandwalker/doctor_command
add command "brew cask doctor"
2014-01-08 09:44:09 -08:00
Roland Walker f2b3401310 Merge pull request #2345 from miguelfrde/2344-qlmanage
Run 'qlmanage -r' after installing a QuickLook plugin
2014-01-07 19:06:09 -08:00
Miguel Flores Ruiz de Eguino 877f96ad91 Run 'qlmanage -r' after installing a QuickLook plugin 2014-01-07 01:02:03 -06:00
Roland Walker d120d3b1a8 add command "brew cask doctor"
pursuant to discussion in #2275
2014-01-06 11:50:17 -05:00
Ali Karbassi bdac489804 Added check for 'HTTP/1.1 302 Found' 2014-01-06 00:42:45 -05:00
Stratos Moros 7136269198 implement `binary` artifact 2014-01-05 22:55:18 +02:00
Roland Walker 4123b05efa use hard links for fonts instead of symlinks
per an issue reported by @jgarber623.  Recast for compatibility
with #2300.
2014-01-04 12:39:37 -05:00
Paul Hinze a369f7ffd4 Merge pull request #2304 from rolandwalker/uri_feedback
add feedback when downloading a URI source
2014-01-04 07:50:44 -08:00
Roland Walker f223821038 add feedback when downloading a URI source
otherwise the user sees the curl progress bar w/o explanation
2014-01-04 07:43:29 -05:00
Roland Walker b88bf787e0 handle fully-qualified cask names, fixes #2235
form "<user>/<repo>/<cask>" may be used on cmdline, matching homebrew
- refactor Cask::Source::Tap into Cask::Source::Tapped, removing
  code, only handling unqualified cask names here now (ie no slash)
- create Cask::Source::TappedQualified, handling "<user>-<repo>/<cask>"
  form as before, and new form "<user>/<repo>/<cask>", for the case that
  the relevant tap already exists
- create Cask::Source::UntappedQualified, handling both command-line
  forms as above, but implicitly creating adding a new tap if it
  does not already exist
- add module Cask::QualifiedCaskName for utility functions on qualified
  Cask names
2014-01-04 07:14:35 -05:00
Roland Walker a4149be6ef refactor artifacts
- abstracts out common logic, much code removed
- fixes one bug/inconsistency: some artifacts failed to
  "return false" when the target exists in "preflight_checks".
- one trivial functional change: artifact type and quotation marks
  added in all user feedback (quotes needed b/c of pathnames
  containing spaces)
2014-01-03 17:08:09 -05:00
Roland Walker cfee08ab9e uninstall files in chunks of 500.
This is intended to address #2122.
2013-12-31 19:47:31 -05:00
Lincoln Lee 70302a4420 Check no_checksum if version is latest
Added one more check in audit if version is latest and have sha1 it will
not pass.
2013-12-30 20:46:11 +08:00
Dillon Benson 12cc9d4006 remove colon and add quotes to search not found message 2013-12-19 12:14:50 -05:00
Dillon Benson fdf43d7873 change search results message 2013-12-19 12:03:42 -05:00
Dillon Benson 10d0feef27 shows that there are no casks matching a search term that did not result in anything 2013-12-19 00:02:38 -05:00
Paul Hinze e46b89c908 Merge pull request #2081 from leoj3n/services-support
[WIP] services support
2013-12-15 15:26:44 -06:00
Paul Hinze 9c99f282e1 Merge pull request #2022 from rolandwalker/kext_check_unload
check if kext is present before attempting unload
2013-12-15 14:57:12 -06:00
Paul Hinze 36b0d166df make method_missing message much more explicit 2013-12-15 14:16:22 -06:00
Paul Hinze ac50e9d65b Merge pull request #2107 from phinze/headers-integration
Headers integration
2013-12-15 11:27:25 -08:00
Paul Hinze f6f507b289 some refactoring around the new download strategy
- move the interface from top-level methods to hash arguments of URL to
   keep the cask DSL as skinny as possible
 - promote the Cask::Headers object up to a Cask::URL object that
   encapsulates all infornation about the URL
 - pull all knowledge about curl arguments into the DownloadStrategy,
   leaving URL to act as a value object to be queried for details
 - test at the DownloadStrategy level; setting up expected curl args
   and example casks
2013-12-15 13:18:47 -06:00
Paul Hinze 24a53c4af7 Merge pull request #1944 from jonahoffline/add_headers_download_strategy
Add DownloadStrategy with custom :headers support
2013-12-14 09:13:58 -06:00
Paul Hinze fd82e97fa1 Merge pull request #2085 from pstadler/master
Handle CaskAlreadyInstalledError more graceful
2013-12-14 07:10:22 -08:00
Paul Hinze 6fa34a8e3e Merge pull request #2051 from rolandwalker/uninstall_flags
flag handling consistent btw install/uninstall
2013-12-14 07:07:45 -08:00
Paul Hinze 0c6e97b8fd use absolute paths for all commands
closes #2029
2013-12-14 08:48:40 -06:00
Paul Hinze 4bfc09ec02 Merge pull request #2066 from halo/master
Configurable Caskroom location, see #475
2013-12-14 06:00:31 -08:00
Patrick Stadler cb11080468 CaskAlreadyInstalledError exits with 0 2013-12-14 14:10:57 +01:00
future e7d98677fe Added inline comment on option parser so that people won't forget about the documentation 2013-12-14 10:13:06 +01:00
Joel Kuzmarski 7432affc59 services support 2013-12-13 18:13:19 -06:00
Roland Walker 9b4805be4e Merge pull request #2026 from rolandwalker/safer_quit_uninst
safer test for currently running app
2013-12-13 13:54:38 -08:00
Paul Hinze 8870f7c1fc Merge pull request #2008 from kevinSuttle/colorpickers 2013-12-13 10:40:36 -06:00
Paul Hinze 0a0c4a2d8a remove use of caller 2013-12-13 08:56:59 -06:00
Jonah Ruiz c92890ecc9 Refactor similar method structure in dirs and files into one for re-use.
By using the name of the method calling fs_command we remove duplication
2013-12-13 04:14:54 -04:00
Kevin Suttle 6dff4a35db Add support for colorpicker type 2013-12-12 22:59:58 -05:00
Jonah Ruiz 06be4b0d8e Add DownloadStrategy and Cask::Headers for custom :headers support
accepts a :user_agent argument and/or multiple :cookies
  headers :user_agent => 'Netscape/1.0', :cookies => { :cookey => "r00t" }

Also adds a standalone :fake_user_agent for a default UserAgent (Chrome)
  fake_user_agent
References #1175, #958
2013-12-12 21:29:12 -04:00
future af408269cf Make caskroom configurable via command line argument 2013-12-12 12:31:57 +01:00
Roland Walker ce4b83984c flag handling consistent btw install/uninstall
This makes uninstall process flag arguments in the same manner
as install. Any argument with a leading dash is assumed to be a
flag, not a Cask.  Argument processing still needs work, unknown
flags and spelling errors are silently accepted.
2013-12-11 17:15:33 -05:00
Roland Walker be7cc838a7 safer test for currently running app
The previous version could fail if the specified bundle was not installed.
Here we tell "System Events" until determining it is safe to do otherwise.
2013-12-09 22:23:27 -05:00
Roland Walker 07b9eea19b refine & document order of uninstall keys
Proposed order - :script, :launchctl, :quit, :kext, :pkgutil, :files.  Quit
a process before attempting to unload an assocated kext, unload kext before
attempting to delete the associated file, etc.  Arguably :script fits
loically with :files near the end of the list.  However, we also have
:after_uninstall which implicitly fires immediately after :files.
Therefore, running :script early provides greater functionality.
2013-12-09 21:34:30 -05:00
Fernando Paredes 150c5bcf6f Merge pull request #2019 from rolandwalker/validate_uninstall_keys
validate keys given to :uninstall
2013-12-09 17:25:27 -08:00
Roland Walker bd9d680b03 check if kext is present before attempting unload
this is intended to address #1941
2013-12-09 19:37:07 -05:00
Roland Walker cf56f10555 add :quit key to uninstall check 2013-12-09 14:17:03 -05:00
Roland Walker dda6573d47 validate keys given to :uninstall
this should also be part of audit
2013-12-09 10:39:34 -05:00
Roland Walker 6d05664532 add :quit key to uninstall
The applescript is divided into two commands to keep from transiently
invoking the application in the case where it is not currently running.
2013-12-09 09:23:53 -05:00