Thread: Favorite Linux Editor for PostgreSQL Scripts?
I'm still new to the Linux world, and do not have a bias for editor choice. I have one colleague that uses Emacs, but another is worried it leads to RSI and carpel tunnel syndrome, because the hands are on the keyboard all the time. So what are the favorites for PostgreSQL scripts? I need to start learning one. Steve Miller SIL International
It depends.... I use vi, and specify the environment variable "PSQL_EDITOR" in "/etc/profile.local", thus: export PSQL_EDITOR="/usr/bin/vi" then when I want to edit a file, from within psql, type: \e /path/tp/file.sql :-) easy. -- Thomas Adam --- Steve_Miller@sil.org wrote: > I'm still new to the Linux world, and do not have a > bias for editor choice. > I have one colleague that uses Emacs, but another is > worried it leads to > RSI and carpel tunnel syndrome, because the hands > are on the keyboard all > the time. > > So what are the favorites for PostgreSQL scripts? I > need to start learning > one. > > Steve Miller > SIL International > > > > ---------------------------(end of > broadcast)--------------------------- > TIP 2: you can get off all lists at once with the > unregister command > (send "unregister YourEmailAddressHere" to majordomo@postgresql.org) ===== Thomas Adam "The Linux Weekend Mechanic" -- www.linuxgazette.com __________________________________________________ Do You Yahoo!? Everything you'll ever need on one web page from News and Sport to Email and Music Charts http://uk.my.yahoo.com
Hi Steve ! On command line I use joe. On KDE, joe via terminal and Kedit. With VNC you can Kedit or Gedit or whatever 'locally'. Even from a windows-box. BR, aarni On Thursday 06 February 2003 05:24 pm, you wrote: > I'm still new to the Linux world, and do not have a bias for editor choice. > I have one colleague that uses Emacs, but another is worried it leads to > RSI and carpel tunnel syndrome, because the hands are on the keyboard all > the time. > > So what are the favorites for PostgreSQL scripts? I need to start learning > one. > > Steve Miller > SIL International > > > > ---------------------------(end of broadcast)--------------------------- > TIP 2: you can get off all lists at once with the unregister command > (send "unregister YourEmailAddressHere" to majordomo@postgresql.org)
On Thu, 6 Feb 2003 Steve_Miller@sil.org wrote: > I'm still new to the Linux world, and do not have a bias for editor choice. > I have one colleague that uses Emacs, but another is worried it leads to > RSI and carpel tunnel syndrome, because the hands are on the keyboard all > the time. I lean towards emacs. But, .... There is some evidence to suggest that RSI (including carpal tunnel syndrome) is in part "socially acceptable", and that has something to do with its prevalence. The statistics are wishy-washy, like a lot of things biological, but it seems that if you live in a culture where RSI is socially acceptable, you stand a larger chance of catching (or getting) it, for the same exposure to some environment. This isn't to say that the pain is imagined, they can instrument people, and they can see that pain signals are being transmitted, so something of it is real. I think the jury is still out on just what is necessary and sufficient conditions to get it. I've always believed that if I do a couple of things, I will lower my chance to get it. 1) Every 20-40 minutes, get away from the computer for a few minutes. Let the eyes focus on some distance other than 18 inches (or whatever). Stretch the wrist in the 4 (predominant) directions of movement: flexion, extention, rotation clockwise, rotation counter-clockwise. I've never looked into the side to side motions (or done anything). Drinking caffienated beverages is good, it forces you to go to the bathroom if nothing else (getting away from the computer). 2) Keep your wrists (heck, your whole body) strong. Get to the gym once in a while. Do exercises which require stronger muscles/tendons/ligaments in the area of the wrist. I don't think the above works as far as rehab goes, if you already have symptoms, I think you need to get your doctor involved. But as a prophylactic, I think the above works. Or, at least it seems to for me. Gord -- Matter Realisations http://www.materialisations.com/ Gordon Haverland, B.Sc. M.Eng. President 101 9504 182 St. NW Edmonton, AB, CA T5T 3A7 780/481-8019 ghaverla @ freenet.edmonton.ab.ca 780/993-1274 (alt.)
> So what are the favorites for PostgreSQL scripts? I need to start learning > one. I use a vi clone, vim, mainly because I tend to like to be in text mode rather than run a gui. I use a laptop and my eyes aren't so good anymore. I also use pico for quick fixes, but vim allows me to switch back and forth between multiple files and copy and paste code into the other window. All text editors with no mouse involved, so it doesn't really answere your question! OK, gang, should I too consider a gui editor, maybe even vim in X? brew ========================================================================== Strange Brew (brew@theMode.com) Check out my Musician's Online Database Exchange (The MODE Pages) http://www.TheMode.com ==========================================================================
On 02/06/2003 10:01:56 AM Mark Thomas wrote: >I am personally an emacs user, but editors are like >religion -- you love what you learn first. :) Not necessarily, on either score, but I get the idea. You Emacs users are a loyal bunch. :-) >If you do choose emacs I'd recommend getting a keyboard that has the CTRL >key left of the 'A' instead of in the lower-left corner where it's useless. >CTRL is commonly used in emacs. Keytronic makes keyboards with the >capslock/CTRL swappable. My CTRL and ALT keys are under my thumbs. Literally. I've learned to appreciate them there under the strongest digit of my hands. Seems placement there would be essential for Emacs. >Why choose one over the other? emacs is modeless (meaning what you type is >what goes into the doc). It uses meta keys (CTRL, ALT, ESC) to carry out >commands. Vi is modal, meaning you are either in edit mode or in command >mode. Being an emacs proponent I'll claim emacs is more powerful. :) I tend >to only have an emacs window open on my desktop and use its directory >browsing, shell window, and compilation support for everything. I wasn't aware of those things. Thanks. >Vi has the advantage of being everywhere. You may find unix installations >without emacs, but I don't think you'll find one without vi. Heavy >cut/paste users seem to like vi more than emacs. Hmmm...I more of a cutter/paster. Steve Miller SIL International
On Thu, 6 Feb 2003 Steve_Miller@sil.org wrote: > On 02/06/2003 10:01:56 AM Mark Thomas wrote: > > >I am personally an emacs user, but editors are like > >religion -- you love what you learn first. :) > > Not necessarily, on either score, but I get the idea. You Emacs users are > a loyal bunch. :-) Yes. In my LUG, we can often get into friendly vi versus emacs fights. Sort of like Tastes Great versus Less Filling from some approximation to beer commercial. > >Why choose one over the other? emacs is modeless (meaning what you type is > >what goes into the doc). It uses meta keys (CTRL, ALT, ESC) to carry out > >commands. Vi is modal, meaning you are either in edit mode or in command > >mode. Being an emacs proponent I'll claim emacs is more powerful. :) I > tend > >to only have an emacs window open on my desktop and use its directory > >browsing, shell window, and compilation support for everything. > > I wasn't aware of those things. Thanks. One thing I had seen written a long time ago, is that people with long fingers tended to like emacs, and short fingers for vi. Makes as much sense as any rules for picking an editor I guess. Certainly if you have short fingers, some of the emacs key combinations aren't easy. *** On another note, Someone thought I was making lightly of RSI with my earlier note. I'm not a spring chicken (I'm 42), and a couple of my jobs over the years (and education) have involved LOTS of programming. And so far (knock on wood, or head :-), no RSI. And I've been involved enough in rehab, that I can read a lot of the good medical info. I have no doubt that people who have gotten RSI have a problem to deal with, and I wish them luck and fast healing. I think prevention is a big part of avoiding RSI, and a big part of that is fitness. As a group, programmers and other people who use keyboards a lot are not big on fitness. Fitness includes aspects of strength, endurance and flexibility. I had mentioned things having to do with strength and flexibility in my earlier note. Gord -- Matter Realisations http://www.materialisations.com/ Gordon Haverland, B.Sc. M.Eng. President 101 9504 182 St. NW Edmonton, AB, CA T5T 3A7 780/481-8019 ghaverla @ freenet.edmonton.ab.ca 780/993-1274 (alt.)
If you use either emacs or vi/vim, it is useful to know that the psql command line has readline support. So if you have a .inputrc file with the line (in my case) "set editing-mode vi" You can move up and down between lines, search, yank and paste in the ways you can on the command line. Rory On 06/02/03, ghaverla@freenet.edmonton.ab.ca (ghaverla@freenet.edmonton.ab.ca) wrote: > On Thu, 6 Feb 2003 Steve_Miller@sil.org wrote: > > On 02/06/2003 10:01:56 AM Mark Thomas wrote: > > > > >I am personally an emacs user, but editors are like > > >religion -- you love what you learn first. :) -- Rory Campbell-Lange <rory@campbell-lange.net> <www.campbell-lange.net>
Steve_Miller@sil.org writes: > I'm still new to the Linux world, and do not have a bias for editor > choice. I have one colleague that uses Emacs, but another is > worried it leads to RSI and carpel tunnel syndrome, because the > hands are on the keyboard all the time. Emacs has a lot going for it as a programmer's editor, especially for working with PostgreSQL (it has several modes that allow you to do most of your PostgreSQL work directly in an Emacs buffer). If you are concerned about the wacky keystrokes giving you RSI then you might want to consider running Emacs in Viper mode. Viper is a vi-emulation package that runs on top of Emacs. This allows you to use vi's more typist friendly keystrokes with Emacs' wide range of powerful extensions. > So what are the favorites for PostgreSQL scripts? I need to start > learning one. Good Luck, Jason
You have lots of editors to choose from but probably the most widely used (at least by professionals) and biggest cause of religious editor wars are emacs and vi (actually vim, that is "vi improved", is the most common version of vi on Linux distros). I chose to learn vim because: -it is reasonably small and fast -there are versions for unix/linux/dos/windows/X-windows/etc. (one editor to rule them all...) -it is the one editor that you find on basically all *nix platforms so you need to know it anyway. BTW, learning vi (or emacs, I guess) is frustrating but once you get it you will not want to go back. HTH, Steve On Thursday 06 February 2003 7:24 am, Steve_Miller@sil.org wrote: > I'm still new to the Linux world, and do not have a bias for editor choice. > I have one colleague that uses Emacs, but another is worried it leads to > RSI and carpel tunnel syndrome, because the hands are on the keyboard all > the time. > > So what are the favorites for PostgreSQL scripts? I need to start learning > one. > > Steve Miller > SIL International > > > > ---------------------------(end of broadcast)--------------------------- > TIP 2: you can get off all lists at once with the unregister command > (send "unregister YourEmailAddressHere" to majordomo@postgresql.org)
Not so sure that the problem is the keyboard, more how you use it. Get a decent keyboard and learn to type, you should be fine. On the linux side, skip emacs, use vim, tis a lovely editor :) Besides that, you could use some of the development IDE's such as KDevelop. Cheers On Thu, 6 Feb 2003, Steve_Miller@sil.org wrote: > I'm still new to the Linux world, and do not have a bias for editor choice. > I have one colleague that uses Emacs, but another is worried it leads to > RSI and carpel tunnel syndrome, because the hands are on the keyboard all > the time. > > So what are the favorites for PostgreSQL scripts? I need to start learning > one. > > Steve Miller > SIL International > > > > ---------------------------(end of broadcast)--------------------------- > TIP 2: you can get off all lists at once with the unregister command > (send "unregister YourEmailAddressHere" to majordomo@postgresql.org) > -- > Virus scanned by edNET. > -- This email and any files transmitted with it are confidential and intended solely for the use of the individual or entity to whom they are addressed. If you have received this email in error please notify the sender. Any offers or quotation of service are subject to formal specification. Errors and omissions excepted. Please note that any views or opinions presented in this email are solely those of the author and do not necessarily represent those of edNET or lightershade ltd. Finally, the recipient should check this email and any attachments for the presence of viruses. edNET and lightershade ltd accepts no liability for any damage caused by any virus transmitted by this email. -- -- Virus scanned by edNET.
vim is the best :-) (well, i like it anyway :-) Try out some of the scripts at: http://vim.sourceforge.net/script_search.php?keywords=database&script_type=&order_by=rating&direction=descending&search=search if you want extra macros/colours/extentions etc.. On Fri, 2003-02-07 at 05:59, Steve Crawford wrote: > You have lots of editors to choose from but probably the most widely used (at > least by professionals) and biggest cause of religious editor wars are emacs > and vi (actually vim, that is "vi improved", is the most common version of vi > on Linux distros). > > I chose to learn vim because: > -it is reasonably small and fast > -there are versions for unix/linux/dos/windows/X-windows/etc. (one editor to > rule them all...) > -it is the one editor that you find on basically all *nix platforms so you > need to know it anyway. > > BTW, learning vi (or emacs, I guess) is frustrating but once you get it you > will not want to go back. > > HTH, > Steve > > On Thursday 06 February 2003 7:24 am, Steve_Miller@sil.org wrote: > > I'm still new to the Linux world, and do not have a bias for editor choice. > > I have one colleague that uses Emacs, but another is worried it leads to > > RSI and carpel tunnel syndrome, because the hands are on the keyboard all > > the time. > > > > So what are the favorites for PostgreSQL scripts? I need to start learning > > one. > > > > Steve Miller > > SIL International > > > > > > > > ---------------------------(end of broadcast)--------------------------- > > TIP 2: you can get off all lists at once with the unregister command > > (send "unregister YourEmailAddressHere" to majordomo@postgresql.org) > > ---------------------------(end of broadcast)--------------------------- > TIP 5: Have you checked our extensive FAQ? > > http://www.postgresql.org/users-lounge/docs/faq.html