[ 
https://issues.apache.org/jira/browse/NETBEANS-2756?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=16874179#comment-16874179
 ] 

Laszlo Kishalmi commented on NETBEANS-2756:
-------------------------------------------

Well, it seems it is either a bug or a wrong documentation, so there is 
certainly a thing to do about it.

The docs incorrectly says that the netbeans.license shall be relative to the 
root project, which would eventually make sense.

However the code expects relative path to the project or absolute path.

You can use the absolute path in your root project's build.gradle as of:

{{ext.license = file("$rootDir/licenseheader") or 
ext.setProperty('netbeans.license', file("$rootDir/licenseheader"))}}

so I'm going to change the docs to match the implementation.

Then I'm going to add that if the license header is not found relative to the 
project then it shall be searched relative to the root project.

Change the docs according to the later change when it gets released.

> Gradle project properties: Couldn't get license header to work
> --------------------------------------------------------------
>
>                 Key: NETBEANS-2756
>                 URL: https://issues.apache.org/jira/browse/NETBEANS-2756
>             Project: NetBeans
>          Issue Type: Bug
>          Components: projects - Gradle
>         Environment: Windows 10
> Netbeans 11.1 beta 2
> Oracle JDK 8
> Gradle 5.2
>            Reporter: Travis
>            Assignee: Laszlo Kishalmi
>            Priority: Minor
>
> I tried adding the following line in my root project's gradle.properties file:
>  
> netbeans.license=licenseheader
>  
> And placing a file named "licenseheader" in the root project directory.
>  
> After doing so and creating a new file in the IDE editor, the header was not 
> included.  Also, the project properties "License Headers" settings appear the 
> same as before, as if the new line in gradle.properties is being completely 
> ignored.  There were no notifications about any exceptions during this 
> experiment.
>  
>  
> I believe what I did was consistent with the directions at:
> [https://cwiki.apache.org/confluence/display/NETBEANS/License+Headers]
>  
> Am I doing something wrong?  Or is there still a bug with this feature?



--
This message was sent by Atlassian JIRA
(v7.6.3#76005)

---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]

For further information about the NetBeans mailing lists, visit:
https://cwiki.apache.org/confluence/display/NETBEANS/Mailing+lists

Reply via email to