Bug 41 - On Mac OS X, it's probably better to use open(1) for DISPLAYCMD than require X11
Summary: On Mac OS X, it's probably better to use open(1) for DISPLAYCMD than require X11
Status: CONFIRMED
Alias: None
Product: abcde
Classification: Unclassified
Component: Album art (show other bugs)
Version: unspecified
Hardware: All All
: Normal normal
Assignee: Andrew Strong
URL:
Depends on:
Blocks:
 
Reported: 2016-08-27 23:48 BST by Gabriel Rosenkoetter
Modified: 2016-08-27 23:55 BST (History)
1 user (show)

See Also:


Attachments
add handling to use native open(1) as DISPLAYCMD on Mac OS X (1.03 KB, application/octet-stream)
2016-08-27 23:48 BST, Gabriel Rosenkoetter
Details
a few line addition to abcde.conf about how Mac OS X users may want to set DISPLAY (848 bytes, patch)
2016-08-27 23:49 BST, Gabriel Rosenkoetter
Details
add handling to use native open(1) as DISPLAYCMD on Mac OS X (1.03 KB, patch)
2016-08-27 23:50 BST, Gabriel Rosenkoetter
Details
a few line addition to abcde.conf about how Mac OS X users may want to set DISPLAYCMD (851 bytes, patch)
2016-08-27 23:55 BST, Gabriel Rosenkoetter
Details

Note You need to log in before you can comment on or make changes to this bug.
Description Gabriel Rosenkoetter 2016-08-27 23:48:46 BST
Created attachment 27 [details]
add handling to use native open(1) as DISPLAYCMD on Mac OS X

Mac OS X has a native GUI and, although there are several X11 servers out there, if all you want to do is display album art, it's probably not necessary to depend on ImageMagick.

The attached patch sets DISPLAY to "Quartz" (only if it's not already set to something; that's to get past the check for $DISPLAY != "", which I'm pretty sure is there to say "don't try to do X11 without an X11 server") and DISPLAYCMD to the Apple-provided open(1) command, which does the same thing that the user would get if they highlighted an item in the GUI and chose "Open" from the File Menu. In the case of images, this is by default "open the file in Preview.app".

I'm also including a patch for abcde.conf that adds some explanation of open(1) and why a user would care: not clear whether you guys would want to include that.

Note that this doesn't account for CONVERT at all: if there's a Mac OS X-native way to do that, I don't know what it is.

patches against 2.7.3-UNRELEASED (2f566c2 according to gitweb) attached (but it's one line, so it's probably fine against 2.7.*).
Comment 1 Gabriel Rosenkoetter 2016-08-27 23:49:35 BST
Created attachment 28 [details]
a few line addition to abcde.conf about how Mac OS X users may want to set DISPLAY
Comment 2 Gabriel Rosenkoetter 2016-08-27 23:50:35 BST
Created attachment 29 [details]
add handling to use native open(1) as DISPLAYCMD on Mac OS X
Comment 3 Gabriel Rosenkoetter 2016-08-27 23:55:54 BST
Created attachment 31 [details]
a few line addition to abcde.conf about how Mac OS X users may want to set DISPLAYCMD