Skip to content

Commit

Permalink
GHA: added an action to spell check.
Browse files Browse the repository at this point in the history
  • Loading branch information
agarny committed May 9, 2024
1 parent 5e920f2 commit 0ef1f35
Show file tree
Hide file tree
Showing 8 changed files with 30 additions and 9 deletions.
21 changes: 21 additions & 0 deletions .github/workflows/spellCheck.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,21 @@
name: Spell check

on:
pull_request:
branches: [ master ]
workflow_dispatch:

jobs:
spell_check:
name: Spell check
runs-on: ubuntu-latest
steps:
- name: Check out OpenCOR
uses: actions/checkout@v4
- name: Spell check
uses: codespell-project/actions-codespell@v2
with:
check_filenames: true
skip: ./i18n,.res/flags,./res/ui.qrc,./src/3rdparty,./src/plugins/thirdParty/PythonPackages/scripts
exclude_file: *_fr.ts
ignore_words_list: fileTests,pEvent,pRes,DEPENDEES
Original file line number Diff line number Diff line change
Expand Up @@ -1300,7 +1300,7 @@ void CellmlTextViewWidget::mathmlConversionDone(const QString &pContentMathml,
// Note: before setting the contents of our viewer, we need to make sure
// that pInput is still our current Content MathML equation. Indeed,
// say that updateViewer() gets called many times in a short period of
// time (e.g. as a result of replacing all the occurences of a
// time (e.g. as a result of replacing all the occurrences of a
// particular string with another one) and that some of those calls
// don't require an XSL transformation, then we may end up in a case
// where pInput is not our current Content MathML equation anymore, in
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -599,7 +599,7 @@ void RawCellmlViewWidget::mathmlConversionDone(const QString &pContentMathml,
// Note: before setting the contents of our viewer, we need to make sure
// that pInput is still our current Content MathML equation. Indeed,
// say that updateViewer() gets called many times in a short period of
// time (e.g. as a result of replacing all the occurences of a
// time (e.g. as a result of replacing all the occurrences of a
// particular string with another one) and that some of those calls
// don't require an XSL transformation, then we may end up in a case
// where pInput is not our current Content MathML equation anymore, in
Expand Down
2 changes: 1 addition & 1 deletion src/plugins/solverinterface.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -72,7 +72,7 @@ void Solver::setProperties(const Properties &pProperties)

void Solver::emitError(const QString &pErrorMessage)
{
// Let people know that an error occured, but first reformat the error a
// Let people know that an error occurred, but first reformat the error a
// bit, if needed

QString errorMessage;
Expand Down
2 changes: 1 addition & 1 deletion src/plugins/widget/EditorWidget/src/editorwidget.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -497,7 +497,7 @@ void EditorWidget::selectAll()

void EditorWidget::highlightAll()
{
// Highlight all the occurences of the text, if any, in our editor
// Highlight all the occurrences of the text, if any, in our editor

mEditor->highlightAll();
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -273,7 +273,7 @@ void EditorWidgetEditorWidget::processAll(Action pAction)
|(mFindReplace->isCaseSensitive()?SCFIND_MATCHCASE:0)
|(mFindReplace->searchWholeWordsOnly()?SCFIND_WHOLEWORD:0)));

// Hihghlight/replace all the occurences of the text
// Hihghlight/replace all the occurrences of the text

const char *rawFindText = findText.constData();
int findTextLen = findText.length();
Expand Down Expand Up @@ -362,7 +362,7 @@ void EditorWidgetEditorWidget::processAll(Action pAction)

void EditorWidgetEditorWidget::highlightAll()
{
// Highlight all the occurences of the text
// Highlight all the occurrences of the text

processAll(Action::HighlightAll);
}
Expand All @@ -371,7 +371,7 @@ void EditorWidgetEditorWidget::highlightAll()

void EditorWidgetEditorWidget::replaceAll()
{
// Replace all the occurences of the text
// Replace all the occurrences of the text

processAll(Action::ReplaceAll);
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -480,7 +480,7 @@ void EditorWidgetFindReplaceWidget::replaceAndFindButtonClicked()

void EditorWidgetFindReplaceWidget::replaceAllButtonClicked()
{
// Let people know that we want to replace all the occurences of the text
// Let people know that we want to replace all the occurrences of the text

emit replaceAllRequested();
}
Expand Down
2 changes: 1 addition & 1 deletion src/tests/src/testsutils.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -199,7 +199,7 @@ int runCli(const QStringList &pArguments, QStringList &pOutput)
// - Making paths relative rather than absolute;
// - Replacing backslashes with forward slashes; and
// - Removing all occurrences of the CR character.
// Note: the idea is to be able to compare our output indepedent of where
// Note: the idea is to be able to compare our output independent of where
// the test was run from and of which operating system it was run
// on...

Expand Down

0 comments on commit 0ef1f35

Please sign in to comment.