BBEdit

Want to talk about something that isn't covered by another category?

Moderators: FourthWorld, heatherlaine, Klaus, kevinmiller, robinmiller

Post Reply
anmldr
Posts: 459
Joined: Tue Sep 11, 2012 11:13 pm

BBEdit

Post by anmldr » Wed Jun 24, 2020 1:16 am

I have read several times here on the boards that some people are using BBEdit instead of the LC Script Editor.

Please tell me the advantages and/or how you are using it?

Am I missing something? Is there a LC language module? As recommended here, I downloaded the trial version. I had not upgraded since BBEdit 2.0 because I had not used it in several years (never with LC).

Give me some hints on how it helps you with LC. Someone mentioned recently in one of my posts about it's ability to search/replace in multiple files. That one thing makes it highly useful to me but that is not exactly LC related. But it does mean that I will probably purchase it rather than just using the free version.

TIA,
Linda

Mikey
VIP Livecode Opensource Backer
VIP Livecode Opensource Backer
Posts: 755
Joined: Fri Jun 27, 2008 9:00 pm

Re: BBEdit

Post by Mikey » Wed Jun 24, 2020 2:36 pm

OR you could use either Atom or SublimeText. There are LC language pieces for both.
If you are only using binary stacks (all your scripts are contained in the stack file, and are not separated into behavior stacks), then you would not be using an external text editor.
There are lots of advantages of external editors, the biggest being...they are designed to do text editing, and thus have many enhancements that LC's script editor does not have (code folding, speed, theming, plugins, etc.)

anmldr
Posts: 459
Joined: Tue Sep 11, 2012 11:13 pm

Re: BBEdit

Post by anmldr » Wed Jun 24, 2020 5:13 pm

Mikey wrote:
Wed Jun 24, 2020 2:36 pm
If you are only using binary stacks (all your scripts are contained in the stack file, and are not separated into behavior stacks), then you would not be using an external text editor.
I understand now. Thank you,
Linda

bogs
Posts: 5435
Joined: Sat Feb 25, 2017 10:45 pm

Re: BBEdit

Post by bogs » Wed Jun 24, 2020 5:51 pm

Mikey wrote:
Wed Jun 24, 2020 2:36 pm
There are lots of advantages of external editors,
Keep in mind though that there are somethings you will have to do manually that the SE would do for you, such as 90% of the debugging features like keeping track of variables, break points, etc.

This isn't very hard to do, but if your used to just clicking a breakpoint in, or glancing along the bottom for variable states, it is something you'd have to do yourself.
Image

jacque
VIP Livecode Opensource Backer
VIP Livecode Opensource Backer
Posts: 7210
Joined: Sat Apr 08, 2006 8:31 pm
Location: Minneapolis MN
Contact:

Re: BBEdit

Post by jacque » Wed Jun 24, 2020 8:08 pm

BBEdit does have a LiveCode plugin if you want to script with it. I sometimes look at script-only stacks that way. But mostly I use BBEdit as an enhancement for LC:

1. My projects often use text files extensively. There are many times where I need to edit or even just view those files and I can keep them open in BBEdit while writing scripts to parse them. BBEdit's extensive "find" capabilities make it easy to locate any particular section of the text and I often use grep to get fuzzy search results. It also provides a scratchpad for temporary text or reminders to myself.

