-
Notifications
You must be signed in to change notification settings - Fork 83
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Added a bundler:clean task #68
Conversation
It brings some kind of unstability to rollbacked releases. I'm not really sure that we need to include this task into the gem. |
As I commented on #65, now that there's a hook for running |
Why altering the log level? Can't you use something like |
@Kriechi Done, please take another look. |
Nice! |
Agreed. There are some arguments that should be passed here if they are set. I have to take a look at the docs to see which ones are applicable. Hopefully I can get to this later today. |
Done, a few days later than I'd hope. Please take a look again. |
@kirs Can we get this merged? |
Would love to see this merged too! |
Will this PR be merged someday ? |
What about just adding |
That's risky--what if the deployment fails and need to be rolled back? Some gems (nokogiri, etc.) may take a long time to install and rollbacks need to be as fast as possible. |
@betesh If rollbacks need to be as fast as possible, then it seems like running |
Since there are some rollback risks involved in supporting this feature, and since it is fairly trivial for someone to implement their own |
I just ran across this. I'm about to write my own Gem to do it, but it might be worth putting in core. If this is in core, it should only be a task with no default hook.
If someone wants this task, the would just need to add it as an after published task. This would indeed slow rollbacks slightly, but as long as we don't make it the default, I don't think it is an issue. We should just make sure to document the tradeoff. In my case, we are running out of disk space due to tons of Gems lying around. I'm running a cleanup command periodically right now. @mattbrictson, have I provided some decent arguments in favor of this change? |
+200 |
If you are running out of disk space due to old gems piling up, then this is a more pressing issue than I realized. In that case, I'm in favor or adding the |
@betesh: Could you take a whack at documenting the tradeoffs? To give you a head start, what do you think of something like:
|
@betesh Also, could you clarify the purpose behind capturing the |
@mattbrictson It's been a while but IIRC, I capture the output so that you can see the results even when your log level is higher than debug. This is helpful, as long as it's not too noisy, so I reformat it to keep it concise. @will-in-wi I'm too busy at the momet to push changes of my own. I recommend forking my fork and submitting a PR to me. Once I merge your PR, it will show up on this PR. I did that once before here and it worked well. One suggestion about your proposed documentation: I would give a little more context about why nokogiri in particular takes so long, and make it clear that it's one of several examples, but not all gems take that long. |
@betesh: I've added a docs PR: https://github.com/betesh/bundler/pull/1 @mattbrictson: Could you comment on what you'd prefer with the output capture? I can add a change to fix that if needed. |
Add docs per clean option.
@will-in-wi I've merged your PR into mine, but feel free to open another PR if there's followup after @mattbrictson gives feedback |
Regarding the output, I think the task "bundler:clean" do
on release_roles(:all) do
within current_path do
execute :bundle, :clean
end
end
end
Adding the |
It's not confusing or incomplete. In this particular context, I found it useful but unnecessarily verbose. I agree that it's a matter of opinion. |
@mattbrictson I added another PR without capture: #85 |
Closed in favor of #85, which combines commits from this PR along with some modifications from @will-in-wi. |
No description provided.