Skip to content

Commit 83829f2

Browse files
committed
Use a short SPDX license header where applicable; standard lic elsewhere
Following the approach from Apache Airflow PRs #62073 and #62145, files intended for LLM/agent consumption (not distributed in releases) now use a minimal SPDX license identifier instead of the full Apache 2.0 header - for LLM token efficiency. See also: https://lists.apache.org/thread/j1tn63r2lf13v3d1tnnqff8fkcl4nx53
1 parent 7d831f3 commit 83829f2

48 files changed

Lines changed: 819 additions & 65 deletions

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

.asf.yaml

Lines changed: 17 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,20 @@
1+
# Licensed to the Apache Software Foundation (ASF) under one
2+
# or more contributor license agreements. See the NOTICE file
3+
# distributed with this work for additional information
4+
# regarding copyright ownership. The ASF licenses this file
5+
# to you under the Apache License, Version 2.0 (the
6+
# "License"); you may not use this file except in compliance
7+
# with the License. You may obtain a copy of the License at
8+
#
9+
# http://www.apache.org/licenses/LICENSE-2.0
10+
#
11+
# Unless required by applicable law or agreed to in writing,
12+
# software distributed under the License is distributed on an
13+
# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
14+
# KIND, either express or implied. See the License for the
15+
# specific language governing permissions and limitations
16+
# under the License.
17+
118
# https://cwiki.apache.org/confluence/display/INFRA/Git+-+.asf.yaml+features
219

320
github:

.gitattributes

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,8 @@
1+
# SPDX-License-Identifier: Apache-2.0
2+
3+
# Files below use a short SPDX license identifier instead of the full
4+
# Apache 2.0 header because they are NOT included in official releases
5+
# (sdist / wheel). The `export-ignore` attribute ensures `git archive`
6+
# (and tools that rely on it) will exclude them automatically.
7+
8+
.github export-ignore

.github/PULL_REQUEST_TEMPLATE.md

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,5 @@
1+
<!-- SPDX-License-Identifier: Apache-2.0 -->
2+
13
--- PR TEMPLATE INSTRUCTIONS (1) ---
24

35
Looking to submit a Apache Hamilton Dataflow to the sf-hamilton-contrib module? If so go the the `Preview` tab and select the appropriate sub-template:

.github/PULL_REQUEST_TEMPLATE/HAMILTON_CONTRIB_PR_TEMPLATE.md

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,5 @@
1+
<!-- SPDX-License-Identifier: Apache-2.0 -->
2+
13
[Summary of contribution]
24

35
## For new dataflows:

.pre-commit-config.yaml

