LinuxQuestions.org
Welcome to the most active Linux Forum on the web.
Home Forums Tutorials Articles Register
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Distributions > Ubuntu
User Name
Password
Ubuntu This forum is for the discussion of Ubuntu Linux.

Notices


Reply
  Search this Thread
Old 02-03-2008, 10:14 AM   #1
thtr2k
Member
 
Registered: Mar 2005
Location: Australia
Posts: 71

Rep: Reputation: 15
hugs98 help plz


please help me with a simple question guys... How do i set vi editor to use in hugs permanently? I'm using ubuntu 7.10 and installed hugs98 from Adept Manager. i don't know the directories or paths of my installed hugs98. Thank you.
 
Old 02-04-2008, 02:55 AM   #2
b0uncer
LQ Guru
 
Registered: Aug 2003
Distribution: CentOS, OS X
Posts: 5,131

Rep: Reputation: Disabled
New to me, but I take it that you mean how to get this permanent:

Quote:
-Estr
Use editor setting given by str (default: the value of the EDITOR environment variable). Any occurrences of %d and %s in the editor option are replaced by the start line number and the name of the file to be edited, respectively. A common setting is “vi +%d %s".
I don't have the faintest idea of what hugs98 is, so I'll present only one possible solution here. If there is a configuration file to that program, and it allows you to set a default editor, you should do that (maybe /etc/hugs.conf or something? no?) However you have other options. You could use either alias (alias the command so that when you run hugs98, you actually run hugs98 -E"vi +%d %s") or set your editor variable to point to vi(m) instead of whatever it is pointing at.

For changing the editor variable, you can do a search here.

For the alias, you could run
Code:
alias hugs98='hugs98 -E"vi +%d %s"'
Not sure if the quotes inside quotes make life difficult, but I'm hoping that if you first use ' ' quotes and " " inside them, it's ok. Play around if it's not working. The alias should only be in use "for now", so when you reboot don't expect it to be there. Instead you can add that line to your .bash_profile or something, so it's run every time you run bash. Then when you run 'hugs98', the aliased command is actually run..
 
Old 02-04-2008, 11:39 PM   #3
thtr2k
Member
 
Registered: Mar 2005
Location: Australia
Posts: 71

Original Poster
Rep: Reputation: 15
thank you b0uncer. i like the line (alias hugs98='hugs98 -E"vi +%d %s"') of yours. it works with hugs
 
  


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
PLZ, PLZ help - need some info kevmif Linux - General 9 12-17-2007 06:12 AM
please help with hugs98 setting thtr2k Ubuntu 1 10-29-2007 09:25 PM
plz plz help me regarding route mapping nedian123 Programming 1 07-13-2004 08:17 AM
plz plz solve my route mapping problem nedian123 Linux - Networking 1 07-12-2004 09:41 PM
redhat problems plz plz help sap666 Linux - Newbie 5 07-30-2003 10:57 AM

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

All times are GMT -5. The time now is 08:54 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