This repository has been archived by the owner. It is now read-only.

MacOS.cat symbols should be consistent with version methods #14270

Closed
jacknagel opened this Issue Aug 18, 2012 · 10 comments

Comments

Projects
None yet
3 participants
Contributor

jacknagel commented Aug 18, 2012

The symbols returned by MacOS.cat and used in the bottle DSL omit underscores between words, but we traditionally don't run words together, e.g. MacOS.snow_leopard? or MacOS.mountain_lion?

I tend to think we should always use underscores.

Contributor

adamv commented Aug 25, 2012

Yes.

Owner

MikeMcQuaid commented Aug 25, 2012

I started on this and gave up. It's going to be pretty irritating to do; all the current bottles' names rely on the symbols having no _ so we'll need to alter the DSL somehow to indicate the difference between them (or use the checksum value to calculate the URL).

Contributor

jacknagel commented Aug 25, 2012

Hmm. What about

def old_cat
  cat.to_s.gsub('_', '')
end

and use that for building the URL strings?

Owner

MikeMcQuaid commented Aug 25, 2012

Aye, that's doable. The problem is how and when we migrate over to the "new" URL strings which will require using new_cat in filenames for upload.

Contributor

jacknagel commented Aug 25, 2012

Yeah.

Maybe we just keep using old_cat in the URL strings and never migrate them?

Otherwise, meh and we can do it for brew2.

Owner

MikeMcQuaid commented Aug 25, 2012

That works for now. I think the nicer solution (if you can be bothered; I couldn't) is to still support :mountainlion as a a checksum and make that symbol used to create the URL. Then we can change every other instance to use the new code and get rid of the legacy code when all the bottles have been updated.

Contributor

jacknagel commented Aug 25, 2012

Ah, I see what you mean. Will take a look sometime.

Owner

MikeMcQuaid commented Aug 25, 2012

Cheers :)

Contributor

adamv commented Nov 25, 2012

Is this still a thing?

Owner

MikeMcQuaid commented Nov 25, 2012

Yes. Started playing with fixing it today, coincidentally.

Sharpie pushed a commit to Sharpie/homebrew that referenced this issue Feb 19, 2013

@xu-cheng xu-cheng locked and limited conversation to collaborators Feb 16, 2016

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.