Lines changed: 89 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,20 @@
1+
# Licensed to the Apache Software Foundation (ASF) under one
2+
# or more contributor license agreements. See the NOTICE file
3+
# distributed with this work for additional information
4+
# regarding copyright ownership. The ASF licenses this file
5+
# to you under the Apache License, Version 2.0 (the
6+
# "License"); you may not use this file except in compliance
7+
# with the License. You may obtain a copy of the License at
8+
#
9+
# http://www.apache.org/licenses/LICENSE-2.0
10+
#
11+
# Unless required by applicable law or agreed to in writing,
12+
# software distributed under the License is distributed on an
13+
# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
14+
# KIND, either express or implied. See the License for the
15+
# specific language governing permissions and limitations
16+
# under the License.
17+
118
# pre-commit hooks require a user to have installed `prek`:
219
# $ brew install prek
320
# Then install the hooks within the repo:
@@ -25,6 +42,78 @@ repos:
2542
- id: requirements-txt-fixer
2643
# valid python file
2744
- id: check-ast
45+
- repo: https://github.com/Lucas-C/pre-commit-hooks
46+
rev: v1.5.6
47+
hooks:
48+
- id: insert-license
49+
name: Add license for all Python files
50+
files: \.py$|\.pyi$
51+
exclude: ^\.github/
52+
args:
53+
- --comment-style
54+
- "|#|"
55+
- --license-filepath
56+
- scripts/ci/license-templates/LICENSE
57+
- --fuzzy-match-generates-todo
58+
- id: insert-license
59+
name: Add license for all YAML files
60+
files: \.ya?ml$
61+
types: [yaml]
62+
exclude: ^\.github/
63+
args:
64+
- --comment-style
65+
- "|#|"
66+
- --license-filepath
67+
- scripts/ci/license-templates/LICENSE
68+
- --fuzzy-match-generates-todo
69+
- id: insert-license
70+
name: Add license for all TOML files
71+
files: \.toml$
72+
exclude: ^\.github/
73+
args:
74+
- --comment-style
75+
- "|#|"
76+
- --license-filepath
77+
- scripts/ci/license-templates/LICENSE
78+
- --fuzzy-match-generates-todo
79+
- id: insert-license
80+
name: Add license for all Shell files
81+
files: \.bash$|\.sh$
82+
exclude: ^\.github/
83+
args:
84+
- --comment-style
85+
- "|#|"
86+
- --license-filepath
87+
- scripts/ci/license-templates/LICENSE
88+
- --fuzzy-match-generates-todo
89+
- id: insert-license
90+
name: Add license for all Markdown files
91+
files: \.md$
92+
exclude: |
93+
(?x)
94+
^\.github/.*\.md$|
95+
^scripts/ci/license-templates/
96+
args:
97+
- --comment-style
98+
- "<!--|| -->"
99+
- --license-filepath
100+
- scripts/ci/license-templates/LICENSE
101+
- --fuzzy-match-generates-todo
102+
- id: insert-license
103+
name: Add short license for agentic Markdown files
104+
files: |
105+
(?x)
106+
^\.github/.*\.md$
107+
exclude: |
108+
(?x)
109+
^\.github/ISSUE_TEMPLATE/|
110+
^scripts/ci/license-templates/
111+
args:
112+
- --comment-style
113+
- "||"
114+
- --license-filepath
115+
- scripts/ci/license-templates/SHORT_LICENSE.md
116+
- --fuzzy-match-generates-todo
28117
- repo: local
29118
hooks:
30119
- id: validate-example-notebooks

.readthedocs.yaml

Lines changed: 17 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,20 @@
1+
# Licensed to the Apache Software Foundation (ASF) under one
2+
# or more contributor license agreements. See the NOTICE file
3+
# distributed with this work for additional information
4+
# regarding copyright ownership. The ASF licenses this file
5+
# to you under the Apache License, Version 2.0 (the
6+
# "License"); you may not use this file except in compliance
7+
# with the License. You may obtain a copy of the License at
8+
#
9+
# http://www.apache.org/licenses/LICENSE-2.0
10+
#
11+
# Unless required by applicable law or agreed to in writing,
12+
# software distributed under the License is distributed on an
13+
# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
14+
# KIND, either express or implied. See the License for the
15+
# specific language governing permissions and limitations
16+
# under the License.
17+
118
# .readthedocs.yaml
219
# Read the Docs configuration file
320
# See https://docs.readthedocs.io/en/stable/config-file/v2.html for details

CONTRIBUTING.md

Lines changed: 18 additions & 15 deletions
Original file line numberDiff line numberDiff line change
@@ -1,19 +1,22 @@
1+
12
<!--
2-
Licensed to the Apache Software Foundation (ASF) under one or more
3-
contributor license agreements. See the NOTICE file distributed with
4-
this work for additional information regarding copyright ownership.
5-
The ASF licenses this file to You under the Apache License, Version 2.0
6-
(the "License"); you may not use this file except in compliance with
7-
the License. You may obtain a copy of the License at
8-
9-
http://www.apache.org/licenses/LICENSE-2.0
10-
11-
Unless required by applicable law or agreed to in writing, software
12-
distributed under the License is distributed on an "AS IS" BASIS,
13-
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
14-
See the License for the specific language governing permissions and
15-
limitations under the License.
16-
-->
3+
Licensed to the Apache Software Foundation (ASF) under one
4+
or more contributor license agreements. See the NOTICE file
5+
distributed with this work for additional information
6+
regarding copyright ownership. The ASF licenses this file
7+
to you under the Apache License, Version 2.0 (the
8+
"License"); you may not use this file except in compliance
9+
with the License. You may obtain a copy of the License at
10+
11+
http://www.apache.org/licenses/LICENSE-2.0
12+
13+
Unless required by applicable law or agreed to in writing,
14+
software distributed under the License is distributed on an
15+
"AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
16+
KIND, either express or implied. See the License for the
17+
specific language governing permissions and limitations
18+
under the License.
19+
-->
1720

