When I put more thant 10 million files within 400 folders. Sublime just cannot start. How many files can I put the most with16G RAM?
How many snippets file can I put into User folder?
I donāt have an answer to your question but I suspect youāre trying to use Sublime Text for something it isnāt designed for.
May I ask you why do you want to use 10 million snippet files? What are you trying to achive?
Just write some code snippets to save time.
500000 snippets can start but I want to know the upper bound.
There is no hard upper bound, just however much your hardware is able to support and how long youāre willing to wait/how much youāre willing to deal with an unresponsive UI.
Can I create many folders to save snippet to make sublime run more fast instead of put all in one folder?
But seriously, why do you need that many snippets ? Thatās excessive in the extreme.
Iām not quite sure of the question youāre asking because ealier you say
and then youāre talking about 256GB of RAM:
but Iāve just had a look at my snippets and they vary between 200 and 1000 bytes, so 0.2 to 1k. I donāt know how much space they take up in memory when theyāre loaded into Sublime, Iām guessing theyāll only be loaded as neccessary or perhaps thereās some caching method going on, theyāre scoped too, which will reduce overheads.
If youāre talking about a 256Gig hard drive, well the answer is 5x256 x10ā¹ snippets max or 256x10ā¹ min. Should keep you going for a while.
Even if all the snippets are loaded into memory and they take up 100 times more space in memory (as machine instructions) that still gives you 256x10ā· snippets. Obvs thereās got to be room for ST3 and all your other processes, but the english language only contains 50k words, your average computer language (pulling a number out of the air) 100, 200. I think C has about 20 keywords. MindF*ck has two. But I digress. Iām going to stick my neck out and say I think youāll be fine for the first 6 months of ST use, after six months see how things are looking ?
Ps Sorry it was Brainf**k
Thank for reply.(The problem is trigger words.If trigger words less than 7 more than 1 with printable character,then the number of possible snippets is huge)
If I put more than about 1 million snippets(fix length ,all the same) . Then I cannot normal start sublime. (If I put 200000 snippets I can see task manage show sublime take much memory and CPU when it started,and then down later.)
I want to know If I add RAM space like from 16GB to 64GB and upgrade my CPU allow me to put more snippets and start sublime normally.And how much more can load?
That, I have no idea about, Iām just a user (and a noob at that)
But having said that, is the goal (of your question) to get a specific answer to your question?:
Or is this line of questioning trying to work out the performance of this editor vs other editors; so that you can decide which one you should use ?
If it is the latter; how do the other editors perfom when you run the same tests? If they perform better or worse, thereās your answer as to which one you should use, if those are your circumstances/criteria you have to work with.
However if the reason for your question is the former, then everything Iāve just said is totally useless, and hopefully someone else can jump in a save me/us
Good luck L
Ps Just a final thought, I guess the folks at Sublime have designed it with some parameters in mind ie what is the upperbound for the amount of snippets the design team thought that someone might need. 200,000 snippets is a lot of snippetsā¦
ā¦Not require specific answerā¦just want to know how to use more snippets.
Actually I havenāt use that much snippets.I wrote a program generate that much snippet templates for testing.So I have this question.
Other editors use different methods to create snippets(sublime is easy enough for me),maybe test later haā¦
Can you explain a little bit better why it is you need to have 10 million code snippets? You say āto save timeā, but Iām having a hard time grasping how you could even remember 10 million different tab sequences to trigger the snippets in the first place. It seems like trying to narrow in on the correct one would take vastly more time than it would take to just enter the text you want in the first place.
Just want to know the if thee is an answer.There maybe someone need in some time.
https://packagecontrol.io/packages/Unity%20Completions has 209169 .sublime-snippets
files in itā¦
Maybe it is a filesystem I/O bottleneck? You should try to pack your snippets to zip-archive with .sublime-package extension, put it to the Installed Packages folder and look at any difference.
Also, if your snippets are just list of class/method names - you probably should try to generate completions (that can be in one file) instead of snippets.
Personally why I donāt use completions is (if Iāve understood correctly) Iāve got remember what I want in that file, and edit a long list where as with a snippet I can create one on the fly with a couple of keystrokes (now)ā¦
The main issue would be that in order to be a part of the completion system, the contents of the files has to be loaded into memory, and since thereās no artificially constrained upper bounds on the number memory is a finite resource, there is a finite number of them which can be defined before itās no longer sustainable.
Regarding the differences between snippets and completions, thatās summarized here:
Since both are meant to add items to the autocomplete panel to make common sequences or blocks of text easier to write, the idea that one would need so many of them that the limit is even something to worry about is a strong suggestion that someone is doing something wrong, all else being equal.