Skip to content
Snippets Groups Projects
Commit 65fa9e69 authored by Martin Schroschk's avatar Martin Schroschk
Browse files

Let spell check skip files with german stuff.

parent a06c9c29
No related branches found
No related tags found
3 merge requests!322Merge preview into main,!319Merge preview into main,!272Review loadleveler page
......@@ -146,12 +146,10 @@ description of keywords\]\].
Submission of a job without a job file can be done by the command:
`llsub [llsub_options] <command>`
This command is not part of the IBM Loadleveler software but was
developed at ZIH.
This command is not part of the IBM LoadLeveler software but was developed at ZIH.
The job file will be created in background by means of the command line
options. Afterwards, the job file will be passed to the command
`llsubmit` which submit the job to LoadLeveler (see above).
The job file will be created in background by means of the command line options. Afterwards, the job
file will be passed to the command `llsubmit` which submit the job to LoadLeveler (see above).
Important options are:
......@@ -185,9 +183,9 @@ Interactive Jobs can be submitted by the command:
llsub -I -q <interactive> <command>
```
### Loadleveler Runtime Environment Variables
### LoadLeveler Runtime Environment Variables
Loadleveler Runtime Variables give you some information within the job
LoadLeveler runtime variables give you some information within the job
script, for example:
```Bash
......
......@@ -13,7 +13,7 @@ function getNumberOfAspellOutputLines(){
branch="preview"
if [ -n "$CI_MERGE_REQUEST_TARGET_BRANCH_NAME" ]; then
branch="origin/$CI_MERGE_REQUEST_TARGET_BRANCH_NAME"
branch="origin/$CI_MERGE_REQUEST_TARGET_BRANCH_NAME"
fi
any_fails=false
......@@ -25,30 +25,37 @@ files=`git diff $source_hash | sed -n 's/^[-+]\{3,3\} //p'`
#echo "-------------------------"
#Assume that we have pairs of lines (starting with --- and +++).
while read oldfile; do
read newfile
if [ "${newfile: -3}" == ".md" ]; then
if [ "$oldfile" == "/dev/null" ]; then
#Added files should not introduce new spelling mistakes
previous_count=0
else
previous_count=`git show "$source_hash:${oldfile:2}" | getNumberOfAspellOutputLines`
fi
if [ "$newfile" == "/dev/null" ]; then
#Deleted files do not contain any spelling mistakes
current_count=0
else
#Remove the prefix "b/"
newfile=${newfile:2}
current_count=`cat "$newfile" | getNumberOfAspellOutputLines`
fi
if [ $current_count -gt $previous_count ]; then
echo "-- File $newfile"
echo "Change increases spelling mistake count (from $previous_count to $current_count)"
any_fails=true
fi
read newfile
if [ "${newfile: -3}" == ".md" ]; then
if [[ $newfile == *"accessibility.md"* ||
$newfile == *"data_protection_declaration.md"* ||
$newfile == *"legal_notice.md"* ]]; then
echo "Skip $newfile"
else
echo "Check $newfile"
if [ "$oldfile" == "/dev/null" ]; then
#Added files should not introduce new spelling mistakes
previous_count=0
else
previous_count=`git show "$source_hash:${oldfile:2}" | getNumberOfAspellOutputLines`
fi
if [ "$newfile" == "/dev/null" ]; then
#Deleted files do not contain any spelling mistakes
current_count=0
else
#Remove the prefix "b/"
newfile=${newfile:2}
current_count=`cat "$newfile" | getNumberOfAspellOutputLines`
fi
if [ $current_count -gt $previous_count ]; then
echo "-- File $newfile"
echo "Change increases spelling mistake count (from $previous_count to $current_count)"
any_fails=true
fi
fi
fi
done <<< "$files"
if [ "$any_fails" == true ]; then
exit 1
exit 1
fi
......@@ -92,3 +92,6 @@ gnuplot
RSA
SHA
pipelining
stdout
stderr
multithreaded
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment