beyondgrep / ack2

**ack 2 is no longer being maintained. ack 3 is the latest version.**
https://github.com/beyondgrep/ack3/
Other
1.48k stars 140 forks source link

Reorganization #261

Closed mmcclimon closed 11 years ago

mmcclimon commented 11 years ago

I was wondering what you think about reorganizing the working tree slightly. It's often difficult for me to remember what goes where (what's a Filter subclass, a Resource subclass, etc.). I've rearranged things here, moving into folder and moving a bunch of the stuff that probably shouldn't be in root into dev (perlcriticrc, etc.). Feel free to throw this away if this is a bad idea.

-mjm

hoelzro commented 11 years ago

I sympathize with wanting to reorganize the source, but if we were to do so, I think it might be a better idea to follow the Perl convention of throwing modules under lib/, like so:

lib/App/Ack.pm
lib/App/Ack/ConfigLoader.pm
lib/App/Ack/Resources.pm
lib/App/Ack/Filter.pm
lib/App/Ack/Filter/Match.pm
lib/App/Ack/Filter/Extension.pm
lib/App/Ack/Filter/FirstLineMatch.pm
lib/App/Ack/Filter/Default.pm
lib/App/Ack/Filter/Is.pm
lib/App/Ack/Filter/Inverse.pm
lib/App/Ack/Resource.pm
lib/App/Ack/Resource/Basic.pm
lib/App/Ack/ConfigFinder.pm
lib/App/Ack/ConfigDefault.pm
petdance commented 11 years ago

I kinda like the direction of the stuff @mmcclimon has proposed in his pull request. I very specifically do NOT want to do the "standard Perl way" of

lib/App/Ack.pm lib/App/Ack/ConfigLoader.pm lib/App/Ack/Resources.pm lib/App/Ack/Filter.pm lib/App/Ack/Filter/Match.pm lib/App/Ack/Filter/Extension.pm lib/App/Ack/Filter/FirstLineMatch.pm lib/App/Ack/Filter/Default.pm lib/App/Ack/Filter/Is.pm lib/App/Ack/Filter/Inverse.pm lib/App/Ack/Resource.pm lib/App/Ack/Resource/Basic.pm lib/App/Ack/ConfigFinder.pm lib/App/Ack/ConfigDefault.pm

because typing out all those paths, even with tab-completion, sucks my soul away.

petdance commented 11 years ago

Let's leave this topic alone for now, until we start thinking about API in a bit.