-
Notifications
You must be signed in to change notification settings - Fork 20
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
ST3 support? #4
Comments
It's completely compatible with ST3, I don't know why it's marked ST2-only. You'll have to manually clone the repo into your |
I think you need to follow the instructions here: https://sublime.wbond.net/docs/developers and change the lines https://github.com/wbond/package_control_channel/blob/master/repository/d.json#L138-L147 to read: {
"name": "Default File Type",
"details": "https://github.com/spadgos/sublime-DefaultFileType",
"releases": [
{
"sublime_text": "*",
"details": "https://github.com/spadgos/sublime-DefaultFileType/tree/master"
}
]
}, That should make it show up in Package Control as working with ST2 and ST3. |
I've done this for you: wbond/package_control_channel#2421 |
Merged. |
Not being a Sublime Text or OSX pro yet, I was unsure exactly what was meant by "Sublime base directory". I guessed this was /Users/username/Library/Application Support/Sublime Text 3, but the structure seems to be different than it was in ST2. I don't have language folders under the Packages folder, nor do I seem to have a file called "Java.tmLanguage" like the example anywhere on my system.'' Do the docs need to be updated for ST3 or am I missing something? Thanks! |
ST3 stores the standard packages in the application folder (where it is installed). See http://www.sublimetext.com/docs/3/packages.html |
Thank you @FichteFoll, that's very helpful! |
For ST 3 I can't seem to find the default language definitions there (/Applications/Sublime Text 3.app/Contents/MacOS/Packages) or in the (/Users/kai/Library/Application Support/Sublime Text 3/Packages) Are they compressed in the Markdown.sublime-package file? Would I need to extract this, leave extracted, and point at it? Or am I missing something here? Thanks, Kai |
Yes, packages are stored in zip archives which have the |
Hi @kaimantsch, do you mean you looked in Anyway, my That said, I'm actually not sure if I have the DefaultFileType plugin working. My |
Oh on second reading, you're looking to reference Markdown? For some reason I thought you were saying all you had was a Markdown file. |
Yes, I was hoping to have Markdown be the default but I can't find the .tmLanguage file for it anywhere. (I renamed my app in the /Applications dir. No problems there.) |
If you were to duplicate the "Markdown.sublime-package" file, rename it "Markdown.zip" and extract it, you should find "Markdown/Markdown.tmLanguage". You don't need to actually extract the ZIP, though, but it's how you can be sure of the file name/path. So to set Markdown as the default file type, I think you would create ~/Library/Application Support/Sublime Text 3/Packages/User/default_file_type.sublime-settings:
Also note from the docs of this plugin:
Does that help? |
I have only been using the cmd-N to open/test the feature. I tried a number of paths: Packages/Markdown/MultiMarkdown.tmLanguage I then extracted the MultiMarkdown.tmLanguage from the zip file and just dumped it in the App Packages directory and used the full path: Error loading syntax file "/Applications/Sublime Text 3.app/Contents/MacOS/Packages/MultiMarkdown.tmLanguage I moved it several more places, including ~/MultiMarkdown.tmLanguage Complaint is the same about not being able to open: Error loading syntax file "~/MultiMarkdown.tmLanguage": Unable to open ~/MultiMarkdown.tmLanguage Other ideas? Is this working for you? |
Correction: I somehow forced a reload that suddenly caused it to work. I went back and even tried Packages/Markdown/MultiMarkdown.tmLangugage and suddenly that works too. I forgot the cardinal rule: "have you tried unplugging it and plugging it back in?" No idea what they worked but seems to be fine now. Thanks for all the help debugging! |
I haven't tried extracting it or moving it anywhere, but just with the default ST3 install and then with DefaultFileType package installed, I get it to work just fine by having this as my default_file_type.sublime-settings file:
Is the |
Hah OK, glad it works. For me, the changes to the settings file seem to take immediately. I can change to another language, save, and then do Cmd+N and it opens a new tab as the new file type immediately. |
The crazy thing is that clear that was happening, at least in part. I would hit cmd-n and it would complain that it couldn't open the file named just as I had typed in the lastest change. So clearly it had read the new file name each time and updated. But somehow... something changed? Suddenly all the same combinations I tried before worked. I went back and tried them all. Anyway, clearly a Sublime text issue and not with your plugin. Hopefully all of this working back and forth will be useful to someone! When in doubt... reboot. |
I've got the exact same issue as kaimantsch except that a reboot didn't fix it, neither did a reinstall of the package. If I look under I've tried;
and when I create a new document, it has the white background (as per the language settings) and the correct option is selected in I've also tried tried HTML and XML to test and I get the same symptoms. |
Did you actually extract the .tmlanguage file to Packages/User/ and then reference it there? That worked for me with Markdown Extended. |
Any chance of making your plug-in compatible with ST3?
The text was updated successfully, but these errors were encountered: