mkdir -p ~/.vim/{ftdetect,indent,syntax} && for d in ftdetect indent syntax ; do wget --no-check-certificate -O ~/.vim/$d/scala.vim https://raw.githubusercontent.com/derekwyatt/vim-scala/master/syntax/scala.vim; doneUpdate
Here is a solution using cURL submitted by Joe:
mkdir -p ~/.vim/{ftdetect,indent,syntax} && for d in ftdetect indent syntax ; do curl -o ~/.vim/$d/scala.vim https://raw.githubusercontent.com/derekwyatt/vim-scala/master/syntax/scala.vim; done
Thanks bro, works saved me some work!
ReplyDeleteGood!
ReplyDeleteGood stuff, thank you!
ReplyDeleteGreat, thanks!
ReplyDeleteSubstituting cURL:
ReplyDeletemkdir -p ~/.vim/{ftdetect,indent,syntax} && for d in ftdetect indent syntax ; do curl -o ~/.vim/$d/scala.vim https://raw.github.com/scala/scala-dist/master/tool-support/src/vim/$d/scala.vim; done
Thanks for contributing!
DeleteAwesome! Thanks!
ReplyDeleteThanks!
ReplyDeletelove this. thanks !
ReplyDeleteI can use the 5 minutes I gained getting Scala syntax highlighting from this post to tell you how much I like it :). But seriously, thanks! I know I'll use it again on some other machine ... somewhere.
ReplyDeleteNice work Bruce. (hope all is well)
ReplyDeleteThanks, that saved me a lot of time! I had to change the url to `https://raw.githubusercontent.com` to actually be able to download the files (I'm guessing that Github changed it recently, in which case you might want to update it in your post as well)
ReplyDeleteThank you for this great solution!
ReplyDeletethanks :D
ReplyDeleteThis comment has been removed by the author.
ReplyDeleteupdated url:
ReplyDeletemkdir -p ~/.vim/{ftdetect,indent,syntax} && for d in ftdetect indent syntax ; do curl -o ~/.vim/$d/scala.vim https://raw.githubusercontent.com/scala/scala-dist/master/tool-support/src/vim/$d/scala.vim; done
This is a quick way, but Vundle or Pathogen would be a better approach.
ReplyDeleteIf you are interested I recently wrote an article about programming Scala in Vim - http://lauris.github.io/vim/2014/08/21/scala-in-vim/
thanks a lot. very nice
ReplyDeletePerfect! Thank you
ReplyDeleteWorks great Thanks
ReplyDeleteI used the above bash command on my MacBook pro terminal and it executed successfully. After that, $vi test.scala and types a few scala statements but I do not see the syntax highlighted. Am I missing something?
ReplyDeleteDo you have syntax highlighting enabled in Vim? Did you manually check for the correct directories and files after running the command? (~/.vim/ftdetect/ ~/.vim/indent and ~/.vim/syntax)
DeleteThanks Bruce. I did check for these directories. But it works now.
ReplyDeleteIt no longer works. Here is an update:
ReplyDeletemkdir -p ~/.vim/{ftdetect,indent,syntax} && for d in ftdetect indent syntax ; do wget --no-check-certificate -O ~/.vim/$d/scala.vim https://raw.githubusercontent.com/derekwyatt/vim-scala/master/syntax/scala.vim; done
Thank you, Arun!
DeleteJust amazing ^_^
ReplyDeleteSaved me some time, thanks!
ReplyDeletethe kudos keep coming! Thanks for putting this together, Bruce, and for keeping it updated, Arun. cheers!
ReplyDeleteThanks !
ReplyDeleteImpressed, I am.
ReplyDeleteGreat! Thanks
ReplyDeleteExcelente! Gracias.
ReplyDeleteThanks man! helped me a lot :)
ReplyDeleteAwesome script. I will not have to go out of my terminal now.
ReplyDelete