forked from ARM-software/arm-trusted-firmware
-
Notifications
You must be signed in to change notification settings - Fork 4
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #3 from SgrrZhf/topics/huizha01/2.9.0-updates
TF-A 2.9.0 updates
- Loading branch information
Showing
1,444 changed files
with
77,429 additions
and
19,134 deletions.
There are no files selected for viewing
This file contains 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
This file contains 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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,6 @@ | ||
#!/bin/sh | ||
|
||
# shellcheck source=./_/husky.sh | ||
. "$(dirname "$0")/_/husky.sh" | ||
|
||
"$(dirname "$0")/pre-commit.copyright" "$@" |
This file contains 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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,63 @@ | ||
#!/bin/bash | ||
|
||
# A hook script that checks if files staged for commit have updated Arm copyright year. | ||
# In case they are not - updates the years and prompts user to add them to the change. | ||
# This hook is called on "git commit" after changes have been staged, but before commit | ||
# message has to be provided. | ||
|
||
RED="\033[00;31m" | ||
YELLOW="\033[00;33m" | ||
BLANK="\033[00;00m" | ||
|
||
FILES=`git diff --cached --name-only HEAD` | ||
YEAR_NOW=`date +"%Y"` | ||
|
||
YEAR_RGX="[0-9][0-9][0-9][0-9]" | ||
ARM_RGX="\(ARM\|Arm\|arm\)" | ||
|
||
exit_code=0 | ||
|
||
function user_warning() { | ||
echo -e "Copyright of $RED$FILE$BLANK is out of date/incorrect" | ||
echo -e "Updated copyright to" | ||
grep -nr "opyright.*$YEAR_RGX.*$ARM_RGX" "$FILE" | ||
echo | ||
} | ||
|
||
while read -r FILE; do | ||
if [ -z "$FILE" ] | ||
then | ||
break | ||
fi | ||
# Check if correct copyright notice is in file. | ||
# To reduce false positives, we assume files with no | ||
# copyright notice do not require it. | ||
if ! grep "opyright.*$YEAR_NOW.*$ARM_RGX" "$FILE">/dev/null 2>&1 | ||
then | ||
# If it is "from_date - to_date" type of entry - change to_date entry. | ||
if grep "opyright.*$YEAR_RGX.*-.*$YEAR_RGX.*$ARM_RGX" "$FILE" >/dev/null 2>&1 | ||
then | ||
exit_code=1 | ||
sed -i "s/\(opyright.*\)$YEAR_RGX\(.*$ARM_RGX\)/\1$(date +"%Y"), Arm/" $FILE | ||
user_warning | ||
# If it is single "date" type of entry - add the copyright extension to current year. | ||
elif grep "opyright.*$YEAR_RGX.*$ARM_RGX" "$FILE" >/dev/null 2>&1 | ||
then | ||
exit_code=1 | ||
sed -i "s/\(opyright.*$YEAR_RGX\)\(.*$ARM_RGX\)/\1-$(date +"%Y"), Arm/" $FILE | ||
user_warning | ||
fi | ||
# Even if the year is correct - verify that Arm copyright is formatted correctly. | ||
elif grep "opyright.*\(ARM\|arm\)" "$FILE">/dev/null 2>&1 | ||
then | ||
exit_code=1 | ||
sed -i "s/\(opyright.*\)\(ARM\|arm\)/\1Arm/" $FILE | ||
user_warning | ||
fi | ||
done <<< "$FILES" | ||
|
||
if [ $exit_code -eq 1 ] | ||
then | ||
echo -e "$RED""Please stage updated files$BLANK before commiting or use$YELLOW git commit --no-verify$BLANK to skip copyright check" | ||
fi | ||
exit $exit_code |
This file contains 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
This file contains 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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1 @@ | ||
v16.17.1 |
This file contains 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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,26 @@ | ||
# Copyright (c) 2023, Arm Limited. All rights reserved | ||
# | ||
# SPDX-License-Identifier: BSD-3-Clause | ||
# | ||
# Configuration file for the readthedocs deploy | ||
# Available at https://trustedfirmware-a.readthedocs.io/en/latest/ | ||
|
||
|
||
# readthedocs config version | ||
version: 2 | ||
|
||
build: | ||
os: ubuntu-22.04 # Ubuntu Jammy LTS | ||
tools: | ||
python: "3.10" | ||
apt_packages: | ||
- plantuml | ||
jobs: | ||
post_create_environment: | ||
- pip install poetry=="1.3.2" | ||
- poetry config virtualenvs.create false | ||
post_install: | ||
- poetry install --with doc | ||
|
||
sphinx: | ||
configuration: docs/conf.py |
This file contains 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
Oops, something went wrong.