dmytrodanylyk / folding-plugin

Android File Grouping Plugin
http://www.dmytrodanylyk.com/pages/blog/android-file-grouping.html
MIT License
1.53k stars 145 forks source link

File grouping config #1

Closed Rainer-Lang closed 9 years ago

Rainer-Lang commented 9 years ago

"Naming rules: folder name -> file name part till underscore"

I often have such names: "abc_defgh_ijklmn_fragment.xml" Therefore I'd like to have folders for "abc_defgh". Please let the user decide which position of the underscore is taken for filtering.

dmytrodanylyk commented 9 years ago

@Rainer-Lang good point

dmytrodanylyk commented 9 years ago

I can make a config file, where users will be able to define custom rules for folding. Question is where to put this file?

Rainer-Lang commented 9 years ago

Have other plugins also config-files?

dmytrodanylyk commented 9 years ago

I don't think so. Mostly have their own internal settings. But this is a lot of work :)

Maybe we can do the following, user right click on folder, click add custom group rule, and type for example abc_defgh. ?

Rainer-Lang commented 9 years ago

"abcdefgh" was only an example to show that I need to define the position of "". :) But maybe you are more flexible with your suggestion... Would this be saved?

dmytrodanylyk commented 9 years ago

Yes, again: user right click on folder -> click add custom group rule -> pop dialog with input field -> user type custom rule for example "abc_defgh" and it will be saved.

I will think more on other solutions..

Rainer-Lang commented 9 years ago

But this sounds pretty nice. :-)

Rainer-Lang commented 9 years ago

@dmytrodanylyk Any news? Maybe something to discuss here?

dmytrodanylyk commented 9 years ago

@Rainer-Lang not yet, I just got married :) I will try to do this on weekends.

Rainer-Lang commented 9 years ago

Wow :-) Nice! Have a time! ;-)

Rainer-Lang commented 9 years ago

@dmytrodanylyk Any news? :-)

dmytrodanylyk commented 9 years ago

@Rainer-Lang Hi, I am thinking if we need this at all.

I considered following:

  1. Making possibility to config folding require additional steps from developer.
  2. It will persist on your local machine, when you re-download project all settings will be gone.
  3. Developers which work on project with you would have to config folding them self.
  4. It doesn't work on Android Project view.

And concluded that using multi-res folders is better way to manage this job.

I am using following structure:

sourceSets {
    main {
        res.srcDirs = [
                'src/main/res',
                'src/main/layouts/chat',
                'src/main/layouts/chatlist',
                'src/main/layouts/gallery',
                'src/main/layouts/profile',
                'src/main/layouts/contacts'
        ]
    }
}

What do you think?

Rainer-Lang commented 9 years ago

For me it would be fine. I don't care about some extra "work" to configure. I save more time with that plugin. :-)

dmytrodanylyk commented 9 years ago

@Rainer-Lang why you are not using multi-res folders?

Rainer-Lang commented 9 years ago

Tried but doesn't work.

dmytrodanylyk commented 9 years ago

@Rainer-Lang I can help you, ping me in Hangout if you want.