Closed tsdh closed 12 years ago
On Mon, Mar 26, 2012 at 6:47 PM, Tassilo Horn reply@reply.github.com wrote:
It would be awesome, if kibit could support the programmer with cleaning up
(ns ...)
declarations. By that I mean the following:
- Suggest removing unused but
:import
-ed classes.- Suggest removing unused but
:require
-ed or:use
-d namespaces.- Suggest removing unused vars in the
:only
clause of:use
.- If a namespace is required with alias (e.g.,
(:require [foo.bar.baz :as fbb])
), suggest replacing fully qualified var accesses likefoo.bar.baz/some-var
withfbb/some-var
.- If a class is imported, suggest replacing fully qualified accesses with non-qualified ones.
Is that doable with kibit?
I guess everything is doable but it's not the current focus which is to simplify expressions. I think that this kind of analysis is better achieved with something like analyze[1] by @frenchy64. I've done some experimental work with it here[2].
[1] https://github.com/frenchy64/analyze [2] https://github.com/jonase/eastwood
Jonas
Reply to this email directly or view it on GitHub: https://github.com/jonase/kibit/issues/25
It also seems like slamhound[1] is applicable.
Thanks for the suggestions. It seems, slamhound is exactly what I've been looking for.
It would be awesome, if kibit could support the programmer with cleaning up
(ns ...)
declarations. By that I mean the following::import
-ed classes.:require
-ed or:use
-d namespaces.:only
clause of:use
.(:require [foo.bar.baz :as fbb])
), suggest replacing fully qualified var accesses likefoo.bar.baz/some-var
withfbb/some-var
.Is that doable with kibit?