Claudia
3dbb735f3c
Fix PKG installer environment
...
This commit solves an issue where the environment handed to
`/usr/sbin/installer` is not the same as the environment used by the
graphical PKG installer.
This is evident in some post-install scripts, e. g. the
`component-10.pkg/Scripts/postinstall` script in the `dymo-label`
cask. The code says:
```
USER_ID=`id -u ${USER}`
launchctl bootstrap gui/$USER_ID /Library/LaunchAgents/com.dymo.dls.webservice.plist
```
The graphical installer will export e. g. `USER=alice`, and
everything works as intended.
However, `brew cask install` does not override `sudo`’s default,
which is `USER=ROOT`. This violates the assumptions in the script.
This commit fixes the issue by configuring `sudo` to override the
following environment variables with the proper user name:
- `LOGNAME`
- `USER`
- `USERNAME`
2018-07-06 09:38:00 +02:00
Markus Reiter
e07eddc391
Simplify Hbc::SystemCommand::Result#plist
.
2018-07-05 10:54:35 +02:00
alexbostock
296dd5ecb2
Fix format of cask JSON output
2018-07-04 15:08:32 +01:00
alexbostock
7e5addfb22
Add version number to cask JSON option
...
`$ brew cask info --json=v1 <formula>` instead of `$ brew cask info --json <formula>`
2018-07-04 15:03:31 +01:00
commitay
44a78a12a9
Merge pull request #4344 from commitay/cask-audit-all-appcasts
...
cask audit: check for devmate and hockeyapp appcasts
2018-07-04 11:13:40 +10:00
alexbostock
b548dbde97
Fix style
2018-07-02 10:46:41 +01:00
alexbostock
22b3102fbe
Add version number to cask json option
...
Old:
$ brew cask info --json <formula>
New:
$ brew cask info --json-v1 <formula>
2018-07-02 10:32:59 +01:00
alexbostock
0bfc6bd490
Improve format of git cask info --json output
2018-07-02 10:13:25 +01:00
alexbostock
2d5ae645d9
Add basic JSON option to brew cask
...
$ brew cask info --json <cask>
2018-07-02 09:05:49 +01:00
Mike McQuaid
61a8c4d1fb
Merge pull request #4300 from apjanke/new-rubocop-version
...
Upgrade to Rubocop 0.57.2
2018-07-01 09:08:16 +01:00
Andrew Janke
e0a8a79921
Style fixes for Rubocop 0.57.1
2018-06-30 19:40:14 -04:00
Markus Reiter
20b990a19f
Remove Cask#qualified_token
.
2018-06-30 06:03:51 +02:00
Markus Reiter
df3d017739
Fix Cask#full_name
.
2018-06-30 06:01:01 +02:00
commitay
b12498159b
cask audit: check for devmate and hockeyapp appcasts
2018-06-28 23:17:05 +10:00
Markus Reiter
6a44c529e5
Readd functionality to list all casks.
2018-06-23 01:54:07 +02:00
commitay
41e27928c4
Merge pull request #4232 from commitay/cask-caveats
...
cask fetch and upgrade: print caveats
2018-06-21 11:51:29 +10:00
Markus Reiter
25542d7398
Merge pull request #4316 from reitermarkus/merge-search
...
Merge `brew cask search` into `brew search`.
2018-06-18 21:31:33 +02:00
Markus Reiter
c814199a79
Merge pull request #4320 from lucafavatella/brew-cask-doctor
...
Fix `brew cask doctor` for non-standard installation location
2018-06-18 16:30:23 +02:00
Markus Reiter
8c620d8b97
Redirect brew cask search
to brew search
.
2018-06-18 16:23:35 +02:00
Markus Reiter
da193d2f7e
Merge brew cask search
into brew search
.
2018-06-18 16:23:35 +02:00
Vítor Galvão
9831e67452
Merge pull request #4346 from commitay/version-minor_patch
...
cask dsl versions: add minor_patch
2018-06-16 13:18:21 +01:00
commitay
c5bbf28dd6
cask dsl versions: add minor_patch
2018-06-15 22:40:33 +10:00
Luca Favatella
ece34dbe26
cask doctor: fix for non-standard installation location in ~
...
Symptom (relevant portions):
```
$ brew cask doctor
==> Homebrew-Cask Version
Homebrew-Cask 1.6.7-56-g9ebcef7
Homebrew/homebrew-cask (git revision fc24e; last commit 2018-06-09)
==> macOS
10.13.5
==> SIP
Enabled
...
==> Homebrew-Cask Install Location
<NONE>
==> Homebrew-Cask Staging Location
~/homebrew/Caskroom
...
==> Environment Variables
HOMEBREW_CASK_OPTS="--appdir=~/Applications"
LC_ALL="en_US.UTF-8"
PATH="/usr/bin:/bin:/usr/sbin:/sbin:~/homebrew/Library/Homebrew/shims/scm"
SHELL="/bin/bash"
Cask's Doctor Checkup: failed
- The staging path ~/homebrew/Caskroom does not exist.
Error: There are some problems with your setup.
```
Analysis:
* The source code is
[this](9ebcef785e/Library/Homebrew/cask/lib/hbc/cli/doctor.rb (L63-L66)
).
* The issue is reproducible in `brew irb`:
```
$ ls -dl ~/homebrew/Caskroom
drwxrwxr-x 10 luca admin 340 9 Jun 16:22 /Users/luca/homebrew/Caskroom
$ ( cd ~ && pwd; )
/Users/luca
$ ls -dl /Users/luca/homebrew/Caskroom
drwxrwxr-x 10 luca admin 340 9 Jun 16:22 /Users/luca/homebrew/Caskroom
$ brew irb
==> Interactive Homebrew Shell
Example commands available with: brew irb --examples
irb(main):001:0> Pathname.new("~/homebrew/Caskroom").exist?
=> false
irb(main):002:0> Pathname.new("/Users/luca/homebrew/Caskroom").exist?
=> true
```
2018-06-14 23:58:03 +01:00
Luca Favatella
cac30f6186
cask doctor: delete unused render_* methods
2018-06-14 23:56:35 +01:00
Markus Reiter
b45996dada
Don’t use ohai
for SystemCommand
output.
2018-06-14 22:45:20 +02:00
commitay
7a48e04d07
internal_audit_modified_casks: remove appcast
2018-06-11 13:15:32 +10:00
commitay
c3ac638b9f
appcast: remove calculate_checkpoint
2018-06-11 13:15:32 +10:00
commitay
0980de4cb0
_appcast_checkpoint: remove
2018-06-11 13:15:30 +10:00
commitay
c68526ac09
audit: remove appcast checkpoints
2018-06-11 13:14:00 +10:00
Markus Reiter
1d27c5f79a
Don't create Caskroom.path
for tests.
2018-06-09 11:32:49 +02:00
Markus Reiter
767ebe6ab6
Fail brew cask upgrade
early if Cask is not installed.
2018-06-09 11:27:44 +02:00
Markus Reiter
488149242b
Remove Hbc.init
.
2018-06-09 11:18:40 +02:00
Markus Reiter
b2f67c6d77
Remove the need for ensure_cache_exists
.
2018-06-09 11:13:37 +02:00
Markus Reiter
1c153f7781
Remove Locations
module.
2018-06-09 10:14:13 +02:00
Markus Reiter
12ab263784
Remove Hbc.default_tap
.
2018-06-09 10:13:28 +02:00
Markus Reiter
3d423b0587
Add path
method to Caskroom
and Cache
.
2018-06-09 09:52:48 +02:00
Markus Reiter
458a1e7903
Remove Locations
module.
2018-06-09 09:01:09 +02:00
Markus Reiter
cb7f25ceb8
Refactor brew cask search
.
2018-06-07 18:42:30 +02:00
Markus Reiter
cc93997fb7
Refactor search_taps
.
2018-06-07 14:02:31 +02:00
Markus Reiter
dd8370a9fa
Move shared search logic into Homebrew::Search
module.
2018-06-07 13:50:10 +02:00
Markus Reiter
14b3b82fca
Remove exact match from brew cask search
.
2018-06-07 13:48:35 +02:00
Markus Reiter
e786bb08c9
Use search_taps
in brew cask search
.
2018-06-07 13:48:35 +02:00
commitay
b9b3952494
cask audit: review changes
2018-06-05 19:20:38 +10:00
commitay
f012b5acf8
cask audit: check for sourceforge appcast
2018-06-05 16:42:19 +10:00
Vítor Galvão
b088302e11
Merge pull request #4224 from vitorgalvao/fix-language-bug
...
HBC: Make language stanza order not matter
2018-06-04 00:55:45 +01:00
commitay
a48e42e9dd
cask fetch and upgrade: print caveats
2018-06-02 11:31:38 +10:00
Markus Reiter
e07e036695
Moving and copying must succeed.
2018-06-01 03:31:12 +02:00
Vítor Galvão
dc1edf6bfc
cask --language: have specific match always trump general
2018-05-29 11:42:05 +01:00
Markus Reiter
c89ae8c5ab
Fall back to CaskLoader.load
to get a better error message.
2018-05-26 16:05:51 +02:00
Markus Reiter
de246cc528
Update Homebrew-Cask references.
2018-05-25 18:20:02 +02:00