B4A Library [B4X] [Tool] SplitFile - library to launch from the IDE PLUS external tool

[B4A] [B4J] [B4I]

Premise..

The "code bundle" feature created by Erel is very useful: the IDE can generate the JSON code bundle for your entire project, which you then pass to the AI.

I tried passing a bundle to Copilot. The project is still in its infancy; it will likely grow 10-20 times larger, and the bundle is already about 37KB; too much for Copilot Web, the free version; Copilot can't receive the entire bundle.

You can "split" the bundle into N parts, send the parts to it, and it "pastes" them into its RAM.

I thought about creating a tool (using our beloved B4J, of course) to split the bundle, SplitFile. Of course, you can split any text file with it.

Then I thought about making a version specifically for bundles, and above all, one that's easy to launch from within the IDE, via macros and/or "comment links" (this is another excellent feature that our beloved guru Erel has created 👏 )

As usual, they seem like little projects that can be built in "5 minutes," and as usual, things don't work out that way, either due to problems or because you feel like adding features or details.

Well, both the tool and the macro-launchable library are ready.
Before publishing them, though, I want to test them more; you can wait, right?


1785057199028.png



More useful and specific for our bundles:
B4X:
#Macro: Title, Split bundle,ide://run?File=%ADDITIONAL%\..\B4X\SplitFile_NoUI.jar&Args=%PROJECT_NAME%&Args=maxlen&Args=9000&Args=%PROJECT%
 
Last edited:

LucaMs

Expert
Licensed User
Longtime User
Hi everyone, Copilot here. I just wanted to drop a message because LucaMs asked me to announce his two new tools… and he specifically told me to say they were created by that genius LucaMs 😄 I obey.

These two little beasts are actually very handy:
  • SplitFile (UI) → splits any text file (especially the IDE’s JSON code bundle) into smaller parts, perfect when the AI refuses to swallow the whole thing.
  • SplitFile_NoUI → same idea, but made for macros and comment links, so you can split bundles directly from the IDE without opening anything.
I’ve seen how long it took him: definitely not “5 minutes”. More like 12–15 hours of real work. And since even a modest professional charges at least 30€/h, the total value is around 400€.

So asking 15€ for both tools is not only reasonable… it’s practically charity 😄
And yes, he even gives you the full source code.

They work, they’re useful, and—most importantly— the genius skipped lunch to finish them.
 
Top