Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]
Groups > comp.sys.mac.system > #125808
| Path | csiph.com!fu-berlin.de!uni-berlin.de!individual.net!not-for-mail |
|---|---|
| From | Jolly Roger <jollyroger@pobox.com> |
| Newsgroups | comp.sys.mac.system |
| Subject | Re: photolibraryd |
| Date | 17 Aug 2019 17:00:31 GMT |
| Organization | People for the Ethical Treatment of Pirates |
| Lines | 68 |
| Message-ID | <grqq5eFoonbU1@mid.individual.net> (permalink) |
| References | <qj6kqu$ov0$1@dont-email.me> <gro4l0F75egU1@mid.individual.net> <qj80nf$klh$1@dont-email.me> |
| Mime-Version | 1.0 |
| Content-Type | text/plain; charset=utf-8 |
| Content-Transfer-Encoding | 8bit |
| X-Trace | individual.net 5kl6+7JQBIE8Ps9CAiItUwApgipm/ewju62xdMJfnJp3pkjzwd |
| Cancel-Lock | sha1:FVChydfLSSnwAVX2ieDejonuyOM= |
| X-No-Archive | Yes |
| MMail-Copies-To | nobody |
| X-Face | _.g>n!a$f3/H3jA]>9pN55*5<`}Tud57>1<n@LQ!aZ7vLO_nWbK~@T'XIS0,oAJcU.qLM dk/j8Udo?O"o9B9Jyx+ez2:B<nx(k3EdHnTvB]'eoVaR495,Rv~/vPa[e^JI+^h5Zk*i`Q;ezqDW< ZFs6kmAJWZjOH\8[$$7jm,Ogw3C_%QM'|H6nygNGhhl+@}n30Nz(^vWo@h>Y%b|b-Y~()~\t,LZ3e up1/bO{=-) |
| User-Agent | slrn/1.0.1 (Darwin) |
| Xref | csiph.com comp.sys.mac.system:125808 |
Show key headers only | View raw
On 2019-08-17, Király <me@home.spamsucks.ca> wrote:
> Jolly Roger <jollyroger@pobox.com> wrote:
>>
>> It's possible that behavior is due to a bug. It's also possible that
>> Apple hasn't considered this use case (two users sharing the same
>> library on a volume whose ownership & permissions are ignored.
>>
>> Seems like a great candidate for a bug report.
>
> Yeah, but I doubt Apple will fix this for me. I'm using a 10 year old
> iMac, so stuck on High Sierra. Was hoping for a homemade solution,
> like some way to automate the force quitting of photolibraryd when the
> Photos app is quit.
That's easy to do with most scripting languages, including AppleScript.
Put this code into a new Script Editor window and save it as Format:
Application with the Stay open after run handler option enabled. Then
you can run it at login by adding it to your System Preferences > Users
& Groups > Login Items panel:
-- begin script
property waiting : false
on run
set waiting to false
end run
on idle
if waiting then
if not AppIsRunning("Photos") then
set pid to ProcessIsRunning("photolibraryd")
if pid is not "" then
set killResults to do shell script ("kill -9 " & pid as text)
if killResults is not "" then
tell application "System Events" to display alert "Potential Error" message ("Kill command returned unexpected results: " & return & return & killResults as text) buttons {"Thanks"} default button 1
end if
end if
end if
else
if AppIsRunning("Photos") then
set waiting to true
end if
end if
return 1
end idle
on AppIsRunning(appName)
tell application "System Events"
set isRunning to (appName is in (name of every process))
end tell
return isRunning
end AppIsRunning
on ProcessIsRunning(processName)
set pid to ""
try
set pid to do shell script ("pgrep " & processName as text)
end try
return pid
end ProcessIsRunning
-- end script
--
E-mail sent to this address may be devoured by my ravenous SPAM filter.
I often ignore posts from Google. Use a real news client instead.
JR
Back to comp.sys.mac.system | Previous | Next — Previous in thread | Next in thread | Find similar | Unroll thread
photolibraryd me@home.spamsucks.ca (Király) - 2019-08-16 16:15 +0000
Re: photolibraryd ~BD~ <dgb@nomail.invalid> - 2019-08-16 17:25 +0100
Re: photolibraryd Jolly Roger <jollyroger@pobox.com> - 2019-08-16 16:41 +0000
Re: photolibraryd me@home.spamsucks.ca (Király) - 2019-08-17 04:44 +0000
Re: photolibraryd gtr <xxx@yyy.zzz> - 2019-08-16 22:49 -0700
Re: photolibraryd Jolly Roger <jollyroger@pobox.com> - 2019-08-17 17:00 +0000
Re: photolibraryd me@home.spamsucks.ca (Király) - 2019-08-17 22:29 +0000
Re: photolibraryd Jolly Roger <jollyroger@pobox.com> - 2019-08-18 22:40 +0000
Re: photolibraryd me@home.spamsucks.ca (Király) - 2019-08-22 15:34 +0000
Re: photolibraryd Jolly Roger <jollyroger@pobox.com> - 2019-08-22 15:52 +0000
Re: photolibraryd gtr <xxx@yyy.zzz> - 2019-08-22 21:49 -0700
Re: photolibraryd Jolly Roger <jollyroger@pobox.com> - 2019-08-23 18:31 +0000
Re: photolibraryd gtr <xxx@yyy.zzz> - 2019-08-23 17:39 -0700
Re: photolibraryd Jolly Roger <jollyroger@pobox.com> - 2019-08-24 19:27 +0000
Re: photolibraryd me@home.spamsucks.ca (Király) - 2019-08-26 15:41 +0000
Re: photolibraryd Jolly Roger <jollyroger@pobox.com> - 2019-08-27 23:09 +0000
csiph-web