Cocoanetics / DTFoundation

Standard toolset classes and categories
BSD 2-Clause "Simplified" License
802 stars 237 forks source link

Add Subspecs for DTActionSheet and DTAlertView #36

Closed toco closed 11 years ago

toco commented 11 years ago

It would be really be nice if you could add subspecs to only use DTActionSheet or DTAlertView without other in my case unnecessary categories and classes.

  spec.subspec 'DTActionSheet' do |ss|
    ss.platform = :ios, '4.3'
    ss.ios.source_files = 'Core/Source/DTWeakSupport.h','Core/Source/iOS/DTActionSheet.{h,m}'
  end
  spec.subspec 'DTAlertView' do |ss|
        ss.platform = :ios, '4.3'
        ss.ios.source_files = 'Core/Source/DTWeakSupport.h','Core/Source/iOS/DTAlertView.{h,m}'
  end
odrobnik commented 11 years ago

I can see where you are coming from, but this would unnecessarily complicate our own work. For us there are almost no "unnecessary categories and classes". Most of them are used all the time in our projects.

The UIKit subspec has a very small set of additions to UIKit. All other larger classes, like DTSidePanel have been moved to their own subspecs.

So our approach is not to move every little thing into sub specs, but rather move the large or experimental things (which few people use) into their own sub-folders.

odrobnik commented 11 years ago

I moved all the UIKit Blocks Additions into their own sub spec with a dependency on Core. I also moved a few "unnecessary things" out of the Core spec which has the weak support.

odrobnik commented 11 years ago

this will be released as of 1.4.5