-
Notifications
You must be signed in to change notification settings - Fork 8
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
hack for OSX #14
Comments
Hi John,
Thanks for the feedback. We recently released a new Beta version that
refactored the plugin to support the latest plugin mechanisms of VIM 8. I
presume you looked at the attached instructions in the GIT repository and
it did not work. You can actually change the function keys with a
configuration change without modifying the script
let g:marvim_store = '/usr/local/.marvim' " change store place.let
g:marvim_find_key = '<Space>' " change find key from <F2> to
'space'let g:marvim_store_key = 'ms' " change store key from <F3>
to 'ms'let g:marvim_register = 'c' " change used register from
'q' to 'c'let g:marvim_prefix = 0 " disable default syntax
based prefix
Out of curiosity would having a single file to work with (and source into
.vimrc) be easier. I am new to the plugin mechanism but I too would have
preferred if a single file was used for convenience but was not aware it
would work this way in the plugin directory.
Please do feel free to register more bugs in GIT as the purpose of the Beta
version is to get this feedback
thanks,
Chamindra de Silva
https://www.linkedin.com/in/chamindra |
http://chamindra-de-silva.blogspot.com
…On Mon, Nov 11, 2019 at 9:56 PM John Talbot ***@***.***> wrote:
I believe OSX is not supported. macvim does not have the ability to save
macros.
For marvim on Catalina, after changing the locations of the
autostart/marvim.vim file and plugin/marvim.vim file to match what the
paths looked up in $HOME/.vim by vim -v; it still did not work. I ended up
concatenating the two files and putting this in $HOME/.vim/plugin. I also
ended up using sed to change the Function keys as no matter what I did F3
kept bringing up expose. This is strictly a hack and you can close this
request. Here are the commands if you wish to publish the hack.
tar -xzf marvim.tar.gz
mkdir ~/.vim/plugin
cat marvim/autoload/marvim.vim marvim/plugin/marvim.vim >
~/.vim/plugin/marvim.vim
sed -e's/F2/F4/g' ~/.vim/plugin/marvim.vim
sed -e's/F3/F5/g' ~/.vim/plugin/marvim.vim
thanks for the great plugin,
John Talbot
***@***.***
—
You are receiving this because you are subscribed to this thread.
Reply to this email directly, view it on GitHub
<#14?email_source=notifications&email_token=ABTG6GYVHDM6IQS65LCQZX3QTHIJRA5CNFSM4JL3JZRKYY3PNVWWK3TUL52HS4DFUVEXG43VMWVGG33NNVSW45C7NFSM4HYRAZPQ>,
or unsubscribe
<https://github.com/notifications/unsubscribe-auth/ABTG6G5UNIFNQRXCLJG7LA3QTHIJRANCNFSM4JL3JZRA>
.
|
Hi Chamindra,
I will look into it further. Vim 8 does seem to have the ability to do a
start portion and then a main portion. Looking at the two though one just
contains Globals and the other the main stuff. The only reason I see for
this is possibly for another piece of code to alter the globals before the
main is loaded later. That would explain it all and if nothing else changes
the global variables, why it still works as one file.
I'll try it on other platforms and let you know and also do a little more
digging myself.
Certainly having just one file is easier and you get another platform out
of it. OSX just works, until it doesn't ;-)
ttfn,
John
On Tue, Nov 12, 2019 at 5:48 AM Chamindra de Silva <[email protected]>
wrote:
… Hi John,
Thanks for the feedback. We recently released a new Beta version that
refactored the plugin to support the latest plugin mechanisms of VIM 8. I
presume you looked at the attached instructions in the GIT repository and
it did not work. You can actually change the function keys with a
configuration change without modifying the script
let g:marvim_store = '/usr/local/.marvim' " change store place.let
g:marvim_find_key = '<Space>' " change find key from <F2> to
'space'let g:marvim_store_key = 'ms' " change store key from <F3>
to 'ms'let g:marvim_register = 'c' " change used register from
'q' to 'c'let g:marvim_prefix = 0 " disable default syntax
based prefix
Out of curiosity would having a single file to work with (and source into
.vimrc) be easier. I am new to the plugin mechanism but I too would have
preferred if a single file was used for convenience but was not aware it
would work this way in the plugin directory.
Please do feel free to register more bugs in GIT as the purpose of the Beta
version is to get this feedback
thanks,
Chamindra de Silva
https://www.linkedin.com/in/chamindra |
http://chamindra-de-silva.blogspot.com
On Mon, Nov 11, 2019 at 9:56 PM John Talbot ***@***.***>
wrote:
> I believe OSX is not supported. macvim does not have the ability to save
> macros.
> For marvim on Catalina, after changing the locations of the
> autostart/marvim.vim file and plugin/marvim.vim file to match what the
> paths looked up in $HOME/.vim by vim -v; it still did not work. I ended
up
> concatenating the two files and putting this in $HOME/.vim/plugin. I also
> ended up using sed to change the Function keys as no matter what I did F3
> kept bringing up expose. This is strictly a hack and you can close this
> request. Here are the commands if you wish to publish the hack.
>
> tar -xzf marvim.tar.gz
> mkdir ~/.vim/plugin
> cat marvim/autoload/marvim.vim marvim/plugin/marvim.vim >
> ~/.vim/plugin/marvim.vim
> sed -e's/F2/F4/g' ~/.vim/plugin/marvim.vim
> sed -e's/F3/F5/g' ~/.vim/plugin/marvim.vim
>
> thanks for the great plugin,
> John Talbot
> ***@***.***
>
> —
> You are receiving this because you are subscribed to this thread.
> Reply to this email directly, view it on GitHub
> <
#14?email_source=notifications&email_token=ABTG6GYVHDM6IQS65LCQZX3QTHIJRA5CNFSM4JL3JZRKYY3PNVWWK3TUL52HS4DFUVEXG43VMWVGG33NNVSW45C7NFSM4HYRAZPQ
>,
> or unsubscribe
> <
https://github.com/notifications/unsubscribe-auth/ABTG6G5UNIFNQRXCLJG7LA3QTHIJRANCNFSM4JL3JZRA
>
> .
>
—
You are receiving this because you authored the thread.
Reply to this email directly, view it on GitHub
<#14?email_source=notifications&email_token=ABSBCX52LGJ7OWM6D5K4R4TQTKCWLA5CNFSM4JL3JZRKYY3PNVWWK3TUL52HS4DFVREXG43VMVBW63LNMVXHJKTDN5WW2ZLOORPWSZGOEDZ2ZBI#issuecomment-552840325>,
or unsubscribe
<https://github.com/notifications/unsubscribe-auth/ABSBCX4Y6O3UHULABB6VSIDQTKCWLANCNFSM4JL3JZRA>
.
|
Hi,
So there are clearly things I did not know. Things work backwards than
what I thought. The auto load portion happens after the plug-in part for
the purpose of speeding up vim loading. You do not really have to do so,
it's just a nicety.
Though auto load is a nicety, how can your plugin read a file to remap F2
if it has not been loaded yet? Sort of a chicken and egg thing. Anyway,
I'm still looking.
Your plugin is really small, having it in one file would not kill anyone
for the extra nanosecond it takes to load, especially if it means the keys
would remapped and then be usable on OSX.
I'll keep you posted,
TTFN,
John
…On Tue, Nov 12, 2019 at 6:45 AM John Talbot ***@***.***> wrote:
Hi Chamindra,
I will look into it further. Vim 8 does seem to have the ability to do
a start portion and then a main portion. Looking at the two though one just
contains Globals and the other the main stuff. The only reason I see for
this is possibly for another piece of code to alter the globals before the
main is loaded later. That would explain it all and if nothing else changes
the global variables, why it still works as one file.
I'll try it on other platforms and let you know and also do a little
more digging myself.
Certainly having just one file is easier and you get another platform
out of it. OSX just works, until it doesn't ;-)
ttfn,
John
On Tue, Nov 12, 2019 at 5:48 AM Chamindra de Silva <
***@***.***> wrote:
> Hi John,
>
> Thanks for the feedback. We recently released a new Beta version that
> refactored the plugin to support the latest plugin mechanisms of VIM 8. I
> presume you looked at the attached instructions in the GIT repository and
> it did not work. You can actually change the function keys with a
> configuration change without modifying the script
>
> let g:marvim_store = '/usr/local/.marvim' " change store place.let
> g:marvim_find_key = '<Space>' " change find key from <F2> to
> 'space'let g:marvim_store_key = 'ms' " change store key from <F3>
> to 'ms'let g:marvim_register = 'c' " change used register from
> 'q' to 'c'let g:marvim_prefix = 0 " disable default syntax
> based prefix
>
>
> Out of curiosity would having a single file to work with (and source into
> .vimrc) be easier. I am new to the plugin mechanism but I too would have
> preferred if a single file was used for convenience but was not aware it
> would work this way in the plugin directory.
>
> Please do feel free to register more bugs in GIT as the purpose of the
> Beta
> version is to get this feedback
>
> thanks,
>
> Chamindra de Silva
> https://www.linkedin.com/in/chamindra |
> http://chamindra-de-silva.blogspot.com
>
>
> On Mon, Nov 11, 2019 at 9:56 PM John Talbot ***@***.***>
> wrote:
>
> > I believe OSX is not supported. macvim does not have the ability to save
> > macros.
> > For marvim on Catalina, after changing the locations of the
> > autostart/marvim.vim file and plugin/marvim.vim file to match what the
> > paths looked up in $HOME/.vim by vim -v; it still did not work. I ended
> up
> > concatenating the two files and putting this in $HOME/.vim/plugin. I
> also
> > ended up using sed to change the Function keys as no matter what I did
> F3
> > kept bringing up expose. This is strictly a hack and you can close this
> > request. Here are the commands if you wish to publish the hack.
> >
> > tar -xzf marvim.tar.gz
> > mkdir ~/.vim/plugin
> > cat marvim/autoload/marvim.vim marvim/plugin/marvim.vim >
> > ~/.vim/plugin/marvim.vim
> > sed -e's/F2/F4/g' ~/.vim/plugin/marvim.vim
> > sed -e's/F3/F5/g' ~/.vim/plugin/marvim.vim
> >
> > thanks for the great plugin,
> > John Talbot
> > ***@***.***
> >
> > —
> > You are receiving this because you are subscribed to this thread.
> > Reply to this email directly, view it on GitHub
> > <
> #14?email_source=notifications&email_token=ABTG6GYVHDM6IQS65LCQZX3QTHIJRA5CNFSM4JL3JZRKYY3PNVWWK3TUL52HS4DFUVEXG43VMWVGG33NNVSW45C7NFSM4HYRAZPQ
> >,
> > or unsubscribe
> > <
> https://github.com/notifications/unsubscribe-auth/ABTG6G5UNIFNQRXCLJG7LA3QTHIJRANCNFSM4JL3JZRA
> >
> > .
> >
>
> —
> You are receiving this because you authored the thread.
> Reply to this email directly, view it on GitHub
> <#14?email_source=notifications&email_token=ABSBCX52LGJ7OWM6D5K4R4TQTKCWLA5CNFSM4JL3JZRKYY3PNVWWK3TUL52HS4DFVREXG43VMVBW63LNMVXHJKTDN5WW2ZLOORPWSZGOEDZ2ZBI#issuecomment-552840325>,
> or unsubscribe
> <https://github.com/notifications/unsubscribe-auth/ABSBCX4Y6O3UHULABB6VSIDQTKCWLANCNFSM4JL3JZRA>
> .
>
|
I have figured out how to get your plugin to work out of the box under
OSX. The problem is of course that F2 and F3 are reserved under OSX for
mission control features. The only reason I got it to work was not the fact
that it was concatenated into one plugin file, but because I had remapped
the keys. The answer then is how to remap the keys. Here are all the steps
that I had to do to install your plugin under OSX.
mkdir $HOME/.vim/plugin
tar -xzf marvim.tar.gz -C $HOME/.vim/plugin
Add the following lines *EXACTLY* to your .vimrc
" Remap marvin keys
vnoremap <F5> : :norm@q<CR>
nnoremap <F5> : call marvim#search()<CR>
vnoremap <F6> y:call marvim#template_store()<CR>
nnoremap <F6> :call marvim#macro_store()<CR>
I had found these mappings by doing a ":map" from within vim on my working
setup and then rechecked it after installing your plugin from scratch to
see that it does work out of the box.
So that I believe is my final answer. While I did not check it under other
platforms, the fact that I did not alter your package and got it to work
under OSX, then this should be an acceptable solution. You could though
however ask them to edit the plugin itself to change the mapped keys as I
did.
Take care,
John
…On Tue, Nov 12, 2019 at 8:18 AM John Talbot ***@***.***> wrote:
Hi,
So there are clearly things I did not know. Things work backwards than
what I thought. The auto load portion happens after the plug-in part for
the purpose of speeding up vim loading. You do not really have to do so,
it's just a nicety.
Though auto load is a nicety, how can your plugin read a file to remap
F2 if it has not been loaded yet? Sort of a chicken and egg thing.
Anyway, I'm still looking.
Your plugin is really small, having it in one file would not kill
anyone for the extra nanosecond it takes to load, especially if it means
the keys would remapped and then be usable on OSX.
I'll keep you posted,
TTFN,
John
On Tue, Nov 12, 2019 at 6:45 AM John Talbot ***@***.***> wrote:
> Hi Chamindra,
>
> I will look into it further. Vim 8 does seem to have the ability to do
> a start portion and then a main portion. Looking at the two though one just
> contains Globals and the other the main stuff. The only reason I see for
> this is possibly for another piece of code to alter the globals before the
> main is loaded later. That would explain it all and if nothing else changes
> the global variables, why it still works as one file.
> I'll try it on other platforms and let you know and also do a little
> more digging myself.
>
> Certainly having just one file is easier and you get another platform
> out of it. OSX just works, until it doesn't ;-)
>
> ttfn,
> John
>
> On Tue, Nov 12, 2019 at 5:48 AM Chamindra de Silva <
> ***@***.***> wrote:
>
>> Hi John,
>>
>> Thanks for the feedback. We recently released a new Beta version that
>> refactored the plugin to support the latest plugin mechanisms of VIM 8. I
>> presume you looked at the attached instructions in the GIT repository and
>> it did not work. You can actually change the function keys with a
>> configuration change without modifying the script
>>
>> let g:marvim_store = '/usr/local/.marvim' " change store place.let
>> g:marvim_find_key = '<Space>' " change find key from <F2> to
>> 'space'let g:marvim_store_key = 'ms' " change store key from <F3>
>> to 'ms'let g:marvim_register = 'c' " change used register from
>> 'q' to 'c'let g:marvim_prefix = 0 " disable default syntax
>> based prefix
>>
>>
>> Out of curiosity would having a single file to work with (and source into
>> .vimrc) be easier. I am new to the plugin mechanism but I too would have
>> preferred if a single file was used for convenience but was not aware it
>> would work this way in the plugin directory.
>>
>> Please do feel free to register more bugs in GIT as the purpose of the
>> Beta
>> version is to get this feedback
>>
>> thanks,
>>
>> Chamindra de Silva
>> https://www.linkedin.com/in/chamindra |
>> http://chamindra-de-silva.blogspot.com
>>
>>
>> On Mon, Nov 11, 2019 at 9:56 PM John Talbot ***@***.***>
>> wrote:
>>
>> > I believe OSX is not supported. macvim does not have the ability to
>> save
>> > macros.
>> > For marvim on Catalina, after changing the locations of the
>> > autostart/marvim.vim file and plugin/marvim.vim file to match what the
>> > paths looked up in $HOME/.vim by vim -v; it still did not work. I
>> ended up
>> > concatenating the two files and putting this in $HOME/.vim/plugin. I
>> also
>> > ended up using sed to change the Function keys as no matter what I did
>> F3
>> > kept bringing up expose. This is strictly a hack and you can close this
>> > request. Here are the commands if you wish to publish the hack.
>> >
>> > tar -xzf marvim.tar.gz
>> > mkdir ~/.vim/plugin
>> > cat marvim/autoload/marvim.vim marvim/plugin/marvim.vim >
>> > ~/.vim/plugin/marvim.vim
>> > sed -e's/F2/F4/g' ~/.vim/plugin/marvim.vim
>> > sed -e's/F3/F5/g' ~/.vim/plugin/marvim.vim
>> >
>> > thanks for the great plugin,
>> > John Talbot
>> > ***@***.***
>> >
>> > —
>> > You are receiving this because you are subscribed to this thread.
>> > Reply to this email directly, view it on GitHub
>> > <
>> #14?email_source=notifications&email_token=ABTG6GYVHDM6IQS65LCQZX3QTHIJRA5CNFSM4JL3JZRKYY3PNVWWK3TUL52HS4DFUVEXG43VMWVGG33NNVSW45C7NFSM4HYRAZPQ
>> >,
>> > or unsubscribe
>> > <
>> https://github.com/notifications/unsubscribe-auth/ABTG6G5UNIFNQRXCLJG7LA3QTHIJRANCNFSM4JL3JZRA
>> >
>> > .
>> >
>>
>> —
>> You are receiving this because you authored the thread.
>> Reply to this email directly, view it on GitHub
>> <#14?email_source=notifications&email_token=ABSBCX52LGJ7OWM6D5K4R4TQTKCWLA5CNFSM4JL3JZRKYY3PNVWWK3TUL52HS4DFVREXG43VMVBW63LNMVXHJKTDN5WW2ZLOORPWSZGOEDZ2ZBI#issuecomment-552840325>,
>> or unsubscribe
>> <https://github.com/notifications/unsubscribe-auth/ABSBCX4Y6O3UHULABB6VSIDQTKCWLANCNFSM4JL3JZRA>
>> .
>>
>
|
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
I believe OSX is not supported. macvim does not have the ability to save macros.
For marvim on Catalina, after changing the locations of the autostart/marvim.vim file and plugin/marvim.vim file to match what the paths looked up in $HOME/.vim by vim -v; it still did not work. I ended up concatenating the two files and putting this in $HOME/.vim/plugin. I also ended up using sed to change the Function keys as no matter what I did F3 kept bringing up expose. This is strictly a hack and you can close this request. Here are the commands if you wish to publish the hack.
tar -xzf marvim.tar.gz
mkdir ~/.vim/plugin
cat marvim/autoload/marvim.vim marvim/plugin/marvim.vim > ~/.vim/plugin/marvim.vim
sed -e's/F2/F4/g' ~/.vim/plugin/marvim.vim
sed -e's/F3/F5/g' ~/.vim/plugin/marvim.vim
thanks for the great plugin,
John Talbot
[email protected]
The text was updated successfully, but these errors were encountered: