LinuxQuestions.org
Help answer threads with 0 replies.
Home Forums Tutorials Articles Register
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Distributions > Slackware
User Name
Password
Slackware This Forum is for the discussion of Slackware Linux.

Notices


Reply
  Search this Thread
Old 04-14-2016, 03:58 PM   #1
sigint-ninja
Member
 
Registered: Feb 2011
Location: Republic Of Ireland
Distribution: Debian,Centos,Slackware
Posts: 508

Rep: Reputation: 29
add python3 feature to vim on slackware


hi guys,

i finally got the correct version of python i want to run installed on my slackware system

i found a good article on vim:
https://realpython.com/blog/python/v...ade-in-heaven/

in the guide it asks you to run
vim --version

it told me to look for vim 7.4 to show its installed...which it obviously is

but under features python has + but python 3 has -
what do i have to do to enable python 3 in vim?

i was reading that vim needs to be recompiled...is this true? or is there another/better way?
 
Old 04-15-2016, 12:42 AM   #2
grail
LQ Guru
 
Registered: Sep 2009
Location: Perth
Distribution: Manjaro
Posts: 10,007

Rep: Reputation: 3191Reputation: 3191Reputation: 3191Reputation: 3191Reputation: 3191Reputation: 3191Reputation: 3191Reputation: 3191Reputation: 3191Reputation: 3191Reputation: 3191
Have you tried reinstalling vim now that you have python3 installed? If vim was installed prior then the install of vim would have noted that python3 was unavailable and hence
excluded the plugin.
 
Old 04-15-2016, 06:28 AM   #3
sigint-ninja
Member
 
Registered: Feb 2011
Location: Republic Of Ireland
Distribution: Debian,Centos,Slackware
Posts: 508

Original Poster
Rep: Reputation: 29
Will try that...thanks
 
Old 04-15-2016, 11:42 AM   #4
K4rolis
LQ Newbie
 
Registered: Jan 2016
Posts: 23

Rep: Reputation: Disabled
Not going to work - it's a compile-time option. You'll want to recompile vim with python3 interpreter enabled (you can just modify the official slackbuild). Sorry, cannot help more than that - haven't tried it myself.
 
Old 04-15-2016, 11:42 AM   #5
dugan
LQ Guru
 
Registered: Nov 2003
Location: Canada
Distribution: distro hopper
Posts: 11,225

Rep: Reputation: 5320Reputation: 5320Reputation: 5320Reputation: 5320Reputation: 5320Reputation: 5320Reputation: 5320Reputation: 5320Reputation: 5320Reputation: 5320Reputation: 5320
What do you need vim to be built against Python 3 for? Is there a specific vim plugin that you want to use, that requires Python 3?

If you just want write Python 3 code with vim, you don't need to rebuild vim for that.

Last edited by dugan; 04-15-2016 at 04:00 PM.
 
Old 04-15-2016, 05:39 PM   #6
sigint-ninja
Member
 
Registered: Feb 2011
Location: Republic Of Ireland
Distribution: Debian,Centos,Slackware
Posts: 508

Original Poster
Rep: Reputation: 29
yes dugan your right...it didnt work
trying to google can only find solutions for ubuntu and debian

dont have a clue
 
Old 04-15-2016, 05:52 PM   #7
sigint-ninja
Member
 
Registered: Feb 2011
Location: Republic Of Ireland
Distribution: Debian,Centos,Slackware
Posts: 508

Original Poster
Rep: Reputation: 29
what file do i download from here to configure and install vim?

https://github.com/akionux/slackbuil.../source/ap/vim
 
Old 04-15-2016, 06:35 PM   #8
K4rolis
LQ Newbie
 
Registered: Jan 2016
Posts: 23

Rep: Reputation: Disabled
You might want to check this.

EDIT: For slackware-current (as an example), you'll find everything you need (including vim source) here. I'm not sure whether you need to rebuild vim-gvim, as far as I understand you shouldn't need to (though I might be wrong on this one, you might need to just try it and see).

Last edited by K4rolis; 04-15-2016 at 06:40 PM.
 
Old 04-16-2016, 02:52 PM   #9
sigint-ninja
Member
 
Registered: Feb 2011
Location: Republic Of Ireland
Distribution: Debian,Centos,Slackware
Posts: 508

Original Poster
Rep: Reputation: 29
i found by starting my script in vim with

#!/usr/local/bin/python3.4

im actually able to write python3 scripts via vim, and run them

Last edited by sigint-ninja; 04-16-2016 at 02:55 PM.
 
  


Reply



Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
Vim xterm_clipboard feature oldfolio Slackware 5 04-16-2008 09:14 PM
Vim's new feature... ;) pwc101 General 7 03-29-2007 04:37 AM
Add GUI feature, how to? sateeshgalla Programming 1 09-15-2005 12:09 PM
how to Add GUI feature to Target board sateeshgalla Linux - General 1 09-14-2005 03:34 PM
How do I add a timeout feature to this code? Dr Twox Programming 3 07-12-2004 04:19 AM

LinuxQuestions.org > Forums > Linux Forums > Linux - Distributions > Slackware

All times are GMT -5. The time now is 07:13 PM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Open Source Consulting | Domain Registration