A quick question if you don't mind. I want a custom build system for a specific file. (It is a text file and the build system runs a Python script to parse some information from it.) Having the filename in file_patterns works, the caveat is that it matches any file with the filename. I tried putting an absolute path in file_patterns but it didn't seem to work. What's a good approach for this kind of use case? Thank you for the excellent tutorials!
@OdatNurdАй бұрын
One way to pull this off would be to have a custom binding on the build key that forces it to use a specific build regardless of the currently selected build, in combination with a plugin that allows the key binding to only be active when a specific filename is the currently active file. An example of that can be found in this gist: gist.github.com/OdatNurd/009565250165d2244705c311d1c9551d This requires that the custom file be focused at the time you press the key. If you just want the build to trigger as long as SOME file in the folder matches even if it's not the current one, the same thing would work but the plugin would need to scan the folder the current file is in for a file that matches instead, which is a slightly different thing.
@dwayne64023 жыл бұрын
is there a resource for someone new to Sublime Text to go from beginner to intermediate to advanced user. I am an intermediate user but I don't have a good grasp of all the basics and I keep struggling with using Sublime Text. I am a front end programmer (beginner, learner) and I use Sublime Text 4 for those purposes ie HTML, CSS, Javascript, Typescript, React, Git etc
@OdatNurd3 жыл бұрын
The first thing that comes to mind is the Community documentation (which used to be called the Unofficial Documentation), which documents more than the official documentation does, though that is currently starting to catch up somewhat. You can find it at docs.sublimetext.io/
@peterSobieraj2 жыл бұрын
keyfiles doesn't work for me. I added "cmd" and "keyfiles". I opened test.txt that is in same folder as Makefile, but when I try to build sublime said "No build system". My build file looks like this: {"cmd": ["make"],"keyfiles":["Makefile","makefile"]}
@OdatNurd2 жыл бұрын
Have you verified that the JSON you're using is valid (i.e. see if it passes JSON Lint) and that it's in a file with the sublime-build extension?
@peterSobieraj2 жыл бұрын
@@OdatNurd Yes. I just verified using some online tool and it's correct. If I compile while makefile is selected it works (but I think that's build in building system for makefiles). If I specyficaly select my build system, then it works. But if it's automatic and I have test.txt selected then I got "No Build System".
@OdatNurd2 жыл бұрын
@@peterSobieraj Do you see any errors in the Sublime console at all?
@peterSobieraj2 жыл бұрын
@@OdatNurd No. Nothing. Also my system works if I manualy select it.
@ivanlegranbizarro81023 жыл бұрын
Dear OdatNurd, Terminus was removed from Package Control ... Do you know anything about it? I can't reinstall it: '(
@OdatNurd3 жыл бұрын
Yesterday GitHub removed access for some methods of Access control in favor of some new ones, and package control is having a bit of a problem finding packages as a result. It's being worked on though
@ivanlegranbizarro81023 жыл бұрын
@@OdatNurd Thank you very much for your answer!
@КостяЕвколиди2 жыл бұрын
Can you please help me? I am coding in c++ and i want to make 2 different keybinding, one for compile + run and second one just for run (if its already compiled and doesn't need to be compiled again), but i haven't found how to do that. The only thing i found is that i can make 2 different buildings and manually select what i want to use (for example with hotkey ctrl + shift + B), but it takes a lot of time to always select build option that i need UPD: I'm sorry, i spent some time before writting this comment, and excatly when i wrote it i found how to do this. Anyway thank you!
@OdatNurd2 жыл бұрын
Awesome, glad you got it working the way you wanted to!