diff --git a/.gitmodules b/.gitmodules index 1aa4e352..1bd960b4 100644 --- a/.gitmodules +++ b/.gitmodules @@ -883,3 +883,6 @@ [submodule "vendor/grammars/atom-language-julia"] path = vendor/grammars/atom-language-julia url = https://github.com/JuliaEditorSupport/atom-language-julia +[submodule "vendor/grammars/language-cwl"] + path = vendor/grammars/language-cwl + url = https://github.com/manabuishii/language-cwl diff --git a/grammars.yml b/grammars.yml index a537b54e..8f008d85 100755 --- a/grammars.yml +++ b/grammars.yml @@ -387,6 +387,8 @@ vendor/grammars/language-csound: - source.csound-score vendor/grammars/language-css: - source.css +vendor/grammars/language-cwl: +- source.cwl vendor/grammars/language-emacs-lisp: - source.emacs.lisp vendor/grammars/language-fontforge: diff --git a/lib/linguist/languages.yml b/lib/linguist/languages.yml index 25a4962e..3c5203a2 100755 --- a/lib/linguist/languages.yml +++ b/lib/linguist/languages.yml @@ -807,6 +807,19 @@ Common Lisp: codemirror_mode: commonlisp codemirror_mime_type: text/x-common-lisp language_id: 66 +Common Workflow Language: + alias: cwl + type: programming + ace_mode: yaml + codemirror_mode: yaml + codemirror_mime_type: text/x-yaml + extensions: + - ".cwl" + interpreters: + - cwl-runner + color: "#B5314C" + tm_scope: source.cwl + language_id: 988547172 Component Pascal: type: programming color: "#B0CE4E" diff --git a/samples/Common Workflow Language/trunk-peak-score.cwl b/samples/Common Workflow Language/trunk-peak-score.cwl new file mode 100644 index 00000000..eabe5496 --- /dev/null +++ b/samples/Common Workflow Language/trunk-peak-score.cwl @@ -0,0 +1,36 @@ +#!/usr/bin/env cwl-runner +# Originally from +# https://github.com/Duke-GCB/GGR-cwl/blob/54e897263a702ff1074c8ac814b4bf7205d140dd/utils/trunk-peak-score.cwl +# Released under the MIT License: +# https://github.com/Duke-GCB/GGR-cwl/blob/54e897263a702ff1074c8ac814b4bf7205d140dd/LICENSE +# Converted to CWL v1.0 syntax using +# https://github.com/common-workflow-language/cwl-upgrader +# and polished by Michael R. Crusoe +# All modifications also released under the MIT License +cwlVersion: v1.0 +class: CommandLineTool +doc: Trunk scores in ENCODE bed6+4 files + +hints: + DockerRequirement: + dockerPull: dukegcb/workflow-utils + +inputs: + peaks: + type: File + sep: + type: string + default: \t + +outputs: + trunked_scores_peaks: + type: stdout + +baseCommand: awk + +arguments: +- -F $(inputs.sep) +- BEGIN{OFS=FS}$5>1000{$5=1000}{print} +- $(inputs.peaks.path) + +stdout: $(inputs.peaks.nameroot).trunked_scores$(inputs.peaks.nameext) diff --git a/vendor/README.md b/vendor/README.md index c9b79e09..ec7d5580 100644 --- a/vendor/README.md +++ b/vendor/README.md @@ -70,6 +70,7 @@ This is a list of grammars that Linguist selects to provide syntax highlighting - **ColdFusion CFC:** [SublimeText/ColdFusion](https://github.com/SublimeText/ColdFusion) - **COLLADA:** [textmate/xml.tmbundle](https://github.com/textmate/xml.tmbundle) - **Common Lisp:** [textmate/lisp.tmbundle](https://github.com/textmate/lisp.tmbundle) +- **Common Workflow Language:** [manabuishii/language-cwl](https://github.com/manabuishii/language-cwl) - **Component Pascal:** [textmate/pascal.tmbundle](https://github.com/textmate/pascal.tmbundle) - **Cool:** [anunayk/cool-tmbundle](https://github.com/anunayk/cool-tmbundle) - **Coq:** [mkolosick/Sublime-Coq](https://github.com/mkolosick/Sublime-Coq) diff --git a/vendor/grammars/language-cwl b/vendor/grammars/language-cwl new file mode 160000 index 00000000..f2ca346c --- /dev/null +++ b/vendor/grammars/language-cwl @@ -0,0 +1 @@ +Subproject commit f2ca346c91bddd7893a88df63eb835843f69da60 diff --git a/vendor/licenses/grammar/language-cwl.txt b/vendor/licenses/grammar/language-cwl.txt new file mode 100644 index 00000000..a0d78479 --- /dev/null +++ b/vendor/licenses/grammar/language-cwl.txt @@ -0,0 +1,26 @@ +--- +type: grammar +name: language-cwl +license: mit +--- +MIT License + +Copyright (c) 2017 Manabu Ishii RIKEN Bioinformatics Research Unit + +Permission is hereby granted, free of charge, to any person obtaining a copy +of this software and associated documentation files (the "Software"), to deal +in the Software without restriction, including without limitation the rights +to use, copy, modify, merge, publish, distribute, sublicense, and/or sell +copies of the Software, and to permit persons to whom the Software is +furnished to do so, subject to the following conditions: + +The above copyright notice and this permission notice shall be included in all +copies or substantial portions of the Software. + +THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR +IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, +FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE +AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER +LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, +OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE +SOFTWARE.