2. I use it to check any regex I use in scripts (I'm pretty bad at regex) and if it works in BBEdit, it will work in your script.

3. I use it to bulk-search all my client folders when I know I wrote a handler I can re-use but I don't remember which project it was in, or which version of a stack. BBEdit can search binary files.

4. I use it to compare two versions of the same script across different iterations of a stack (like git does.) You can add or remove differences by clicking arrow buttons and end up with a revised, up-to-date script.

5. BBEdit will open binary stacks as text files, and in between the binary garble are all your scripts in plain text. I do this when I want to find an earlier version of a handler and I don't want to mess around with the hassle LC gives you if you try to open two stacks with the same name.

6. I use it to quickly mark up htmlText that I need for field content. You can view the resulting text in its built-in browser which appears as you type.

Those are off the top of my head; there are probably others. BBEdit is one of the apps I auto-open when the Mac starts up.
Jacqueline Landman Gay | jacque at hyperactivesw dot com
HyperActive Software | http://www.hyperactivesw.com

kdjanz
Posts: 300
Joined: Fri Dec 09, 2011 12:12 pm
Location: Fort Saskatchewan, AB Canada

Re: BBEdit

Post by kdjanz » Wed Jun 24, 2020 9:15 pm

Jacque - could you please tell me where to go to get a LiveCode plugin for Bbedit? I would love to have script colouring working in it.

Thanks in advance,

kelly

jacque
VIP Livecode Opensource Backer
VIP Livecode Opensource Backer
Posts: 7210
Joined: Sat Apr 08, 2006 8:31 pm
Location: Minneapolis MN
Contact:

Re: BBEdit

Post by jacque » Thu Jun 25, 2020 11:28 pm

kdjanz wrote:
Wed Jun 24, 2020 9:15 pm
Jacque - could you please tell me where to go to get a LiveCode plugin for Bbedit? I would love to have script colouring working in it.
Thierry did a modificatioin last year but hasn't released it as far as I know.
viewtopic.php?t=32121

The one I'm using is from 5 years ago. I'm not sure if the links here are still working but this is where I got it:
http://runtime-revolution.278305.n4.nab ... l#a4696217
Jacqueline Landman Gay | jacque at hyperactivesw dot com
HyperActive Software | http://www.hyperactivesw.com

kdjanz
Posts: 300
Joined: Fri Dec 09, 2011 12:12 pm
Location: Fort Saskatchewan, AB Canada

Re: BBEdit

Post by kdjanz » Fri Jun 26, 2020 12:25 am

Nope . The old dropbox links for James Hale and Kay C Lan are no longer working. Could I get a copy of your plist file then?

Yes Thierry is taking his time.

kelly

Thierry
VIP Livecode Opensource Backer
VIP Livecode Opensource Backer
Posts: 875
Joined: Wed Nov 22, 2006 3:42 pm

Re: BBEdit

Post by Thierry » Fri Jun 26, 2020 9:36 am

kdjanz wrote: Nope . The old dropbox links for James Hale and Kay C Lan are no longer working.
Could I get a copy of your plist file then?
Here is one from my backups.
Disclaimer: I'm not using it,and don't know if it's the last version

LivecodeJames.plist.zip
(6.66 KiB) Downloaded 223 times

HTH,


Yes Thierry is taking his time.
less noise, please; I'm still sleeping... :wink:

Unfortunately there are quite a number of valid reasons
for not to share these BBEdit tools right now,
and none of these reasons are technical.

Regards,

Thierry
!
SUNNY-TDZ.COM doesn't belong to me since 2021.
To contact me, use the Private messages. Merci.
!

kdjanz
Posts: 300
Joined: Fri Dec 09, 2011 12:12 pm
Location: Fort Saskatchewan, AB Canada

Re: BBEdit

Post by kdjanz » Sat Jun 27, 2020 2:17 am

Thanks for that. I'll see how it works.

kelly

kaveh1000
Livecode Opensource Backer
Livecode Opensource Backer
Posts: 508
Joined: Sun Dec 18, 2011 7:23 pm
Location: London
Contact:

Re: BBEdit

Post by kaveh1000 » Sun Jan 29, 2023 7:24 pm

Hi all

Bit late to the party but I have successfully added the BBEdit .plist file so scripts are colored correctly in BBEdit.

I am using script only stacks, so ideal for this use. Here is the problem. I have a main stack that has already loaded the script-only stacks. When I edit externally and save, they are already in memory in LiveCode, so the scripts are not updated. obviously I don't want to keep quitting LiveCode.

I have tried opening the external stacks every time I run a script, but of course they are already open so the code is not reloaded. What is the best procedure, to close and to open them again every time?
Kaveh

stam
Posts: 2599
Joined: Sun Jun 04, 2006 9:39 pm
Location: London, UK

Re: BBEdit

Post by stam » Mon Jan 30, 2023 4:06 pm

Mikey wrote:
Wed Jun 24, 2020 2:36 pm
OR you could use either Atom or SublimeText. There are LC language pieces for both.
Atom is being sunsetted and replaced by VSCode (see here) - which actually works quite well and actually I do like VSCode a lot. Just download VSCode for your platform and search adding for LiveCode - FerrusLogic have released a plugin that requires the server executable for code colouring and syntax error highlighting.

The problem is that there isn't a 2-way communication between LC and external editors so that when you save in an external editor you have to manually reload the same text file in LC (I believe the exception to this is Sublime - Mac only and paid/expensive text editor for which there is a plugin that will reload the file in LC if you're developing with the rather complex Levure framework - but I'm afraid I'm too cheap to pay the $100 for Sublime, when all other code editors are freeeeeee).

S.

jacque
VIP Livecode Opensource Backer
VIP Livecode Opensource Backer
Posts: 7210
Joined: Sat Apr 08, 2006 8:31 pm
Location: Minneapolis MN
Contact:

Re: BBEdit

Post by jacque » Mon Jan 30, 2023 7:01 pm

When I want to update an open stack I use the revert command. Since script only stacks aren't on disk per se it might not work but it's worth a try.
Jacqueline Landman Gay | jacque at hyperactivesw dot com
HyperActive Software | http://www.hyperactivesw.com

kaveh1000
Livecode Opensource Backer
Livecode Opensource Backer
Posts: 508
Joined: Sun Dec 18, 2011 7:23 pm
Location: London
Contact:

Re: BBEdit

Post by kaveh1000 » Mon Jan 30, 2023 11:05 pm

Thanks Jacqueline. Good idea to revert, but wish there was a more elegant way.
Kaveh

Post Reply

Return to “Off-Topic”