Ticket #61 (closed enhancement: fixed)

Opened 6 years ago

Last modified 6 years ago

[Patch] Readline command completion for everything

Reported by: gsauthof Owned by: nobody
Priority: major Milestone:
Component: hugs Version: 200609
Keywords: Cc:

Description

Hi,

I wrote a patch that improves the readline command completion feature of hugs. I.e: - added completion of function names and constructors - added completion of command names (:<cmd>) - added completion of module names (e.g. after :browse , etc.) - only do filename completion where it makes sense (e.g. after :load , etc.) - expand use of tilde (~) in filenames (previously it was completed but not recognized by hugs) - read and write the history from/to ~/.hugs_history - make hugs recognize :help

Patch is attached.

Best regards Georg Sauthoff

Attachments

hugs.readline.patch Download (8.5 KB) - added by gsauthof 6 years ago.
improved readline support for hugs98 200609

Change History

Changed 6 years ago by gsauthof

improved readline support for hugs98 200609

Changed 6 years ago by gsauthof

Hm, trac eats my newlines? The WikiFormatting link ( http://hackage.haskell.org/trac/hugs/wiki/WikiFormatting) contains spam and the suggested formatting does not work in the Comment Preview (e.g. '* ')... Strange.

Changed 6 years ago by ross

  • status changed from new to closed
  • resolution set to fixed

Thanks. I've committed it to our shiny new darcs repository, though it does have some limitations:

  • the names include things that aren't in scope (:names has the same problem)
  • the names don't include qualified names
  • the words completed are space-delimited, rather than being Haskell ids
  • completion for :load works for filenames only, not modules

Still, it's a start, and better than nothing.

Note: See TracTickets for help on using tickets.