Change default settings in MacVim
509
Line numbers:
:set number
Top toolbar deactivated:
:set guioptions-=T
Auto-indenting activated:
:filetype indent on
Be aware that you can turn off the menu bar as well, see ":help 'guioptions'
".
Also, you may want to do ":filetype indent plugin on
" as well as ":syntax on
". See ":help :filetype
".
Related videos on Youtube
Author by
The Codeanaught
Updated on September 17, 2022Comments
-
The Codeanaught over 1 year
I have created a really cool Python program that I want all of my friends to try out. I really want to put the running code onto a website so people can try it all around the world. Is it possible to run Python code on a HTML page? If so, how?
-
mjrider over 11 yearsim trying to follow this ..but I dont know if there IS a ~/.gvimrc file ... at least I dont have one... do I create one when I want to change settings like this? or am I doing something wrong
-
MattDMo over 9 yearsYou can't run Python in a browser without Python being installed on the user's system.
-
therealrootuser over 9 years@MattDMo -- I would beg to differ, though I would agree that strictly speaking the browser itself cannot directly interpret python code unless it is installed on the local machine. However, there are several options for sharing runnable python code online.
-
-
garyjohn about 13 yearsWhether
:filetype indent on
is sufficient depends on what AeroCross means by "Auto-indenting". He probably wants to use:set autoindent
as well to have that option enabled for files such as plain text and configuration files. -
Sabarinathan Jayakodi about 13 yearsThis is exactly what I was looking for (both post and comment). I just wanted to know though, where did you find those settings? I did a little research and I couldn't find those directives (such as guioptions).
-
Heptite about 13 years@AeroCross: I suggest doing a raw ":help" and familiarizing yourself with how the help system works, including the notation for getting help on various things, such as using a single-quote at the beginning of option names. The full reference on what options are available is in ":help options.txt". A briefer quick-reference for options is available in ":help Q_op".
-
Heptite about 13 years@AeroCross: There's also the Vim user's manual, available by doing ":help usr_toc.txt".
-
Sabarinathan Jayakodi about 13 yearsI didn't know any of that, thank you so much for the information. Vim really has a steep learning curve, and it's not too friendly at the beggining, so I'll need a LOT of patience for this to workout - and of couse, superuser.com and kind people like you.
-
Jon Clements over 9 yearsIt's 2014 - WSGI is much preferred (and has been for donkey's years now) over CGI for Python.
-
Sylvain Leroux over 9 yearsThis is an interesting solution. As you seems to know that product, could you elaborate a little bit more ? Does it really run in the browser, or is Python code somehow send to a server for evaluation ? Is it free/opensource ? Does that support Python 2, Python 3, or both ?
-
therealrootuser over 9 years@SylvainLeroux I've only used this service a few times, but I believe that the code is sent to the server for evaluation. It definitely supports Python 2.x, not sure on Python 3. I don't think it is opensource, although it is free (costwise). For a one off "cool script" it will probably suffice.