Live data from Hacker News

Show HN: Termtosvg – Record terminal sessions as SVG animations

github.com

51–60 of 84 posts

Re: Show HN: Termtosvg – Record terminal sessions as SVG animations

#51
I'm very impressed - it combines two of my favourite technologies, Python and SVG. Three, in fact - including terminal. I will be watching it and tinkering with it.

It's written in modern Python and well documented. However, some functions are a bit monolithic: https://github.com/nbedos/termtosvg/blob/master/termtosvg/te...

Re: Show HN: Termtosvg – Record terminal sessions as SVG animations

#52
post #50
post #49

Earlier quoted context omitted.

This is in the context of an upstream comment (softly) claiming that now browser has 100% SVG support. I think sometimes this is because the full spec is infeasible to implement, at least in a performant manner, and rather than implement a fully compliant but slow mess, they implement a partially compliant but usefully fast subset. Providing a reference implementation allows a standards body to learn early that what…

Ok, but it's not like Microsoft can't discuss with W3C any problems (in their view) in the standard. Anyway, I totally agree that there should be a reference implementation. Imho, preferably in a purely functional language, to keep it as clean as possible.

> Ok, but it's not like Microsoft can't discuss with W3C any problems (in their view) in the standard.

Oh, I'm not defending Microsoft specifically, they're generally pretty horrible on this front. All the browser vendors have components in various states of compliance though, and some components seem to sit at a certain level for years.

Re: Show HN: Termtosvg – Record terminal sessions as SVG animations

#53
post #13

What're people using tools like this for? I see the usage surely when demonstrating something in the terminal - and many times used for showcasing projects and tools. Are you using the recordings for other purposes, like to document work and share progress with your team + manager for instance for work you're doing during a sprint (good for demo'ing things at the end of the sprint too).

It's good for right-way vs wrong-way demonstrations. If I just copy the text out of my terminal and say "this is how we used to do it; this is how we should do it/will do it now" and paste it in a jira ticket, not many people will take the time to read and understand. Gifs are more accessible I guess.

Maybe it's just me, but I can't stand having to wait to watch someone slowly type something when all I want to to is know the command or understand what some output should look like.

Similarly, I've never seen this sort of thing used professionally, just on blogs and project demos.

Re: Show HN: Termtosvg – Record terminal sessions as SVG animations

#55
If only ffmpeg->mp4 instead of svg...

I had just thrown together a typescript bash script to record IRC with timing for later playback and sync with a podcast, the trick is the rendering step: in theory it could be done on a canvas with native ffmpeg drawtext, but the invocation is super gnarly.

Re: Show HN: Termtosvg – Record terminal sessions as SVG animations

#56
post #21

This is pretty awesome. I'm a big fan of both SVG animations and terminal recorders, so this is right up my alley. I previously built a small library called svganimator for creating smooth animations between static SVG images [1], used generated SVG animations to help design the Wayback Machine loading animation [2], and also put together a fairly comprehensive comparison of terminal recording solutions [3]. I'll nee…

My first thought was "this seems neat", and my second thought was: how hard would it be to write a small js script to play back "script"[s] output? Or, to take script output, convert it to some pre-tags and add js animation on top of that...

I suppose the main barrier would be lack of recorded timing information in script logs, so either pre-procesding or pause for input (say 50ms/keystroke + 200ms pr return/line-feed) and/or output (say 50ms pr line feed).

Although, now I see there's a -t option for a timing file.

So would seem one should be able to take logs from script, and produce svg, gif, png, webm, mp4... js output.

[s] http://man7.org/linux/man-pages/man1/script.1.html

Re: Show HN: Termtosvg – Record terminal sessions as SVG animations

#57
post #54

This is super awesome, but will there ever be an ability to pause/rewind/scrub?

Well, the animation is inherent to the SVG, so either browsers would need to support that, or some kind of JavaScript library is needed to extract that (probably giving Edge animation support while it's at it)

Re: Show HN: Termtosvg – Record terminal sessions as SVG animations

#58
post #32
post #28

Earlier quoted context omitted.

Honestly, if you're recording terminal sessions, it's probably fine to not support Edge. I doubt any significant portion of your audience is going to be using it, and even if they do, they're going to be perfectly understanding when you say "sorry, Edge doesn't support SVG animations, use a different browser". Shitty of Microsoft, though. If they aren't going to support it, it's not going to be widely deployed. I exp…

W3C should have a rule that a web browser which does not intend to support the standard may not call itself a "web browser".

Those web browsers would probably also not support your new standard, and continue to call themselves web browsers.

Re: Show HN: Termtosvg – Record terminal sessions as SVG animations

#59
post #32
post #28

Earlier quoted context omitted.

Honestly, if you're recording terminal sessions, it's probably fine to not support Edge. I doubt any significant portion of your audience is going to be using it, and even if they do, they're going to be perfectly understanding when you say "sorry, Edge doesn't support SVG animations, use a different browser". Shitty of Microsoft, though. If they aren't going to support it, it's not going to be widely deployed. I exp…

W3C should have a rule that a web browser which does not intend to support the standard may not call itself a "web browser".

> W3C should have a rule that a web browser which does not intend to support the standard may not call itself a "web browser"

They've got no authority to do that. There is no trademark on 'web' that they could enforce.

Post reply on HN