Skip to content

Add haskell-interactive-copy-to-prompt. #457

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 1 commit into from
Mar 5, 2016

Conversation

cmears
Copy link
Contributor

@cmears cmears commented Feb 4, 2015

This change lets you press Enter on a line in a haskell-interactive session to copy that line to the current prompt. It is a small change to make the lack of history-search (e.g. #315) slightly less painful.

In #315 Ivan suggested: "If nothing else, inf-haskell let you C-r to do a backward search in the buffer, and then hitting Enter would copy that line to the current prompt line." That's essentially what I've done.

I'm only an inexpert Emacs Lisper, so any corrections or improvements are welcome!

@gracjan
Copy link
Contributor

gracjan commented Mar 14, 2015

@purcell? @chrisdone? @hvr? Any opinion about this one?

@purcell
Copy link
Member

purcell commented Mar 14, 2015

Looks reasonable to me.

@gracjan
Copy link
Contributor

gracjan commented Sep 28, 2015

I do not know what to think about this one. Is there a prior art with this kind of RET behavior? I've never seen anything working like this.

@purcell
Copy link
Member

purcell commented Sep 29, 2015

@gracjan Guess the best solution would be proper history search. Without that, a command like this is kinda reasonable, but perhaps not bound to RET.

@ivan-m
Copy link
Contributor

ivan-m commented Sep 29, 2015

The old inferior haskell setup has something like this, and I for one have missed it (I've ended up copy/pasting lines that are too far back in the history to keep traversing through).

@gracjan
Copy link
Contributor

gracjan commented Sep 29, 2015 via email

gracjan added a commit that referenced this pull request Mar 5, 2016
Add haskell-interactive-copy-to-prompt.
@gracjan gracjan merged commit 6431491 into haskell:master Mar 5, 2016
@hvr
Copy link
Member

hvr commented Mar 5, 2016

@gracjan Is this now behaving similar to M-x ielm? (that's been one of the prior-art features I sometimes looked at when trying to figure out whether haskell-mode's REPL behaves sensibly)

@gracjan
Copy link
Contributor

gracjan commented Mar 5, 2016

ielm

fice-t added a commit to fice-t/haskell-mode that referenced this pull request Apr 24, 2016
Gets rid of a check that was made redundant in a previous PR (haskellGH-457).
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

5 participants