-
Notifications
You must be signed in to change notification settings - Fork 49
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
Is there a way to get syntax checker working outside of a package? #143
Comments
Definitely possible, the syntax checkers checked in to this repo currently only support swiftpm since that's such a common case, but neomake has a direct swiftc example that just parses the current file: |
Kinda related: #142 |
Thanks. But I'm confused. I don't understand how your module works with Syntastic or how I would integrate neomake with your module or what swiftpm does exactly (I know what a package manager is but I have no idea why it's involved in syntax checking). So what do I have to do, exactly, to get syntax checking on a standalone file working? |
Also, another point of confusion for me is that I've got swift syntax checking working on Ubuntu. But when I run
So I'm not sure how to get this working on my Mac. I thought the package manager would be installed with xcode, though. |
You have a typo, it's |
You have a few options:
|
doh! thanks. I should put my glasses on, I guess. :) |
Note that SwiftPM isn't actually only doing syntax checking, the way it is setup in this repo it actually does a build of your package, and reports the compiler errors back |
OK, I think this is starting to make more sense now. Thank you. |
I took a stab at trying to create a new syntax checker (though my vimscript skills are about on par with my swift skills) called
It doesn't work, though. |
OK, I did a little bit more noodling and got something working:
Are you interested in having me create a patch for this? I'm sure what I have needs to be fixed up and better integrated with your plugin, though. |
Yep looks good! If you put it in that directory named |
I'm new to swift so I'm not familiar with how things are supposed to work. Is there a way to get syntax errors to show up when editing a standalone file?
Similarly, if I edit a file that's part of an xcode project, is there a way to get syntax errors to display?
So far, I've only gotten this to work after init'ing a package and then editing Source/package/main.swift
The text was updated successfully, but these errors were encountered: