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

Support copyright header templates in CIMTool #22

Closed
admin-cimug opened this issue Jul 21, 2022 · 0 comments
Closed

Support copyright header templates in CIMTool #22

admin-cimug opened this issue Jul 21, 2022 · 0 comments
Assignees
Labels
enhancement New feature or request

Comments

@admin-cimug
Copy link
Member

Enhancements are needed in CIMTool to fully support flexible configuration of copyright header templates. Basic requirements are as follows:

  1. Copyright templates must be supported at the "project level".
  2. Support for both multi-line and single-line templates should be implemented so that a given builder can be implemented to support using either template depending on the copyright needs or constraints of the type of output it generates.
  3. Copyright header templates (as shown below) are to be shipped with CIMTool and used as defaults for any new project.
  4. The implementation of this feature should allow for backwards compatibility meaning that as of CIMTool 1.10.0.RC3 and onward that upon importing an older CIMTool project the default templates should be added to the imported project automatically.
  5. The copyright header templates should be stored at the project level and in the root of a the project folder on the file system. It is recommended that the template be stored as hidden files on windows so that they will not be visible in the CIMTool Project workspace and therefore non-editable by an end-user.
  6. Templates should support a ${year} placeholder variable in templates with CIMTool handling the substitution of the variable with the current year whenever a builder is executed and the output of a builder regenerated.
  7. Two new Import wizards for importing both multi-line and single-line copyright templates respectively should be implemented. These screens should perform validation on the template the user selected from the file system. A valid template should have the ${year} substitution variable present and if it is a multi-line template then multiple lines should be present and only a single line for single-line templates (i.e. no carriage returns should exist in the template or minimally any leading and trailing should be removed before saving)

Default multi-line copyright header:

Copyright ${year} UCAIug

Licensed under the Apache License, Version 2.0 (the "License");
you may not use this file except in compliance with the License.
You may obtain a copy of the License at

https://www.apache.org/licenses/LICENSE-2.0

Unless required by applicable law or agreed to in writing, software
distributed under the License is distributed on an "AS IS" BASIS,
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
	
See the License for the specific language governing permissions and
limitations under the License.

Default single-line copyright header:

Copyright ${year} UCAIug SPDX-License-Identifier: Apache-2.0
@admin-cimug admin-cimug self-assigned this Jul 21, 2022
@admin-cimug admin-cimug added the enhancement New feature or request label Jul 21, 2022
@admin-cimug admin-cimug added this to the release-1.10.0.RC3 milestone Jul 21, 2022
@admin-cimug admin-cimug reopened this Jul 28, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
None yet
Development

No branches or pull requests

1 participant