1821
# Guidance on how to contribute
1922

SECURITY.md

Lines changed: 19 additions & 15 deletions
Original file line numberDiff line numberDiff line change
@@ -1,19 +1,23 @@
1+
12
<!--
2-
Licensed to the Apache Software Foundation (ASF) under one or more
3-
contributor license agreements. See the NOTICE file distributed with
4-
this work for additional information regarding copyright ownership.
5-
The ASF licenses this file to You under the Apache License, Version 2.0
6-
(the "License"); you may not use this file except in compliance with
7-
the License. You may obtain a copy of the License at
8-
9-
http://www.apache.org/licenses/LICENSE-2.0
10-
11-
Unless required by applicable law or agreed to in writing, software
12-
distributed under the License is distributed on an "AS IS" BASIS,
13-
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
14-
See the License for the specific language governing permissions and
15-
limitations under the License.
16-
-->
3+
Licensed to the Apache Software Foundation (ASF) under one
4+
or more contributor license agreements. See the NOTICE file
5+
distributed with this work for additional information
6+
regarding copyright ownership. The ASF licenses this file
7+
to you under the Apache License, Version 2.0 (the
8+
"License"); you may not use this file except in compliance
9+
with the License. You may obtain a copy of the License at
10+
11+
http://www.apache.org/licenses/LICENSE-2.0
12+
13+
Unless required by applicable law or agreed to in writing,
14+
software distributed under the License is distributed on an
15+
"AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
16+
KIND, either express or implied. See the License for the
17+
specific language governing permissions and limitations
18+
under the License.
19+
-->
20+
1721
# Security Policy
1822
The security surface area of Apache Hamilton should be pretty small in comparison to other projects.
1923

contrib/docs/blog/authors.yml

Lines changed: 17 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,20 @@
1+
# Licensed to the Apache Software Foundation (ASF) under one
2+
# or more contributor license agreements. See the NOTICE file
3+
# distributed with this work for additional information
4+
# regarding copyright ownership. The ASF licenses this file
5+
# to you under the Apache License, Version 2.0 (the
6+
# "License"); you may not use this file except in compliance
7+
# with the License. You may obtain a copy of the License at
8+
#
9+
# http://www.apache.org/licenses/LICENSE-2.0
10+
#
11+
# Unless required by applicable law or agreed to in writing,
12+
# software distributed under the License is distributed on an
13+
# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
14+
# KIND, either express or implied. See the License for the
15+
# specific language governing permissions and limitations
16+
# under the License.
17+
118
skrawcz:
219
name: Stefan Krawczyk
320
title: Co-creator of Hamilton and CEO @ DAGWorks Inc.

dev_tools/language_server/pyproject.toml

Lines changed: 17 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,20 @@
1+
# Licensed to the Apache Software Foundation (ASF) under one
2+
# or more contributor license agreements. See the NOTICE file
3+
# distributed with this work for additional information
4+
# regarding copyright ownership. The ASF licenses this file
5+
# to you under the Apache License, Version 2.0 (the
6+
# "License"); you may not use this file except in compliance
7+
# with the License. You may obtain a copy of the License at
8+
#
9+
# http://www.apache.org/licenses/LICENSE-2.0
10+
#
11+
# Unless required by applicable law or agreed to in writing,
12+
# software distributed under the License is distributed on an
13+
# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
14+
# KIND, either express or implied. See the License for the
15+
# specific language governing permissions and limitations
16+
# under the License.
17+
118
[build-system]
219
requires = ["setuptools >= 65.0.0"]
320
build-backend = "setuptools.build_meta"

0 commit comments

Comments
 (0)