Skip to content
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

CreateAssemblyInfo alias should allow creation of custom boolean attributes and also empty attributes #2638

Closed
gep13 opened this issue Oct 15, 2019 · 0 comments · Fixed by #2639
Closed
Assignees
Labels
Milestone

Comments

@gep13
Copy link
Member

@gep13 gep13 commented Oct 15, 2019

Currently, it is possible to use the CustomAttributes collection of the AssemblyInfoSettings class to create custom attributes that are not covered in the base AssemblyInfoSettings class. However, it is not currently possible to create a custom attribute that looks like the following:

[assembly: CustomAttributeA(false)]

or like this:

[assembly: CustomAttributeB()]

This is due in part to the fact that the CreateAssemblyInfo alias was never intended to cover all bases, however, I believe that this scenario is common enough that it should be possible.

This is NOT related to this issue: #1027 which is actually looking for a new alias ModifyAssemblyInfo, which knows and understands all the attributes in the assemblyinfo file. This issue is constrained only to the CreateAssemblyInfo alias.

@gep13 gep13 added the Feature label Oct 15, 2019
@gep13 gep13 added this to the v0.36.0 milestone Oct 15, 2019
@gep13 gep13 self-assigned this Oct 15, 2019
gep13 added a commit to gep13/cake that referenced this issue Oct 15, 2019
When creating CustomAttributes for AssemblyInfo files, it is useful to
be able to generate attributes with boolean values, as well as attributes
that don't have a value.  This is a "simple" solution to allow this to
happen, a broader fix would be to use Roslyn to fully understand all
attributes in the file.
gep13 added a commit to gep13/cake that referenced this issue Oct 15, 2019
When creating CustomAttributes for AssemblyInfo files, it is useful to
be able to generate attributes with boolean values, as well as attributes
that don't have a value.  This is a "simple" solution to allow this to
happen, a broader fix would be to use Roslyn to fully understand all
attributes in the file.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
1 participant
You can’t perform that action at this time.