Announcement: Live-Archive package


#1

Live-Archive archives project files continuously with easy review of old versions. The description and feature list from the readme are below.

Description

When Live Archive is enabled for a project then every save on every file will add that version to an archive. This happens transparently in the background with no noticeable delay (unless you can perceive 10 ms). The archive is highly compressed. The biggest source file in this package has 130 versions stored in an archive file smaller than the actual source file.

Later, when that file is open in the Atom editor, the live-archive:open command will open up a matching tab that allows fast and easy access to all versions in the archive. This history can be navigated using a number of methods, like clicking on VCR-like buttons, text searching through time, and more.

When viewing a version, all Atom features like syntax highlighting and Find are available since it is a normal editing tab. Plus the changes in that version can be highlighted with colored markers.

There is one especially powerful feature. You can enable an option to keep the screen focused on one block of text. When going through time it only shows versions with changes to that block.

Features

  • Archive

    • For simplicity all versions are kept forever
    • Archive is highly compressed
      • Text differencing
      • Bit-level binary archive format
      • Text compressed with zlib
    • All files for project archived in single folder
  • Fast Review

    • Ram-based index allows quick search
    • Difference scanning is bi-directional (2X speedup)
    • Bases (entire text versions) interspersed through archive
  • Simple UI

    • No settings
    • Saving is transparent
    • Confidence indicator in status bar shows actions
    • Review pane is at bottom of editor pane like find-and-replace
  • Reliable (virtually crash-proof)

    • All version saves are append-only in a single write
    • Archive can be backed up while in use

#2

I didn’t include an animated gif before. In a form of shameless plug here is one …


#3

Damn. Why would an animated gif not work here? I thought a browser would always handle JPGs and GIFs properly.

Anyway, here is a link to a working version of that GIF.

Live-Archive animated gif.


#4

Discourse de-animates animated GIFs when they’re displayed inline in posts to make things load faster probably. If you click them to bring up the lightbox, they’re animated normally.


#5

Hey Mark, I downloaded it, tested it. Very, very cool!

I’ll have to play with it a lot more before any real suggestions but one simple one:
Can the link for Archive also do the close all? Does that make sense? I was thinking for the bar on the bottom to hide basically. So the link itself would have a sort of toggle behavior.


#6

Sure. I don’t see anything else it would be useful for. It’s on my to-do list.


#7

I’ve been using the crap out of this package. Just thought i’d pop in here and say thank you. Great stuff.


#8

Thanks. I appreciate that.

I obviously also use the crap out of it. It changes my coding style. I code wild ideas freely and revert all the time. I feel free to delete anything any time with no worry about making a mistake.

I don’t think many people will use it though. It is not a familiar concept. The packages that get downloaded a lot are things like auto-completion that people are familiar with and miss.


#9

Yeah, well particularly the things that get downloaded the most I think are things that people know to already search for!

Everyone needs to give this thing a shot! Did you post it on hacker news show?

It will probably / should get listed in the next package round up!


#10

Hacker news is an interesting idea. Not sure how much interest there would be for an Atom package.

I have no idea how they choose packages for round-ups. I guess I’ll send an email to someone. I’m not shy about things like this.


#11

Hacker news show tab is pretty cool, they don’t even make you verify email, just go post it, super easy. Anything that makes non atom users checkout atom is cool too.


#12

So I’m getting back into this, read your doc a little confused, do you recommend including the .live-archive in your git repo? Might be useful. Or definitely add it to the .gitignore? If the latter, maybe your package does / can add it there? An option for this maybe?

I think you should add a sentence to clarify this in the docs maybe.


#13

It shouldn’t be in a repo. It is not something that can be shared with others since it is your personal history of editing and you don’t want to blow away other’s personal history. I always manually add .live-archive to gitignore.

Git is for sharing, live-archive is for accessing the past. I used to access the past using git but I don’t need to anymore. Of course git does a lot other stuff besides sharing. Branching comes to mind first.

I don’t think I should provide a way to automatically add .live-archive to gitignore. Editing someone’s gitignore file isn’t a cool thing to do. However, adding a comment about this in the dialog that asks if they want to enable live-archive would be nice. I’ll add it to my to-do list.

Edit: And add it to the docs as you suggest.


#14

Yeah, after a few minutes of using it on a new repo, it became super clear it needs to be in the .gitignore with git diff etc of course :smile:

Yeah, I mean so like a feature to optionally add it would be cool no? It’s just a

echo “.live-archive” >> ./.gitignore

right? I mean yeah you’d probably need to do that a different way of course :slight_smile:


#15

I still don’t think it’s cool to touch the gitignore file. Do any other utilities do that?

Also, it’s not that hard to just avoid adding (staging) that folder. I just avoid adding it until I get the time to change gitignore.

It will be in the readme and the dialog box asking if they want to create the folder. Surely that’s enough.


#16

Yeah I just added .live-archive to my global gitignore file and so far that has been OK and convenient.

What if the package added its own .gitignore inside the .live-archive folder? I just tested and a .gitignore with only ‘**’ inside it seems to ignore everything within that subdirectory.

Doesn’t emacs have an auto-backup facility? I never did much with it beyond playing with the settings, but I expected more people would be interested in something like this really. There’s another package called “local-history” that seems similar at a glance, although the interface does not seem nearly as nice as the VCR-like interface on live-archive.

This package is so easy to use that it really does free you up. Instead of only searching through backup in those “oh shit!” moments, I’ll hit the keybinding and rewind a bit to see what crazy stuff I may have been thinking several minutes ago. Really nice.

I agree that the things that downloaded most in these early days are the packages that fill feature-gaps in atom compared to people’s favorite editors. This is one of those packages that I would expect to become more widely used as it is shared in curated selections of favorite packages, whether that be in atom’s package round-up blog, an HN post, or a “starter kit”-style distribution of packages and configs.


#17

Wow. That works. I didn’t know you could do this. That fixes everything. It’s on my to-do list.