Skip to content

Commit

Permalink
Merge pull request #275 from douglasjacobsen/typo_fix
Browse files Browse the repository at this point in the history
Add a typos config file to override incorrect typos
  • Loading branch information
rfbgo authored Oct 5, 2023
2 parents f52b04a + a97eeb6 commit c2cbd07
Show file tree
Hide file tree
Showing 12 changed files with 32 additions and 20 deletions.
3 changes: 2 additions & 1 deletion .github/workflows/spelling.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -15,4 +15,5 @@ jobs:
- name: Check Spelling
uses: crate-ci/typos@7ad296c72fa8265059cc03d1eda562fbdfcd6df2 # v1.9.0
with:
files: ./lib ./examples ./share ./bin ./etc ./README.md
files: ./lib/ramble/ramble ./lib/ramble/docs ./examples ./share ./bin ./etc ./README.md
config: ./.typos.toml
23 changes: 16 additions & 7 deletions .typos.toml
Original file line number Diff line number Diff line change
@@ -1,11 +1,20 @@
# do not check external or spack
[files]
extend-exclude = [
"lib/ramble/llnl/*",
"lib/ramble/spack/*",
"lib/ramble/external/*",
[default]
extend-ignore-identifiers-re = [
# *sigh* this just isn't worth the cost of fixing
"AttributeID.*Supress.*",
]

[default.extend-identifiers]
# *sigh* this just isn't worth the cost of fixing
AttributeIDSupressMenu = "AttributeIDSupressMenu"


[default.extend-words]
cachable = "cachable"
fom = "fom"
foms = "foms"
FO = "FO"
FOM = "FOM"
FOMs = "FOMs"
namd = "namd"
cachable = "cachable"
clen = "clen"
8 changes: 4 additions & 4 deletions lib/ramble/docs/workspace.rst
Original file line number Diff line number Diff line change
Expand Up @@ -147,7 +147,7 @@ Concretizing a Workspace

The software definitions in a workspace need to be concretized before the
workspace can be set up. To have Ramble pull software definitions from the
appliaction definition files, one can use:
application definition files, one can use:

.. code-block:: console
Expand Down Expand Up @@ -280,9 +280,9 @@ it generates.

These can be used to modify the behavior of Spack environments generated by Ramble.

^^^^^^^^^^^^^^^^^^^^^^^^^^^
Workspace Invetory and Hash
^^^^^^^^^^^^^^^^^^^^^^^^^^^
^^^^^^^^^^^^^^^^^^^^^^^^^^^^
Workspace Inventory and Hash
^^^^^^^^^^^^^^^^^^^^^^^^^^^^

Setting up a workspace will create inventory files that can be used to identify
which aspects of experiments or workspaces change between different
Expand Down
2 changes: 1 addition & 1 deletion lib/ramble/docs/workspace_config.rst
Original file line number Diff line number Diff line change
Expand Up @@ -672,7 +672,7 @@ Ramble requires the following variables to be defined:
Generated Variables:
""""""""""""""""""""

Ramble automatically generates definitions for the following varialbes:
Ramble automatically generates definitions for the following variables:

* ``application_name`` - Set to the name of the application
* ``workload_name`` - Set to the name of the workload within the application
Expand Down
2 changes: 2 additions & 0 deletions lib/ramble/ramble/application.py
Original file line number Diff line number Diff line change
Expand Up @@ -1205,6 +1205,7 @@ def format_context(context_match, context_format):

with open(file, 'r') as f:
for line in f.readlines():
tty.debug(f'Line: {line}')

for criteria in file_conf['success_criteria']:
tty.debug('Looking for criteria %s' % criteria)
Expand All @@ -1230,6 +1231,7 @@ def format_context(context_match, context_format):
fom_values[context_name] = {}

for fom in file_conf['foms']:
tty.debug(f' Testing for fom {fom}')
fom_conf = foms[fom]
fom_match = fom_conf['regex'].match(line)

Expand Down
2 changes: 1 addition & 1 deletion lib/ramble/ramble/cmd/repo.py
Original file line number Diff line number Diff line change
Expand Up @@ -180,7 +180,7 @@ def repo_list(args):
continue

if sys.stdout.isatty():
msg = f"{len(repos)} {obj_type.name} repositor"
msg = f"{len(repos)} {obj_type.name} repository"
msg += "y." if len(repos) == 1 else "ies."
tty.msg(msg)

Expand Down
2 changes: 1 addition & 1 deletion lib/ramble/ramble/test/cmd/config.py
Original file line number Diff line number Diff line change
Expand Up @@ -196,7 +196,7 @@ def test_merged_success_criteria_section(mock_low_high_config):
file: '{log_file}'"""


def test_merged_appliactions_section(mock_low_high_config):
def test_merged_applications_section(mock_low_high_config):
low_path = mock_low_high_config.scopes['low'].path
high_path = mock_low_high_config.scopes['high'].path

Expand Down
2 changes: 1 addition & 1 deletion lib/ramble/ramble/test/conftest.py
Original file line number Diff line number Diff line change
Expand Up @@ -95,7 +95,7 @@ def working_env():
yield
# os.environ = saved_env doesn't work
# it causes module_parsing::test_module_function to fail
# when it's run after any test using this fixutre
# when it's run after any test using this fixture
os.environ.clear()
os.environ.update(saved_env)

Expand Down
2 changes: 1 addition & 1 deletion lib/ramble/ramble/util/naming.py
Original file line number Diff line number Diff line change
Expand Up @@ -40,7 +40,7 @@ def mod_to_class(mod_name):
* Module and package names use lowercase_with_underscores.
* Class names use the CapWords convention.
Regular source code follows these convetions. Ramble is a bit
Regular source code follows these conventions. Ramble is a bit
more liberal with its Application names:
* They can contain '-' as well as '_', but cannot start with '-'.
Expand Down
2 changes: 1 addition & 1 deletion share/ramble/bash/ramble-completion.in
Original file line number Diff line number Diff line change
Expand Up @@ -76,7 +76,7 @@ _bash_completion_ramble() {
local COMP_CWORD_NO_FLAGS=$((${#COMP_WORDS_NO_FLAGS[@]} - 1))

# There is no guarantee that the cursor is at the end of the command line
# when tab completion is envoked. For example, in the following situation:
# when tab completion is invoked. For example, in the following situation:
# `ramble -d [] install`
# if the user presses the TAB key, a list of valid flags should be listed.
# Note that we cannot simply ignore everything after the cursor. In the
Expand Down
2 changes: 1 addition & 1 deletion share/ramble/ramble-completion.bash
Original file line number Diff line number Diff line change
Expand Up @@ -76,7 +76,7 @@ _bash_completion_ramble() {
local COMP_CWORD_NO_FLAGS=$((${#COMP_WORDS_NO_FLAGS[@]} - 1))

# There is no guarantee that the cursor is at the end of the command line
# when tab completion is envoked. For example, in the following situation:
# when tab completion is invoked. For example, in the following situation:
# `ramble -d [] install`
# if the user presses the TAB key, a list of valid flags should be listed.
# Note that we cannot simply ignore everything after the cursor. In the
Expand Down
2 changes: 1 addition & 1 deletion share/ramble/setup-env.fish
Original file line number Diff line number Diff line change
Expand Up @@ -246,7 +246,7 @@ end



function match_flag -d "checks all combinations of flags ocurring inside of a string"
function match_flag -d "checks all combinations of flags occurring inside of a string"

# Remove leading and trailing spaces -- but we need to insert a "guard" (x)
# so that eg. `string trim -h` doesn't trigger the help string for `string trim`
Expand Down

0 comments on commit c2cbd07

Please sign in to comment.