How can I configure vim to use the same syntax highlighting for Thor as it does for ruby? When I'm editing a *.thor file, I can use :set syntax=ruby, which works, but is not permanent. Is there a way to do something in my .vimrc file to conditionally set the syntax to ruby if it's *.thor? Maybe create a thor syntax file and inherit from ruby?
Ruby-like Syntax Highlighting in VIM for Thor
1.6k Views Asked by Peter Brown At
2
There are 2 best solutions below
Related Questions in RUBY
- how to integrate cashfree payment gateway in ruby on rails project
- RSpec Capybara throwing Selenium error when trying to click a button with browser confirm
- Duplicate GET requests - Rails & Heroku
- convert csv file with json data inside to a column, rows table in 2nd csv file
- Installing dependencies from a gemspec file
- Verifying Google Identity OAuth2 token with Ruby
- Java code of AES/GCM/NoPadding encryption algorithm with authentication tag
- How to fix error in model with gem lockbox
- Cannot install Ruby Gem on Window
- use logstash filter ,aes gcm encrypted in ruby,but cannot decrypted in java
- In Rails 7, what is the right ActiveRecord callback to use if I need to prevent (or rollback) persistance on error?
- How can I go through an array and still remove elements from it
- Nokogiri only returning 5 results
- How do I get the fullscreen mode in firefox?
- undefined group option when using branch reset group regex in Ruby
Related Questions in VIM
- vim python omnifunc not working some modules
- Alias does not take effect when I use Vim to execute external commands
- Executing just multiple python lines in VIM
- Is there a Vim-eqsue way to sequentially copy numbers?
- How do I run a Python program in the Vim editor without closing it?
- Vim 8 - How do I re-number my list after reordering the list - manually or automatically?
- vim: indent next line more than the current
- Unicode character ſ is matched as itself and as 's.'
- Nvim with prose: how to set up proper `autoformat` line-wrapping
- Syntax highlighting of nested braces in vim
- Is there a way to flip the bit under your cursor in (n)vim?
- Vimscript function for replacing the visually selected buffer in nvim
- no console after using :wq in vim
- Convert entire (Python) file from 2-space indent to 4-space indent
- Prepend text to a different file from within Vim
Related Questions in SYNTAX-HIGHLIGHTING
- In VScode, How to custom the PHP heredoc tag "HTML" to others?
- How to highlight comments in several different colors in CLion?
- To enable syntax highlighting with color for JBehave stories in Eclipse
- Implement Highlight.js in TextArea
- How do I turn off syntax highlighting in micro text editor?
- How to fix broken syntax highlight in Visual Studio 2022 UI (different colors)
- Visual Studio 2022 - Strange C++ Coloring/Highlighting
- syntax highlighting in Visual Studio 2022 in cshtml files not working
- Vscode shows fake import errors when saving a file | Java
- How to change background color of selected code
- treesitter/highlighter issues with LaTeX formula in Markdown files, and any other language
- C language server on Zed for SDL
- Vue 3.4 same-name shorthand vs-code support
- Syntax highlighting not applied to PascalCase-named files
- VScode Latex: Disable syntax highlighting for a range of lines
Related Questions in THOR
- Aliases for limited_options in Thor
- Thor third level subcommand not represented correctly in output
- Why is an outdated version of a Ruby script used when running Ruby from a Subprocess in Python?
- How to copy directory of *.tt files with thor?
- Rails new command fails if -m template is applied: "NoMethodError: private method `open' called for URI:Module"
- Using ksdiff as THOR_MERGE tool in zshell
- Thor gem copying an empty directory isn't working
- how to generate a migration with custom generator
- Creating nested subcommands using Thor
- How to get an organizational structure of commands, subcommands, options of a Ruby class that inherits from Thor?
- Is there a way to add hooks to a Thor class in order to run code before/after all commands?
- Fixing Rails generator issues: calling same generator twice no-ops and exits 0 without running 2nd generator
- Middleman Permission denied while installing thor (0.20.3), and Bundler cannot continue
- thor::Animator playing only one frame
- How can I mock a Ruby "require" statement in RSpec?
Related Questions in VIM-SYNTAX-HIGHLIGHTING
- Syntax highlighting of nested braces in vim
- How do I fix the current line color using solarized vim dark mode using Termdebug?
- neovim: setting syntax highlight popup box?
- How to configure highlighting in Vim?
- Why is my region in my Neovim Syntax file unresponsive?
- How to turn off Auto highlight text in Vim editor?
- Can I cascade vim syntax highlighting rules like in nano?
- I need some help making a regex search
- My conceal options are not loading in vim
- Is there a way in vim to change search text highlight color in visual mode only?
- vim syntax highlighting: region that starts with "#" and end with either "#" or end of line
- How to set Neovim+SpaceVim to syntax highlight Hugo (markdown, TOML, Go+HTML, CSS) files?
- Semantic hilight function names in vim
- How to do syntax highlighting for a keyword containing a period (.)?
- create syntax checker vim plugin for a new Programming language
Trending Questions
- UIImageView Frame Doesn't Reflect Constraints
- Is it possible to use adb commands to click on a view by finding its ID?
- How to create a new web character symbol recognizable by html/javascript?
- Why isn't my CSS3 animation smooth in Google Chrome (but very smooth on other browsers)?
- Heap Gives Page Fault
- Connect ffmpeg to Visual Studio 2008
- Both Object- and ValueAnimator jumps when Duration is set above API LvL 24
- How to avoid default initialization of objects in std::vector?
- second argument of the command line arguments in a format other than char** argv or char* argv[]
- How to improve efficiency of algorithm which generates next lexicographic permutation?
- Navigating to the another actvity app getting crash in android
- How to read the particular message format in android and store in sqlite database?
- Resetting inventory status after order is cancelled
- Efficiently compute powers of X in SSE/AVX
- Insert into an external database using ajax and php : POST 500 (Internal Server Error)
Popular # Hahtags
Popular Questions
- How do I undo the most recent local commits in Git?
- How can I remove a specific item from an array in JavaScript?
- How do I delete a Git branch locally and remotely?
- Find all files containing a specific text (string) on Linux?
- How do I revert a Git repository to a previous commit?
- How do I create an HTML button that acts like a link?
- How do I check out a remote Git branch?
- How do I force "git pull" to overwrite local files?
- How do I list all files of a directory?
- How to check whether a string contains a substring in JavaScript?
- How do I redirect to another webpage?
- How can I iterate over rows in a Pandas DataFrame?
- How do I convert a String to an int in Java?
- Does Python have a string 'contains' substring method?
- How do I check if a string contains a specific word?
I think should suffice... maybe this if you want to customize it later:
and copy ruby .vim syntax highlight file to
$HOME/.vim/syntax/thor.vim