Skip to content
New issue

Have a question about this project? # for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “#”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? # to your account

CakeTaskExtensions are no longer accessible #2228

Closed
gitfool opened this issue Aug 14, 2018 · 1 comment
Closed

CakeTaskExtensions are no longer accessible #2228

gitfool opened this issue Aug 14, 2018 · 1 comment
Labels
Milestone

Comments

@gitfool
Copy link
Contributor

gitfool commented Aug 14, 2018

What You Are Seeing?

CakeTaskExtensions are no longer accessible.

What is Expected?

CakeTaskExtensions to be accessible; as before upgrading.

What version of Cake are you using?

0.29.0

Are you running on a 32 or 64 bit system?

64-bit

What environment are you running on? Windows? Linux? Mac?

Windows

Are you running on a CI Server? If so, which one?

TeamCity

How Did You Get This To Happen? (Steps to Reproduce)

I recently updated from Cake 0.23.0 to 0.29.0 and hit the following breaking change:
commit/105eb540d1958f11d7953000ace4377042f192a6#diff-f817cf6c892a63876e9847920aae68eaR8

The CakeTaskExtensions class accessibility was changed from public to internal and we have lots of builds scripts using it; for example using AddCriteria to disable a task in order to override its behaviour:

Tasks.First(x => x.Name == "Zip-DataStore")
    .AddCriteria(() => false);

I can hack around it but it's not pretty:

((CakeTask)Tasks.First(x => x.Name == "Zip-DataStore"))
    .Criterias.Add(new CakeTaskCriteria(_ => false, null));

Output Log

@patriksvensson
Copy link
Member

@gitfool This seems to have been overlooked. I'm OK with making the extensions public.
Would you mind submitting a pull request for this? 👍

# for free to join this conversation on GitHub. Already have an account? # to comment
Labels
Projects
None yet
Development

No branches or pull requests

2 participants