Skip to content
This repository has been archived by the owner on Jul 4, 2023. It is now read-only.

hugo 0.14 #39815

Closed
wants to merge 1 commit into from
Closed

hugo 0.14 #39815

wants to merge 1 commit into from

Conversation

dunn
Copy link
Contributor

@dunn dunn commented May 16, 2015

The new dependencies are only needed for HEAD currently but they'll also be needed in the next stable release.

@DomT4
Copy link
Member

DomT4 commented May 23, 2015

I presume the new dependencies don't upset stable at all?

@dunn
Copy link
Contributor Author

dunn commented May 23, 2015

Stable still builds and runs fine for me. I think the extra deps are just ignored.

@DomT4
Copy link
Member

DomT4 commented May 25, 2015

@BrewTestBot test this please

@dunn
Copy link
Contributor Author

dunn commented May 25, 2015

0.14 just came out—let me just add that to this PR.

@dunn dunn changed the title hugo: add bash completion, new dependencies hugo 0.14 May 25, 2015
system "go", "build", "-o", bin/"hugo", "main.go"

bash_completion.mkpath
system bin/"hugo", "genautocomplete", "--completionfile=#{bash_completion}/hugo.sh"
Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Should this be in postinstall?

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Unless it's the same for every system/install location: yes.

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

For me at least, when it's in post_install Homebrew doesn't automatically link the completion script into /usr/local/etc/bash_completion.d. I have to brew unlink hugo && brew link hugo. Is that expected?

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The user can install the completion script anywhere, but I figure if they're installing hugo with Homebrew it ought to be placed in bash_completion.

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@dunn You probably want to use the bash_completion.install and generate it into the buildpath instead. Can you check if the script contains any hardcoded references to the full path? Thanks!

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Not seeing any, no!

dunn referenced this pull request May 26, 2015
closes #37083

Closes #37510.

Signed-off-by: Misty De Meo <[email protected]>
@MikeMcQuaid
Copy link
Member

Cool. Should be good to go!

@DomT4
Copy link
Member

DomT4 commented May 26, 2015

🚢'd in b85f1e4. Thanks again @dunn!

@DomT4 DomT4 closed this in b85f1e4 May 26, 2015
@dunn dunn deleted the hugo branch May 26, 2015 18:31
@dylancarlson
Copy link

Just FYI. This version of hugo breaks some stuff (path names in my case). I'm not sure why upstream is making such breaking changes (also making slight variable name changes such as .BaseUrl -> .BaseURL ...) but that was a little vexing.

I had to revert to 0.13 since I don't intend to touch my content to work around this.

As an aside, I can't fathom why 'versions' was removed from brew.

@MikeMcQuaid
Copy link
Member

@dylancarlson Can you provide a reproducible test case demonstrating the breakage (and we may roll back)?

As an aside, I can't fathom why 'versions' was removed from brew.

It didn't work well and created more problems than it solved. homebrew/versions is the better solution.

@dylancarlson
Copy link

It is covered here. gohugoio/hugo#1176

We will have to agree to disagree about homebrew/versions :) Maybe I can't see the rationale behind stuffing versions into a separate repo when they are already in the master repo. It's just adding developer overhead and user confusion. 'versions' made sense, IMO

@MikeMcQuaid
Copy link
Member

They are already in the master repository but we are unable to fix bugs, security issues and outright errors because they are immutable once they are in the history.

Maybe we could just apply https://github.com/spf13/hugo/commit/be7404.patch as a patch? If so, could you try and open a pull request? This should help and I'm happy to walk you through anything else: https://github.com/Homebrew/homebrew/blob/master/share/doc/homebrew/How-To-Open-a-Homebrew-Pull-Request-(and-get-it-merged).md#how-to-open-a-homebrew-pull-request-and-get-it-merged

Thanks!

@dylancarlson
Copy link

I'll follow up a bit later and open a new issue in that case since we are getting off-track in this one. I didn't want to clean up .Url -> .URL, .BaseUrl -> .BaseURL (et al) either since I have to do it for themes on multiple sites.

Re: master repo, I still disagree. 'versions' was just a convenience feature. I think it would have been better to modify 'versions' with a warning to people using it. Now we're just forcing people to git log, so the only thing being done is making it harder on people who need to revert to an older version in history. Most packages, hugo included, aren't in homebrew-versions and most probably won't be, due to the extra step and effort in maintaining them.

There are many varied reasons why users may need to checkout an older commit, and packagers can't account for all those reasons. Having old versions in a separate repo is just bloating the workload in all directions IMO. I used to do a ton of packaging in FreeBSD and Gentoo Linux years ago, I am familiar with what can happen. Maybe this is a philosophical complaint or something. It's trivial to make 'versions' a separate tool, but I'll always see this as an intrinsic feature of the packaging tool.

@MikeMcQuaid
Copy link
Member

Having old versions in a separate repo is just bloating the workload in all directions IMO.

The workload for Homebrew maintainers is significantly lower now.

I think it would have been better to modify 'versions' with a warning to people using it.

We did. It was ignored.

Now we're just forcing people to git log, so the only thing being done is making it harder on people who need to revert to an older version in history.

I don't think using git log is particularly hard, personally. If anything it's a suitable barrier to entry for people to think about what they are doing rather than running commands blindly and breaking things (which happened relatively often).

I'll follow up a bit later and open a new issue in that case since we are getting off-track in this one.

Thanks. Ideally a PR rather than an issue.

@dylancarlson
Copy link

As I say, it might be philosophical. :) If it were me, I wouldn't remove features for the sake of keeping a minority of people from shooting themselves in the feet. Screwing up is part of learning also. I'm not sure homebrew's audience is everyone, as the App Store is for everyone. Doing installs from a terminal implies a certain level of technical competence.

@MikeMcQuaid
Copy link
Member

Oh, we don't so much mind people shooting themselves into the foot but we do mind making our own jobs much harder when debugging unrelated issues (which it often did).

@dylancarlson
Copy link

Fair enough, thanks for the discussion & for working on homebrew. I have no idea what kind of workload you have. brew log package with a simple wrapper is easy for me to hack up.

I would imagine brew pin imposes similar workload complications, albeit from a different angle.

Just a thought, if I was in that position, what I might add a 'support' argument to brew for people to attach on new issues, which is file containing a json representation complete with brew info on each package. Feed that to a tool which computes the delta of their local state against master. That would help quickly flag users not conforming to a supportable environment.

@DomT4
Copy link
Member

DomT4 commented Jun 2, 2015

Most packages, hugo included, aren't in homebrew-versions and most probably won't be, due to the extra step and effort in maintaining them.

Just as a heads-up, If there's a valid use case it's perfectly welcome in Versions. There's stuff in Versions that hasn't been touched in 2+ years and still works on all three "modern" Homebrew-supported OS X versions without patching/etc. It's less prone to breakage than the alternative options.

Submitting a formula to Versions that was in the core is as simple as pulling formula from the git history, removing any bottle/head blocks, fixing brew audit --strict and then submitting it. After that it should be good to go.

@dylancarlson
Copy link

@DomT4 thanks. I don't think this formula will come to that. 0.14 was a feature release, hugo releases every 3-4 months so we should see this fixed in the next by ~September. If other people complain about this issue, I'll be happy to do a PR. For now I've rolled back to 0.13 and pinned it.

@Homebrew Homebrew locked and limited conversation to collaborators Jul 10, 2016
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants