Hacker Newsnew | past | comments | ask | show | jobs | submitlogin

Someone steal my idea:

A text editor but with "record" and "stop" buttons. Click "record", write all your code, then click "stop". Now you can go back in time and play it all from the beginning, and you can also select certain stopping points as frames.

Then in your live demo, just navigate from one frame to the next, and everyone can watch the pre-recorded code being typed as if it were being done in real time.

Bam. Problem solved.



I once saw a presentation that used a Python shell. The guy typed _super_ fast and didn't make any mistakes. It was pretty impressive.

But then afterwards he told us that he had written a tool that typed out something prewritten as he mashed the keyboard.



Very cool, though what I saw was someone else, probably over a decade ago, who must have had the same idea independently. Though I don't know that he released it as you did.


Perhaps you're thinking of Pete Fein's lightning talk at PyCon 2019 in Atlanta?

https://www.youtube.com/watch?v=MVzTcQkMNXg


Ah, probably using playerpiano. Same idea, but I wanted it for bash.


Ah, yes, and in fact the presentation was from Pete Fein himself! I guess he did release it after all.


You should post a show HN of this. It's really cool and I definitely will be using this in about a month. I wouldn't have found it if not for this comment.


I didn't make it. I made a quick personal hack a few minutes before my lightning talk and Steven Loria later turned it into a real package. I'm just listed in the kudos:

https://doitlive.readthedocs.io/en/latest/kudos.html


this is awesome! nice work


Http://hackertyper.net does that for silly Hacker text, or http://geektyper.com/mobile/ for mobile.


There's something similar for PowerShell: https://www.powershellgallery.com/packages/Start-Demo/1.0.1


Please no. That's the equivalent of presenting an unedited video recording onstage and saying it's all cool because you can fast forward and pause it.

Take the time to build a proper, edited presentation.


This is more-or-less the format Bisquit uses in his tutorial videos, e.g.

https://youtu.be/vkUwT9U1GzA

Somewhere he explained that he made a custom tool to make and play back a "perfect recording" of his edits.


I love how epic the music is


1. asciinema[0] has the ability to record a terminal (and thus, terminal-based editors) and replay it. By default, the replay comes with pause (via <SPACE>) and play-single-frame (via <.>).

2. Vim has Mundo[1] and Emacs has undo-tree[2] which allow you to step backwards-and-forwards through your changes.

As I see it, adding explicitly-selected frames to any of these features should be possible.

0: https://asciinema.org

1: https://simnalamburt.github.io/vim-mundo/

2: https://www.emacswiki.org/emacs/UndoTree


There's a vscode extension that does exactly this. Haven't tested it, but it looks like it should work for live coding presentations.

https://marketplace.visualstudio.com/items?itemName=jevakall...


Here's a demo of that in action. https://youtu.be/rO8-cgtkZSw?t=295


The emacs-gif-screencast package does this very well. Each keystroke (technically, each command) is recorded as a frame, with timestamps used to set the appropriate duration of each frame. e.g. if you stare at the screen for 30 seconds, no additional frames are captured, and that frame lasts 30 seconds (which you can then edit the duration of later in other software).

Note that I don't know how well it would work for long sessions. Theoretically it would be fine, but the way it uses ImageMagick to convert the frames to an animation can be heavy on memory, so that could be a problem. However, the frames could be stitched together with other software that didn't present that problem...


Haha neat idea :) Can't you simulate this in git?

  1. git checkout -b demo
  2. write some code and/or comments
  3. git commit -am "message of what we did in this step"
  4. Go to step 2 if not finished with demo.
  5. Cycle through commits with script, each one a frame.
I probably didn't think about it enough (commit granularity too fine == annoying), but that seems like it might work, and you have the added bonus of having everything in git.


Ah yeah, that would do the same thing basically.


asciinema does that for the terminal: https://asciinema.org/


You know what's funny to me is Mr. Robot does their scenes in.... flash. Even their mobile phone shots are done via flash.


that's incredible. I didn't even know that Adobe was still maintaining and releasing new versions of Flash.


They call it “Animate” now. Once they got their HTML exporter working they changed the name.


Open vim, type code. Done. Hold `u` for playing backwards, or `Ctrl-r` for playing forwards. If you want to show your undos too, then remap `g-` and `g+` to something you can hold and use those instead. If you want to save that undo history, set options `undofile` and `undodir` and perhaps `undolevels` if 1000 is too little.


Sounds like a cool VIM plugin to write, basically just a key logger that when ran against a file recreates what was done.

Even simpler, a key logger with some control, wouldn't even need integration into a specific editor.


heres a weekend script I wrote as a prank. it just remaps your a-z keys and reads in from a renamed version of a file.

https://github.com/mjbrownie/hackertyper.vim



Wouldn't that just be watching you type the mistakes again, but this time without the cursing?

Edit, I see you can manually update stuff.


This app works pretty well. I turn it on during hackathons etc, to show work done.

http://getscreenninja.com


And don't record Ctrl+X and DEL and it's going to be more interesting. And mute that nerdy vocal frier. :)


scrimba.com comes to mind


Came here to say this, Scrimba is a thing and it's very well done. I just took a look, and it seems like their original premise didn't really take hold-- they're mostly pushing tutorials now, which is probably the most common use case.


I thought they were primarily for tutorials. What was their original premise? Do you mean the whole "use our framework instead of react" thing?


You could probably do something like that using vim macros.


   script -r
   script -p


Which version of script are you using? Mine replies to script --version with "script from util-linux 2.31.1". It doesn't support those flags.

However, I can use it like this:

  script --command='vim code.py' --timing=typescript.timing typescript
  scriptreplay -t typescript.timing -s typescript


I'm on a Mac running High Sierra at the moment.




Guidelines | FAQ | Lists | API | Security | Legal | Apply to YC | Contact

Search: