mirror of
https://github.com/atom/atom.git
synced 2026-04-28 03:01:47 -04:00
Use xargs -0 instead of sed, as this is easier to understand.
Fixed atom/atom#4337 Fixes atom/atom#4336
This commit is contained in:
2
atom.sh
2
atom.sh
@@ -50,7 +50,7 @@ if [ $OS == 'Mac' ]; then
|
||||
|
||||
# If ATOM_PATH isn't a executable file, use spotlight to search for Atom
|
||||
if [ ! -x "$ATOM_PATH/$ATOM_APP_NAME" ]; then
|
||||
ATOM_PATH="$(mdfind "kMDItemCFBundleIdentifier == 'com.github.atom'" | grep -v ShipIt | sed '{s#/[^/]*$##; q; }')"
|
||||
ATOM_PATH="$(mdfind "kMDItemCFBundleIdentifier == 'com.github.atom'" | grep -v ShipIt | head -1 | xargs -0 dirname)"
|
||||
fi
|
||||
|
||||
# Exit if Atom can't be found
|
||||
|
||||
Reference in New Issue
Block a user