[CI] Add pre-commit hook to auto insert license for RST files#2752
Draft
jbampton wants to merge 1 commit intoapache:masterfrom
Draft
[CI] Add pre-commit hook to auto insert license for RST files#2752jbampton wants to merge 1 commit intoapache:masterfrom
jbampton wants to merge 1 commit intoapache:masterfrom
Conversation
Apache Airflow uses this same "insert-license" hook for RST files https://github.com/apache/airflow/blob/d1455c892fedf1256ed88e389bd0ededad8ad4a4/.pre-commit-config.yaml#L73 https://github.com/apache/airflow/blob/main/scripts/ci/license-templates/LICENSE.rst We already use pre-commit to insert licenses for other files
Member
|
@zhangfengcdt I think these RST files were automatically generated, right? |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Apache Airflow uses this same "insert-license" hook for RST files
https://github.com/apache/airflow/blob/d1455c892fedf1256ed88e389bd0ededad8ad4a4/.pre-commit-config.yaml#L73
https://github.com/apache/airflow/blob/main/scripts/ci/license-templates/LICENSE.rst
We already use pre-commit to insert licenses for other files
Did you read the Contributor Guide?
Is this PR related to a ticket?
[CI] my subjectWhat changes were proposed in this PR?
Added another check / test to our pre-commit framework
How was this patch tested?
sedona$ pre-commit run --all-filesto test the insert license hook both before and after the license headers were auto insertedsedona$ cd python/sedona/doc; make htmland viewed the generated HTML files in_buildfolder in my IDE and no license headers were present. Also opened some of these HTML files in Firefox and they display correctlyDid this PR include necessary documentation updates?