Skip to content

Commit

Permalink
Merge pull request #13 from MetRonnie/suite-to-flow
Browse files Browse the repository at this point in the history
Change suite.rc -> flow.cylc
  • Loading branch information
oliver-sanders authored Aug 20, 2020
2 parents 504abaf + be0f8bf commit e40ae6d
Show file tree
Hide file tree
Showing 19 changed files with 4 additions and 3 deletions.
4 changes: 2 additions & 2 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@

![test](https://github.com/cylc/cylc-textmate-grammar/workflows/test/badge.svg?branch=master&event=push)

This repository provides a TextMate grammar for Cylc workflow configuration (`suite.rc`) files, enabling syntax highlighting and other features.
This repository provides a TextMate grammar for Cylc workflow configuration (`suite.rc` and `.cylc`) files, enabling syntax highlighting and other features.

`cylc.tmLanguage.json` is the grammar file used by plugins for editors:
- VSCode - [cylc/vscode-cylc](https://github.com/cylc/vscode-cylc)
Expand Down Expand Up @@ -147,7 +147,7 @@ npx eslint src/ lib/
```
#### Unit tests
We're using [vscode-tmgrammar-test](https://github.com/PanAeon/vscode-tmgrammar-test) for testing the textmate grammar. Test files reside in the `/tests` directory. These are essentially suite.rc files that are annotated with comments (filenames must match pattern `suite*.rc` or `suite*.rc.*`). The comments detail what the expected scopes of the test line are. The comments are read in by vscode-tmgrammar-test and compared to the actual applied scopes. An example test might be:
We're using [vscode-tmgrammar-test](https://github.com/PanAeon/vscode-tmgrammar-test) for testing the textmate grammar. Test files reside in the `/tests` directory. These are essentially Cylc workflow files that are annotated with comments. The comments detail what the expected scopes of the test line are. The comments are read in by vscode-tmgrammar-test and compared to the actual applied scopes. An example test might be:
```ini
foo = bar
# ^^^ variable.other.key.cylc
Expand Down
1 change: 1 addition & 0 deletions cylc.tmLanguage.json
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,7 @@
"suite.rc",
"suite.rc.processed",
"cylc",
"cylc.processed",
"flow.rc",
"flow-tests.rc"
],
Expand Down
File renamed without changes.
File renamed without changes.
File renamed without changes.
2 changes: 1 addition & 1 deletion src/cylc.tmLanguage.js
Original file line number Diff line number Diff line change
Expand Up @@ -787,7 +787,7 @@ class Jinja2Comment {
exports.tmLanguage = {
scopeName: 'source.cylc',
$schema: 'https://raw.githubusercontent.com/martinring/tmlanguage/master/tmlanguage.json',
fileTypes: ['suite.rc', 'suite.rc.processed', 'cylc', 'flow.rc', 'flow-tests.rc'],
fileTypes: ['suite.rc', 'suite.rc.processed', 'cylc', 'cylc.processed', 'flow.rc', 'flow-tests.rc'],
name: 'cylc',
patterns: [
{include: '#comments'},
Expand Down
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.

0 comments on commit e40ae6d

Please sign in to comment.