LinuxQuestions.org
Latest LQ Deal: Latest LQ Deals
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-22-2009, 07:56 AM   #1
vonbiber
Member
 
Registered: Apr 2009
Distribution: slackware 14.1 64-bit, slackware 14.2 64-bit, SystemRescueCD
Posts: 533

Rep: Reputation: 129Reputation: 129
vi display of certain files (html, tex)


on slackware12.2 vi is a link to elvis.
There's an annoying feature in the config
that I can't figure out how to unset.
When I open an html file, it doesn't display
like a text file that I can edit
I have to
:display normal
everytime
I tried to create ~/.exrc (I can get the 'tilde' character
here) and tried
display=normal
that resulted in an error message
then I tried
display=
But I'm still stuck with this.
I know that in the past I got the same problem with
TeX files (I hadn't tried lately).
This thing isn't documented anywhere.
 
Old 04-22-2009, 08:09 AM   #2
Libu
Member
 
Registered: Oct 2003
Location: Chennai
Distribution: Slackware 12.1
Posts: 165

Rep: Reputation: 36
Why don't you just use vim ? You can delete the vi link and recreate it so that it points to vim.

As for your query, just add this to the config file
Quote:
display normal
I think this might work, however I'm not sure.


Quote:
I tried to create ~/.exrc (I can get the 'tilde' character here)
~ just represents your home directory.
 
Old 04-28-2009, 02:39 AM   #3
vonbiber
Member
 
Registered: Apr 2009
Distribution: slackware 14.1 64-bit, slackware 14.2 64-bit, SystemRescueCD
Posts: 533

Original Poster
Rep: Reputation: 129Reputation: 129
html default display in vi: problem solved

display normal
in ~/.exrc doesn't change anything
But looking thru the files in /usr/share/elvis/elvis.*
and reading a bit the doc I figured it
1. I created a folder .elvis in my home directory
2. I copied from /usr/share/elvis to ~/.elvis
these 2 files: elvis.rc and elvis.arf
I edited elvis.arf
I replaced the line
case .html set! bufdisplay=html
with
case .html set! bufdisplay=normal

While I was there, I did the same with .tex

I really don't understand why vi is trying to mimic
emacs. vi should be an editor, period.
If I want to display an html file I already
got links in console, and a bunch of browsers in X.
 
Old 04-28-2009, 03:57 AM   #4
mRgOBLIN
Slackware Contributor
 
Registered: Jun 2002
Location: New Zealand
Distribution: Slackware
Posts: 999

Rep: Reputation: 231Reputation: 231Reputation: 231
Did you notice that you can toggle the display mode, hit ^Wd
(that's CTRL+w d)

It's actually very handy once you get the hang of it
 
  


Reply


Thread Tools Search this Thread
Search this Thread:

Advanced Search

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
Merge Of Html Files Into A Single Html (or Pdf) fiomba Linux - Software 10 05-11-2018 11:28 AM
Tomcat 6.0.16 installed, but does not display HTML or JSP files edwarrj1 Linux - Software 4 02-21-2008 02:17 PM
Ever used TeX, post your work. -- Tex Art Gallery barton Linux - Software 2 02-28-2006 02:29 AM
TeX can't find tex.fmt jrdioko Linux - Software 0 11-14-2005 05:34 PM
Can OOo display .html files? CyberLord_7 Linux - Software 3 03-23-2004 01:27 PM

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

All times are GMT -5. The time now is 11:30 AM.

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