Lighthouse has a new layout. Prefer the old one? Return to the old layout, and switch back any time from the link at the top of each page.

handle directories as cmdline args

#26

From Ashley Moran, via email:

"Any chance you could make it take directories?"

Reported by Kevin Rutherford · March 8th, 2009 @ 02:17 PM

State: resolved
Milestone: none
Assigned to: Kevin Rutherford Kevin Rutherford

Activity

  1. Kevin Rutherford
    Kevin Rutherford

    In fact this is what Reek 0.2 used to do and I took it out. Let's do some design. If a commandline argument is a directory Reek should look at:

    • all files called DIR/*.rb ?
    • all files called DIR/*/.rb ?

    So should this be a config-file option? What about a list of files to be excluded (eg. *_spec.rb)?

    Currently Reek::RakeTask has an option to specify the set of files, and globs are permitted. So in a way this is already supported. Plus, most operating systems provide a way to find loads of files and pass them to the commandline, eg:

    
    $ reek `find DIR -name \*.rb -print`
    

    March 8th, 2009 @ 02:25 PM

  2. Kevin Rutherford
    Kevin Rutherford
    • State changed from new to resolved

    Closed, because there are already a couple of viable alternatives.

    March 8th, 2009 @ 02:26 PM

  3. Kevin Rutherford
    Kevin Rutherford
    
    "app/models".should_not reek
    

    is very sexy. Is

    
    "app/models/**/*.rb".should_not reek
    

    any less so?

    March 8th, 2009 @ 04:11 PM

  4. Kevin Rutherford
    Kevin Rutherford

    Yes, I'll add some more factory methods to Source. In a few days...

    March 24th, 2009 @ 04:07 PM

Please Sign in or create a free account to add a new ticket.

With your very own profile, you can contribute to projects, track your activity, watch tickets, receive and update tickets through your email and much more.