Use consistent case for error messages

Use the style introduced by @def- in
61e47422f6
This commit is contained in:
ChillerDragon 2021-08-03 16:14:54 +02:00
parent 3d3c190cd4
commit 02abc95c18
3 changed files with 13 additions and 4 deletions

View file

@ -36,6 +36,15 @@ jobs:
run: scripts/check_dilate.sh release data
- name: Shellcheck
run: find . -type f -name '*.sh' -print0 | xargs -0 shellcheck
- name: Check log error case
run: |
if grep -Eqr '(msg|Print).*\(.*"[Ee]rror:' src/;
then
echo "[!] Expect log erros to be in this format 'ERROR: error message'"
echo "[!] Found these non uppercased log errors:"
grep -Er '(msg|Print).*\(.*"[Ee]rror:' src/
exit 1
fi
- name: Pylint
run: |
pylint --version

View file

@ -190,7 +190,7 @@ void CCommandProcessorFragment_OpenGL::SetState(const CCommandBuffer::SState &St
}
else
{
dbg_msg("opengl", "Error: this call should not happen.");
dbg_msg("opengl", "ERROR: this call should not happen.");
}
}
}

View file

@ -3691,7 +3691,7 @@ void CClient::Con_SaveReplay(IConsole::IResult *pResult, void *pUserData)
{
int Length = pResult->GetInteger(0);
if(Length <= 0)
pSelf->m_pConsole->Print(IConsole::OUTPUT_LEVEL_STANDARD, "replay", "Error: length must be greater than 0 second.");
pSelf->m_pConsole->Print(IConsole::OUTPUT_LEVEL_STANDARD, "replay", "ERROR: length must be greater than 0 second.");
else
pSelf->SaveReplay(Length);
}
@ -3709,9 +3709,9 @@ void CClient::SaveReplay(const int Length)
}
if(!DemoRecorder(RECORDER_REPLAYS)->IsRecording())
m_pConsole->Print(IConsole::OUTPUT_LEVEL_STANDARD, "replay", "Error: demorecorder isn't recording. Try to rejoin to fix that.");
m_pConsole->Print(IConsole::OUTPUT_LEVEL_STANDARD, "replay", "ERROR: demorecorder isn't recording. Try to rejoin to fix that.");
else if(DemoRecorder(RECORDER_REPLAYS)->Length() < 1)
m_pConsole->Print(IConsole::OUTPUT_LEVEL_STANDARD, "replay", "Error: demorecorder isn't recording for at least 1 second.");
m_pConsole->Print(IConsole::OUTPUT_LEVEL_STANDARD, "replay", "ERROR: demorecorder isn't recording for at least 1 second.");
else
{
// First we stop the recorder to slice correctly the demo after