Git Product home page Git Product logo

Comments (12)

Arcanemagus avatar Arcanemagus commented on June 15, 2024

Assuming the clojure.jar file supports it with the same options and the same output format it should be as simple as adding that to the list of supported scopes. Have you tried that locally?

from linter-clojure.

damassi avatar damassi commented on June 15, 2024

@Arcanemagus - can you explain a little better what you mean? I'm very new to Clojure / ClojureScript development, though an experienced programmer

from linter-clojure.

Arcanemagus avatar Arcanemagus commented on June 15, 2024

In this block of code the command that gets executed is built up. First either java or the contents of javaExecutablePath is used as the command base. The the parameters get assembled. By default it looks like it runs something similar to this:

java -jar /path/to/closure-1.7.0.jar -i /path/to/file_currently_open.ext

So if you manually run a command like that on a ClojurScript file and get reasonable output, ClojustScript should work if it is added to the list of grammarScopes for this plugin.

Having said all that, now that I've checked while writing that up I see that it should already be working since source.clojurescript is in the list of allowed grammars, do you have an example file where it isn't working? What do you get when you run Editor: Log Cursor Scope (Ctrl + Shift + Alt + P) on a ClosureScript file?

from linter-clojure.

damassi avatar damassi commented on June 15, 2024

Thanks for working through this :)

When I run log cursor scope this is what's returned:

Scopes at Cursor
source.clojure
meta.expression.clojure
meta.definition.global.clojure
meta.expression.clojure
meta.expression.clojure
meta.expression.clojure
meta.expression.clojure

And here's an example of a basic linting error:

screen shot 2015-12-28 at 3 20 26 pm

And one more:
screen shot 2015-12-28 at 3 25 23 pm

from linter-clojure.

Arcanemagus avatar Arcanemagus commented on June 15, 2024

Looks like it's working properly already then 😛

Were you expecting something that it isn't doing, or had you just not tried it yet?

from linter-clojure.

damassi avatar damassi commented on June 15, 2024

Well what I mean about supporting ClojureScript is js->clj shouldn't be unresolved (its a common built in function in the global js namespace), and neither should defproject -- unless I am misunderstanding something?

from linter-clojure.

Arcanemagus avatar Arcanemagus commented on June 15, 2024

You'll have to ask somebody familiar with ClojureScript for that, @trevershick?

from linter-clojure.

Arcanemagus avatar Arcanemagus commented on June 15, 2024

Marking this as closed since linter-clojure is already running on ClojureScript files, feel free to continue the discussion though 😉.

from linter-clojure.

damassi avatar damassi commented on June 15, 2024

Sounds good. @trevershick, any help would be appreciated. I know there is a cljs.jar file that is used to compile ClojureScript; wondering if we could leverage that somehow within the library along with the typical clojure.jar that is used for linting.

from linter-clojure.

Arcanemagus avatar Arcanemagus commented on June 15, 2024

Just to be clear, I have no experience with Clojure beyond knowing it's a language. If there are actual implementation details that need changing to get proper support in by all means please reopen this issue.

from linter-clojure.

damassi avatar damassi commented on June 15, 2024

I'm assuming there is, but I honestly have no clue what they could be (total noob here). Whatever it is I imagine its trivial, though, as there are linters available for other editors.

from linter-clojure.

trevershick avatar trevershick commented on June 15, 2024

I'll take a look. I've been ill lately but i'll look after the new year.

from linter-clojure.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.