Skip to content

Commit

Permalink
Merge pull request #183 from zaqbez39me/fix/test-raf-root-usage
Browse files Browse the repository at this point in the history
Removed usage of sudo from test-raf.sh
  • Loading branch information
yegor256 authored Mar 1, 2024
2 parents e03b3d0 + de83afc commit aa46376
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion metrics/raf.sh
Original file line number Diff line number Diff line change
Expand Up @@ -39,7 +39,7 @@ if git status > /dev/null 2>&1 && test -n "$(git log --oneline -- "${base}")"; t
current_time_timestamp=$(date -d "$current_time" +%s)
from_file_creation=$((current_time_timestamp - file_creation_timestamp))
from_repo_creation=$((current_time_timestamp - repo_creation_timestamp))
raf=$(echo 'import sys; print(float(sys.argv[1])/float(sys.argv[2]) if float(sys.argv[2]) != 0 else 1.0)' | python - $((from_file_creation)) $((from_repo_creation)))
raf=$(echo 'import sys; print(float(sys.argv[1])/float(sys.argv[2]) if float(sys.argv[2]) != 0 else 1.0)' | python3 - $((from_file_creation)) $((from_repo_creation)))
else
raf=0
fi
Expand Down

0 comments on commit aa46376

Please sign in to comment.