mirror of
https://github.com/mesonbuild/meson.git
synced 2026-06-24 08:48:03 +00:00
This replaces all of the Apache blurbs at the start of each file with an `# SPDX-License-Identifier: Apache-2.0` string. It also fixes existing uses to be consistent in capitalization, and to be placed above any copyright notices. This removes nearly 3000 lines of boilerplate from the project (only python files), which no developer cares to look at. SPDX is in common use, particularly in the Linux kernel, and is the recommended format for Meson's own `project(license: )` field
20 lines
420 B
Python
20 lines
420 B
Python
# SPDX-License-Identifier: Apache-2.0
|
|
# Copyright © 2021-2023 Intel Corporation
|
|
from __future__ import annotations
|
|
|
|
"""Helper script to copy files at build time.
|
|
|
|
This is easier than trying to detect whether to use copy, cp, or something else.
|
|
"""
|
|
|
|
import shutil
|
|
import typing as T
|
|
|
|
|
|
def run(args: T.List[str]) -> int:
|
|
try:
|
|
shutil.copy2(args[0], args[1])
|
|
except Exception:
|
|
return 1
|
|
return 0
|