Re: Copying the path of files selected in Finder
Re: Copying the path of files selected in Finder
- Subject: Re: Copying the path of files selected in Finder
- From: Emmanuel Lévy <email@hidden>
- Date: Mon, 1 May 2017 14:32:29 +0200
I’ll test, but just to be sure, you did change the selection between the two parts of the test, didn’t you?
Otherwise, the 2nd time is always much faster than the 1st one.
My machine is an Early-2011 15” MacBook Pro with macOS 10.11.6.
All the best,
Emmanuel
> On 01 May 2017, at 05:13, Christopher Stone <email@hidden> wrote:
>
> On 04/30/2017, at 06:34, Emmanuel Lévy <email@hidden> wrote:
>> You must be right in some context, but as for me I see no difference, in both cases Finder requires 0.025 second per item selected.
>
> Hey Emmanuel,
>
> My best guess is that your system is faster than mine, since I'm using a Mid-2010 17" MacBook Pro with macOS 10.12.4.
>
> How many selected files did you test with?
>
> Try upping the number.
>
> Tested with Smile 3.8.0 (build 988) using separate scripts.
>
> Finder References:
>
> ------------------------------------------------------------------------------
> chrono
>
> # Finder References
> tell application "Finder"
> set finderSelectionList to the selection
> end tell
>
> set elapsedTime to chrono
> log "Finder Selection as Finder References List of " & length of finderSelectionList & " items:"
> log " Elapsed Time: " & (format elapsedTime into "##.#####") & " seconds"
> log " Time per Item: " & (format (elapsedTime / (length of finderSelectionList)) into "##.#####") & " seconds"
> log linefeed
> ------------------------------------------------------------------------------
>
> Alias List:
>
> ------------------------------------------------------------------------------
> chrono
>
> # Alias List
> tell application "Finder"
> set finderSelectionList to the selection as alias list
> end tell
>
> set elapsedTime to chrono
> log "Finder Selection as Alias List of " & length of finderSelectionList & " items:"
> log " Elapsed Time: " & (format elapsedTime into "##.#####") & " seconds"
> log " Time per Item: " & (format (elapsedTime / (length of finderSelectionList)) into "##.#####") & " seconds"
> log linefeed
> ------------------------------------------------------------------------------
>
> Finder Selection as Finder References List of 250 items:
> Elapsed Time: 1.31477 seconds
> Time per Item: 0.00526 seconds
>
> Finder Selection as Alias List of 250 items:
> Elapsed Time: 0.49492 seconds
> Time per Item: 0.00198 seconds
>
> ------------------------------------------------------------------------------
>
> Finder Selection as Finder References List of 500 items:
> Elapsed Time: 2.55785 seconds
> Time per Item: 0.00512 seconds
>
> Finder Selection as Alias List of 500 items:
> Elapsed Time: 0.87233 seconds
> Time per Item: 0.00174 seconds
>
> ------------------------------------------------------------------------------
>
> As you can see there's a significant difference – on my system at least.
>
> --
> Take Care,
> Chris
>
> _______________________________________________
> Do not post admin requests to the list. They will be ignored.
> AppleScript-Users mailing list (email@hidden)
> Help/Unsubscribe/Update your Subscription:
> Archives: http://lists.apple.com/archives/applescript-users
>
> This email sent to email@hidden
_______________________________________________
Do not post admin requests to the list. They will be ignored.
AppleScript-Users mailing list (email@hidden)
Help/Unsubscribe/Update your Subscription:
Archives: http://lists.apple.com/archives/applescript-users
This email sent to email@hidden