-
Notifications
You must be signed in to change notification settings - Fork 91
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
[Feature request] Support Github edit code functionality #154
Comments
This requires the extension to be able to interact with the custom javascript for github as it's not presented as a plain text area. |
The functionality for github seems to be provided by CodeMirror. I believe there is an API for client side extensions to interact with CodeMirror but it would be a fair amount of work. I can certainly help with reviewing code and giving pointers if you want to give it a go. |
I thought i have no enough skill to do this, sorry. when i want to contribute some code to another project, this is all my original intention. anyway, thanks, you can close this issue as you like. |
You can leave feature requests open so people can find it. |
This is also a duplicate of #125 which essentially needs the same thing. |
Is this the same reason why it doesn't work for sqlzoo.net? |
@et2010 that seems to be something else:
Which isn't an editable div as I understand it so JavaScript must be doing something behind the scenes. |
No my mistake, there is a textarea in there, not sure why it wasn't tagged. |
Codemirror has a documented API: https://codemirror.net/doc/manual.html#api It doesn't seem like the features needed for editserver would be too hard to implement, a combination of doc.getRange() for pulling and doc.replaceRange() for pushing? But with my meager javascript knowledge, it would take a disproportionately long amount of time to patch things together. |
@ThibautVerron you are assuming that anyone else has greater knowledge and time than you do. Most of the features that have been added to Edit with Emacs over the years have been a result of drive by contributions. So if you want this feature the best way to get it is to have a go at implementing it. Discussion and review of a working proof of concept will beat wishes any day. |
I can't say any about time, but I'm certain that some people do have more knowledge of javascript or of the code of this extension than I do. I did not mean to imply that anything more than that, or to request that somebody invest time into this if they don't care about the feature. My point was only to add relevant information for the passer-by who would be interested in the feature and have the necessary knowledge at hand. Given how many platforms nowadays use CodeMirror (Github, Overleaf, CoCalc, Jupyter...), I have good hope that such a user will eventually come by. And if I ever learn more javascript and it hasn't happened by then, this issue stays on my todo list. |
FWIW, GhostText tries to support editing CodeMirror (and Ace editors). It has its own problems/bugs, of course. |
Following is a image to describe what i means.
I think if we can edit github file directly with emacs, that will make create a PR very simple.
Thanks
The text was updated successfully, but these errors were encountered: