4 ms·
You should take a look at embedmd, which allows you to include files (or just portions of a file) in a Markdown file: https://github.com/campoy/embedmd https://
by misternugget 8y ago
You should take a look at embedmd, which allows you to include files (or just portions of a file) in a Markdown file: https://github.com/campoy/embedmd https://github.com/campoy/embedmd
As I wrote in the post, I didn't use it because it doesn't allow me to include a portion of something and then comment out a part of that, but today I got thinking: if it could include a portion of a function and also the relevant (semantic?) context, it would be 99% of what I need. But the "relevant context" is the tricky part, I guess. I like what git diff does, when it shows the signature of a changed function (does it simply use the first of the previous lines that are less intended?), but I guess it's hard to get really right...
edit: GitChapter is also a really interesting project. If it didn't use a real git repository, but something like folders that resemble single commits, I think I'd use it. https://github.com/chrissound/GitChapter/ https://github.com/chrissound/GitChapter/