Loading ...
Sorry, an error occurred while loading the content.

Silly Hack of the Week: Gvim as a front-end to xmms

Expand Messages
  • Shlomi Fish
    Getting tired of looking for a good file manager without any major side-effects, when all I needed was the ability to scroll the mp3 list, I decided to adapt
    Message 1 of 4 , Feb 7, 2002
    • 0 Attachment
      Getting tired of looking for a good file manager without any major
      side-effects, when all I needed was the ability to scroll the mp3 list, I
      decided to adapt gvim to the job. The result are the following two lines,
      which one can add to his .vimrc file:

      map <F3> 0"5y$:!xmms -e "<C-R>5"<CR><CR>
      map <C-F3> 0"5y$:!xmms "<C-R>5"<CR><CR>

      To use it, run "ls | gvim -", put the cursor on the line which
      contains the filename you wish to play and press F3 to enqueue it or
      Ctrl+F3 to play it. Known Bugs:

      1. Not resistant to backslashes, double quotes, back quotes, and other
      shell special characters. (maybe I should use a single quote?) Thinking
      about it a filename that contains a backslash may turn these macros
      into a security hazard. (I.e: my-file-`rm -rf $HOME`.mp3)

      2. Not compatible with filenames that contain newlines.

      3. May or may not work with other vi clones, or with SysV vi's.

      Disclaimer:
      1. I may possibly be re-inventing the wheel, but nonetheless having fun in
      the process and I learn how to program Vim.
      2. Don't tell me emacs has it, because I know it does.

      Regards,

      Shlomi Fish

      ----------------------------------------------------------------------
      Shlomi Fish shlomif@...
      Home Page: http://t2.technion.ac.il/~shlomif/
      Home E-mail: shlomif@...

      "Let's suppose you have a table with 2^n cups..."
      "Wait a second - is n a natural number?"
    • Oleg Goldshmidt
      ... ... Have you thought of aliasing it to mpls ? ;-) -- Oleg Goldshmidt | ogoldshmidt@NOSPAM.computer.org If it ain t broken, it has not got enough
      Message 2 of 4 , Feb 7, 2002
      • 0 Attachment
        Shlomi Fish <shlomif@...> writes:

        > all I needed was the ability to scroll the mp3 list

        <snip>

        > To use it, run "ls | gvim -"

        Have you thought of aliasing it to "mpls"? ;-)

        --
        Oleg Goldshmidt | ogoldshmidt@...
        "If it ain't broken, it has not got enough features yet."
      • Tzafrir Cohen
        ... See for yourself: http://vim.sf.net/ Many, many gvim-related stuff. e.g: how to use gvim as the editor of evoltion messages, how to get it to do inline
        Message 3 of 4 , Feb 7, 2002
        • 0 Attachment
          On Thu, 7 Feb 2002, Shlomi Fish wrote:

          > Disclaimer:
          > 1. I may possibly be re-inventing the wheel, but nonetheless having fun in
          > the process and I learn how to program Vim.

          See for yourself:

          http://vim.sf.net/

          Many, many gvim-related stuff. e.g: how to use gvim as the editor of
          evoltion messages, how to get it to do inline spell-checking, generate
          morse-code, and use bit-keeper.

          Disclaimer: I haven't tested any of the above-mentioned scripts (except
          the spell-checker, which works nicely)

          --
          Tzafrir Cohen /"\
          mailto:tzafrir@... \ / ASCII Ribbon Campaign
          Taub 229, 972-4-829-3942, X Against HTML Mail
          http://www.technion.ac.il/~tzafrir / \
        • Shlomi Fish
          ... If the spell-checker ignores formatting style like Emacs M-x ispell-buffer does, then it would be highly useful. (I m using Emacs to check the spelling of
          Message 4 of 4 , Feb 7, 2002
          • 0 Attachment
            On Thu, 7 Feb 2002, Tzafrir Cohen wrote:

            > On Thu, 7 Feb 2002, Shlomi Fish wrote:
            >
            > > Disclaimer:
            > > 1. I may possibly be re-inventing the wheel, but nonetheless having fun in
            > > the process and I learn how to program Vim.
            >
            > See for yourself:
            >
            > http://vim.sf.net/
            >
            > Many, many gvim-related stuff. e.g: how to use gvim as the editor of
            > evoltion messages, how to get it to do inline spell-checking, generate
            > morse-code, and use bit-keeper.
            >
            > Disclaimer: I haven't tested any of the above-mentioned scripts (except
            > the spell-checker, which works nicely)
            >

            If the spell-checker ignores formatting style like Emacs' M-x
            ispell-buffer does, then it would be highly useful. (I'm using Emacs to
            check the spelling of my HTML and LaTeX documents). I'll look into it.
            Thanks.

            Regards,

            Shlomi Fish

            > --
            > Tzafrir Cohen /"\
            > mailto:tzafrir@... \ / ASCII Ribbon Campaign
            > Taub 229, 972-4-829-3942, X Against HTML Mail
            > http://www.technion.ac.il/~tzafrir / \
            >
            >
            >
            > To unsubscribe from this group, send an email to:
            > hackers-il-unsubscribe@egroups.com
            >
            >
            >
            > Your use of Yahoo! Groups is subject to http://docs.yahoo.com/info/terms/
            >
            >



            ----------------------------------------------------------------------
            Shlomi Fish shlomif@...
            Home Page: http://t2.technion.ac.il/~shlomif/
            Home E-mail: shlomif@...

            "Let's suppose you have a table with 2^n cups..."
            "Wait a second - is n a natural number?"
          Your message has been successfully submitted and would be delivered to recipients shortly.