Quantcast

specialFolderPath("resources") on Mac with trailing slash

classic Classic list List threaded Threaded
4 messages Options
Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate

specialFolderPath("resources") on Mac with trailing slash

prothero--- via use-livecode
Hello,

LC 8.1.3: getting the specialFolderPath("resources") comes on Mac & Win
without trailing slash.

On Win I also don't get a trailing slash in a standalone.

BUT in a MacOS 10.12 standalone I get a trailing slash!

Is this a wanted "feature" which I have to script around, or is this a bug I
should file?

What do you think?

Tiemo

 

 

 

_______________________________________________
use-livecode mailing list
[hidden email]
Please visit this url to subscribe, unsubscribe and manage your subscription preferences:
http://lists.runrev.com/mailman/listinfo/use-livecode
Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate

Re: specialFolderPath("resources") on Mac with trailing slash

prothero--- via use-livecode
Hi Tiemo,

This is a bug, which will be fixed in LiveCode 8.1.4 RC-1:

http://quality.livecode.com/show_bug.cgi?id=18619

Best,
Panos
--

On Wed, Mar 29, 2017 at 9:43 AM, Tiemo Hollmann TB via use-livecode <
[hidden email]> wrote:

> Hello,
>
> LC 8.1.3: getting the specialFolderPath("resources") comes on Mac & Win
> without trailing slash.
>
> On Win I also don't get a trailing slash in a standalone.
>
> BUT in a MacOS 10.12 standalone I get a trailing slash!
>
> Is this a wanted "feature" which I have to script around, or is this a bug
> I
> should file?
>
> What do you think?
>
> Tiemo
>
>
>
>
>
>
>
> _______________________________________________
> use-livecode mailing list
> [hidden email]
> Please visit this url to subscribe, unsubscribe and manage your
> subscription preferences:
> http://lists.runrev.com/mailman/listinfo/use-livecode
>
_______________________________________________
use-livecode mailing list
[hidden email]
Please visit this url to subscribe, unsubscribe and manage your subscription preferences:
http://lists.runrev.com/mailman/listinfo/use-livecode
Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate

AW: specialFolderPath("resources") on Mac with trailing slash

prothero--- via use-livecode
Thanks for the quick answer :)
Tiemo

-----Ursprüngliche Nachricht-----
Von: use-livecode [mailto:[hidden email]] Im Auftrag
von panagiotis merakos via use-livecode
Gesendet: Mittwoch, 29. März 2017 10:49
An: How to use LiveCode <[hidden email]>
Cc: panagiotis merakos <[hidden email]>
Betreff: Re: specialFolderPath("resources") on Mac with trailing slash

Hi Tiemo,

This is a bug, which will be fixed in LiveCode 8.1.4 RC-1:

http://quality.livecode.com/show_bug.cgi?id=18619

Best,
Panos
--

On Wed, Mar 29, 2017 at 9:43 AM, Tiemo Hollmann TB via use-livecode <
[hidden email]> wrote:

> Hello,
>
> LC 8.1.3: getting the specialFolderPath("resources") comes on Mac &
> Win without trailing slash.
>
> On Win I also don't get a trailing slash in a standalone.
>
> BUT in a MacOS 10.12 standalone I get a trailing slash!
>
> Is this a wanted "feature" which I have to script around, or is this a
> bug I should file?
>
> What do you think?
>
> Tiemo
>
>
>
>
>
>
>
> _______________________________________________
> use-livecode mailing list
> [hidden email]
> Please visit this url to subscribe, unsubscribe and manage your
> subscription preferences:
> http://lists.runrev.com/mailman/listinfo/use-livecode
>
_______________________________________________
use-livecode mailing list
[hidden email]
Please visit this url to subscribe, unsubscribe and manage your subscription
preferences:
http://lists.runrev.com/mailman/listinfo/use-livecode


_______________________________________________
use-livecode mailing list
[hidden email]
Please visit this url to subscribe, unsubscribe and manage your subscription preferences:
http://lists.runrev.com/mailman/listinfo/use-livecode
Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate

Re: specialFolderPath("resources") on Mac with trailing slash

prothero--- via use-livecode
In reply to this post by prothero--- via use-livecode
panagiotis wrote:
 > On Wed, Mar 29, 2017 at 9:43 AM, Tiemo Hollmann TB wrote:
 >
 >> LC 8.1.3: getting the specialFolderPath("resources") comes on Mac &
 >> Win without trailing slash.
 >>
 >> On Win I also don't get a trailing slash in a standalone.
 >>
 >> BUT in a MacOS 10.12 standalone I get a trailing slash!
 >>
 >> Is this a wanted "feature" which I have to script around, or is this
 >> a bug I should file?
 >
 > This is a bug, which will be fixed in LiveCode 8.1.4 RC-1:
 >
 > http://quality.livecode.com/show_bug.cgi?id=18619

This is also a good reminder about code style for those of us who write
libraries:

The engine is pretty consistent about not including the trailing slash
with values returned from functions that are folder paths.

Indeed where it does, as we've seen here, it's probably a bug.

If we all follow that convention it can reduce the learning curve for
your APIs, and allow one to swap out one function for another with
relative ease.

I used to write my own folder path functions that included the trailing
slash.  Seemed like a good idea at the time, since it saved me from
having to include the slash when concatenating with a file name later on.

But I found over time that I had to think about things too much, to keep
track of which functions included the slash and which didn't, so I could
concatenate correctly, avoiding double slashes.

No more.  Now I follow the engine convention of not including the
trailing slash, and life is that much simpler. :)

--
  Richard Gaskin
  Fourth World Systems
  Software Design and Development for the Desktop, Mobile, and the Web
  ____________________________________________________________________
  [hidden email]                http://www.FourthWorld.com

_______________________________________________
use-livecode mailing list
[hidden email]
Please visit this url to subscribe, unsubscribe and manage your subscription preferences:
http://lists.runrev.com/mailman/listinfo/use-livecode
Loading...