Extend the Version function

Something you want to see in a LiveCode product? Want a new forum set up for a specific topic? Talk about it here.

Moderator: Klaus

Post Reply
edgore
VIP Livecode Opensource Backer
VIP Livecode Opensource Backer
Posts: 197
Joined: Wed Jun 14, 2006 8:40 pm

Extend the Version function

Post by edgore » Fri Aug 02, 2013 1:20 am

It would be great if the version function returned more than just a number. It would be nice if it told you if it was desktop or server, for example, so that I could code in conditionals when developing on the desktop. Then when I copy and paste to server I don't need to comment stuff in and out by hand each time.

wsamples
VIP Livecode Opensource Backer
VIP Livecode Opensource Backer
Posts: 264
Joined: Mon May 18, 2009 4:12 am

Re: Extend the Version function

Post by wsamples » Fri Aug 02, 2013 2:32 am

Try 'the environment'. Should return server, example <?lc put the environment ?> resturns "server"

edgore
VIP Livecode Opensource Backer
VIP Livecode Opensource Backer
Posts: 197
Joined: Wed Jun 14, 2006 8:40 pm

Re: Extend the Version function

Post by edgore » Fri Aug 02, 2013 2:52 am

Ah - exactly what I was looking for.

I guess I will change the feature request to "Update the documentation for environment to indicate that "server" is a possible result.
Last edited by edgore on Fri Aug 02, 2013 3:11 pm, edited 1 time in total.

richmond62
Livecode Opensource Backer
Livecode Opensource Backer
Posts: 10081
Joined: Fri Feb 19, 2010 10:17 am

Re: Extend the Version function

Post by richmond62 » Fri Aug 02, 2013 7:53 am

That's a can of worms:

Think about all the different versions of Linux.

edgore
VIP Livecode Opensource Backer
VIP Livecode Opensource Backer
Posts: 197
Joined: Wed Jun 14, 2006 8:40 pm

Re: Extend the Version function

Post by edgore » Fri Aug 02, 2013 3:07 pm

@richmond62

I haven't fooled around with systemVersion enough to know whether it would give you anything useful back in those situations or not, but that might take care of it, along with environment.

My main interest was just being able to put conditionals into my code so I don't have to comment stuff in/out during development and deployment between desktop and server, so environment will work for me.

Post Reply