<?xml version="1.0" encoding="UTF-8"?>
<feed xmlns="http://www.w3.org/2005/Atom">

    <title>Live Version</title>
    <generator uri="https://github.com/jekyll/jekyll">Jekyll v3.10.0</generator>
		<icon>https://anupam-arohi.github.io/lv/apple-touch-icon-precomposed.png</icon>
    <subtitle>An insurance system for your precious work!</subtitle>
    <link href="https://anupam-arohi.github.io/lv/atom.xml" rel="self"/>
    <link href="https://anupam-arohi.github.io/lv/" rel="alternate" type="text/html"/>
    <updated>2026-08-02T18:08:29+00:00</updated>
    <id>https://anupam-arohi.github.io/lv/</id>
    <author>
			<name>Anupam Arohi</name>
			<uri>https://anupam-arohi.github.io/lv/</uri>
			<email>arohi.misc@gmail.com</email>
		</author>

    
    <entry>
        <title>Philosophy</title>
        <link href="https://anupam-arohi.github.io/lv/documentation/Philosophy/"/>
        <updated>2014-11-17T14:30:00+00:00</updated>
        <id>https://anupam-arohi.github.io/lv/documentation/Philosophy</id>
        <author>
					<name>Anupam Arohi</name>
					<uri>https://anupam-arohi.github.io/lv/</uri>
					<email>arohi.misc@gmail.com</email>
				</author>
        <content type="html">
        	
        	&lt;p&gt;For someone who uses git or any other source control regularly, it may be very unusual approach. After all they made commit message mandatory for a reason! If we take a shift from this and look at how our mind works, we may be able to appreciate the philosophy behind live version. When we are in the flow, we want and need complete freedom - no distractions and no fear at all. Making those small commits is a distraction, not making them induces fear of losing good work.&lt;/p&gt;

&lt;p&gt;Live version makes those small commits for you with a message of timestamp; hence no distraction of writing commit message. Since all small changes are synchronized and committed, there is no fear of loss. This facilitates complete flow in doing your work.&lt;/p&gt;


        </content>
    </entry>
    
    <entry>
        <title>Theory</title>
        <link href="https://anupam-arohi.github.io/lv/documentation/Theory/"/>
        <updated>2014-11-17T14:30:00+00:00</updated>
        <id>https://anupam-arohi.github.io/lv/documentation/Theory</id>
        <author>
					<name>Anupam Arohi</name>
					<uri>https://anupam-arohi.github.io/lv/</uri>
					<email>arohi.misc@gmail.com</email>
				</author>
        <content type="html">
        	&lt;img src=&quot;https://anupam-arohi.github.io/lv/images/lv-overview.png&quot;&gt;&lt;br/&gt;
        	&lt;p&gt;&lt;a href=&quot;/lv/images/lv-situation.png&quot;&gt;&lt;img src=&quot;/lv/images/lv-situation.png&quot; alt=&quot;&quot; /&gt;&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;The blocks in the picture above describe a situation my friends and I get into many times while coding. Of course, we use &lt;a href=&quot;https://en.wikipedia.org/wiki/Revision_control&quot;&gt;version control&lt;/a&gt; but then not every small change is worth a team commit: a commit with a message that meaningfully represents the change, and the whole effort of making that commit.&lt;/p&gt;

&lt;p&gt;Earlier, while experimenting with code, I used to comment some sections of the code, even make copies of code files. That all created more chaos rather than help me write neat and brief code and experiment at the same time. Then I started keeping a personal backup repository of my code and made commits there for small changes, but then again it was lot of manual work. Eventually, it gave birth to the Live Version or LV.&lt;/p&gt;

&lt;p&gt;You can definitely benefit from LV if you code in any computer language or write text documents (like latex files) on regular basis. Most visual git clients like &lt;a href=&quot;https://www.sourcetreeapp.com&quot;&gt;Source Tree&lt;/a&gt; let you see the differences between each commit.&lt;/p&gt;

&lt;p&gt;LV is a shell script, and there are a few helping scripts in the system. If you are not comfy with command line interface, you may want to get some help in setting the system up for you. Once it is setup, you can use it without command line.&lt;/p&gt;

&lt;h2 id=&quot;features&quot;&gt;Features&lt;/h2&gt;

&lt;p&gt;&lt;a href=&quot;/lv/images/lv-features.png&quot;&gt;&lt;img src=&quot;/lv/images/lv-features.png&quot; alt=&quot;&quot; /&gt;&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;Personal&lt;/strong&gt;: Live Version is made for your own personal use. It is for you and you only, you can do all play with your work, and that is being recorded in the Live Repository for you to look back in need. Your team mates have no business in your Live Repository. Your team commits are not impacted with Live Version.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;Automatic&lt;/strong&gt;: Once you setup LV for a specific folder, the versioning is alive. There is no manual labor involved in maintaining the backups.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;Git&lt;/strong&gt;: Yes, it uses git. But you can use any versioning system for your code in your source code folder. Or, no versioning system at all, like I do for some small home projects. I count on LV to do the versioning for me.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;Backup&lt;/strong&gt;: It is a backup system, a separate folder contains Live Repository. It does not in any way manipulate your source folder. It is also an automatic backup of your code, so you always know that you have an updated backup copy of your code.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;Timeline&lt;/strong&gt;: LV maintains a timeline for you. You can use LV to track how much time  you spent on recent coding. Just check the timestamps on commits of a day, to get an idea. It also helps you in making a meaningful team commit message when you can look thru all the changes made in certain time frame.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;Peace of Mind&lt;/strong&gt;: Knowing that all my changes are versioned gives me immense peace of mind. It gives me freedom to try out bizarre ideas and experiment more. I do not comment code lines anymore, I do not make zip copies my source folder anymore. With Live Version, it is super easy to recover a recent piece of work.&lt;/p&gt;

&lt;h2 id=&quot;overview&quot;&gt;Overview&lt;/h2&gt;

&lt;p&gt;&lt;a href=&quot;/lv/images/lv-overview.png&quot;&gt;&lt;img src=&quot;/lv/images/lv-overview.png&quot; alt=&quot;&quot; /&gt;&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;Live Version extensively uses git branching and squashing to keep your live repository  lean and up to date. When we use LV, we give a source folder and a destination folder. Source folder has your code and destination folder is where live repository would be maintained. In the picture above, the line with source represents source folder over time and small dots represent granular changes. These dots can be further classified as changes belonging to a certain day based on the color of the dots. The lines, today, previous day, this week, previous week and master represent git branches in Live Repository.&lt;/p&gt;

&lt;p&gt;When you make any change on your source folder, it is automatically synchronized with the live repository. That change is then recorded as a commit. Depending on how many times you update files in the source, you can have from zero to hundreds of commits in a day. All these commits belong to the branch of that day and are marked with time-stamp. When in need, you can go back to any of these commits and recover your precious piece of work.&lt;/p&gt;

&lt;p&gt;Next day, when you start working (i.e. making changes to your source folder), all these changes from the previous day are squashed as a single change into the current week’s branch. The branch for the previous day is still there, you can refer back to it if needed. In addition, this week’s branch has a new commit that represents the combination of all the changes from the previous day. In other words, it represents how your work looked like after the last change was made on the the previous day.&lt;/p&gt;

&lt;p&gt;If the this next day marks the beginning of a new week, all daily squashes of the previous week would be squashed into master branch showing how your work looked like at the end of the previous week. In this way, you’ll always have granular changes from today and the the previous day. You’ll have ‘end of day’ snapshots for the current week and the previous week; and ‘end of week’ snapshots for all the weeks.&lt;/p&gt;

&lt;h2 id=&quot;walkthrough&quot;&gt;Walkthrough&lt;/h2&gt;

&lt;p&gt;The Overview section gave a big picture of how LV works. To understand it better, lets walk through together over a concrete example where Sam starts to use lv for his project on Sep 9th, 2014:&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;First Day&lt;/strong&gt;: After setup, lv is first used on Sep 9, 2014 (week 37):
3 changes are made on the same day. That is when the live repository would look like this:
&lt;a href=&quot;/lv/images/lv-day1.png&quot;&gt;&lt;img src=&quot;/lv/images/lv-day1.png&quot; alt=&quot;&quot; /&gt;&lt;/a&gt;
In this context, each change is synchronized and committed on 9-Sep-2014 branch.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;Another day&lt;/strong&gt;: More changes are made in the source on say, 10-Sep-2014; live repository looks like this:
&lt;a href=&quot;/lv/images/lv-day2.png&quot;&gt;&lt;img src=&quot;/lv/images/lv-day2.png&quot; alt=&quot;&quot; /&gt;&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;when the system recognized change in the day (date), it created a squash commit on W37-2014 branch, representing a combined change for 9-Sep-2014 branch. LV also created another branch for the day, i.e. 10-Sep-2014. All changes on the day are recorded on 10-Sep-2014 branch.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;Yet another day&lt;/strong&gt;: Let’s say that the next day Sam works on the source is Sep 13th. There are already 2 branches in live repository representing daily granular changes. Let’s see what happens in two steps:
&lt;a href=&quot;/lv/images/lv-day3-prep.png&quot;&gt;&lt;img src=&quot;/lv/images/lv-day3-prep.png&quot; alt=&quot;&quot; /&gt;&lt;/a&gt;
&lt;em&gt;Step 1&lt;/em&gt;: Granular changes of 9-Sep-2014 are disposed off, i.e. the branch is deleted. However, the squash commit on W37-2014 branch still remains, preserving ‘end of day’ state of Sep 9th. And then:
&lt;a href=&quot;/lv/images/lv-day3.png&quot;&gt;&lt;img src=&quot;/lv/images/lv-day3.png&quot; alt=&quot;&quot; /&gt;&lt;/a&gt;
&lt;em&gt;Step 2&lt;/em&gt;: A branch is created for Sep 13th and all changes of the day are recorded there.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;What’s next?&lt;/strong&gt;: What’ll happen when Sam works next week on Sep 15th? Following steps describe the situation:
&lt;a href=&quot;/lv/images/lv-day4.png&quot;&gt;&lt;img src=&quot;/lv/images/lv-day4.png&quot; alt=&quot;&quot; /&gt;&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;&lt;em&gt;Step 1&lt;/em&gt;: Branch 10-Sep-2014 is deleted.&lt;/p&gt;

&lt;p&gt;&lt;em&gt;Step 2&lt;/em&gt;: All changes from branch 13-Sep-2014 are squashed on the W-37-2014 branch.&lt;/p&gt;

&lt;p&gt;&lt;em&gt;Step 3&lt;/em&gt;: Since it’s a change in the week, all changes on the previous week, i.e. W-37-2014 branch are squashed on the master branch.&lt;/p&gt;

&lt;p&gt;&lt;em&gt;Step 4&lt;/em&gt;: A new branch for the current week, i.e. W-38-2014 is spawned from the master branch.&lt;/p&gt;

&lt;p&gt;&lt;em&gt;Step 5&lt;/em&gt;: A new branch, 15-Sep-2014 is spawned from W-38-2014 branch.&lt;/p&gt;

&lt;p&gt;&lt;em&gt;Step 6&lt;/em&gt;: All changes on 15th Sep are synchronized and committed to the branch 15-Sep-2014.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;Summary&lt;/strong&gt;: Live Version keeps weekly snapshots on master branch permanently. It keeps current week and previous week branches which have daily snapshots respectively. In addition, it maintains two branches: one for today and one for previous day for recovering granular changes.&lt;/p&gt;


        </content>
    </entry>
    
    <entry>
        <title>Meet the scripts</title>
        <link href="https://anupam-arohi.github.io/lv/documentation/Scripts/"/>
        <updated>2014-11-16T14:30:00+00:00</updated>
        <id>https://anupam-arohi.github.io/lv/documentation/Scripts</id>
        <author>
					<name>Anupam Arohi</name>
					<uri>https://anupam-arohi.github.io/lv/</uri>
					<email>arohi.misc@gmail.com</email>
				</author>
        <content type="html">
        	&lt;img src=&quot;https://anupam-arohi.github.io/lv/images/lv-pragmatics.png&quot;&gt;&lt;br/&gt;
        	&lt;p&gt;In this section I’ll tell at length about cutomizing and configuring Live Version to suit your needs. It requires familiarity with terminal, and unix commands.&lt;/p&gt;

&lt;h2 id=&quot;whats-in-the-box&quot;&gt;What’s in the box?&lt;/h2&gt;

&lt;p&gt;When you download Live Version, you’ll get following:&lt;/p&gt;

&lt;ol&gt;
  &lt;li&gt;
    &lt;p&gt;&lt;strong&gt;setup&lt;/strong&gt; - one time execution script to setup the scripts in &lt;code class=&quot;language-plaintext highlighter-rouge&quot;&gt;$HOME/bin&lt;/code&gt; folder and set its path. So you don’t need root access to setup.&lt;/p&gt;
  &lt;/li&gt;
  &lt;li&gt;
    &lt;p&gt;&lt;strong&gt;lv&lt;/strong&gt; - core of live versioning logic.&lt;/p&gt;
  &lt;/li&gt;
  &lt;li&gt;
    &lt;p&gt;&lt;strong&gt;watch&lt;/strong&gt; - very handy utility script that would configure automatic watch for a folder you want to version live.&lt;/p&gt;
  &lt;/li&gt;
  &lt;li&gt;
    &lt;p&gt;&lt;strong&gt;unwatch&lt;/strong&gt; - it’ll only set off the automatic watch but the live repository would still persist unless you delete it manually on Mac OS X. On Linux, you’ll need to edit respective files yourself.&lt;/p&gt;
  &lt;/li&gt;
&lt;/ol&gt;

&lt;h2 id=&quot;configuration-for-watch-script&quot;&gt;Configuration for watch script&lt;/h2&gt;

&lt;p&gt;If you’re like me and find watch script handy, the first time you execute it, it asks you some details. These details are:&lt;/p&gt;

&lt;ol&gt;
  &lt;li&gt;Root path of all live repositories. Stored in &lt;code class=&quot;language-plaintext highlighter-rouge&quot;&gt;$HOME/.LiveVersion/lv_base&lt;/code&gt;.&lt;/li&gt;
  &lt;li&gt;Root path of all log files. Stored in &lt;code class=&quot;language-plaintext highlighter-rouge&quot;&gt;$HOME/.LiveVersion/log_base&lt;/code&gt;.&lt;/li&gt;
  &lt;li&gt;Email address that’ll receive the log each time lv is executed. Stored in &lt;code class=&quot;language-plaintext highlighter-rouge&quot;&gt;$HOME/.LiveVersion/email&lt;/code&gt;.&lt;/li&gt;
&lt;/ol&gt;

&lt;p&gt;You can manually edit these files to change the configuration.&lt;/p&gt;

&lt;p&gt;&lt;em&gt;Note:&lt;/em&gt; This configuration is used only by watch script. &lt;strong&gt;lv&lt;/strong&gt; takes these details as command line arguments.&lt;/p&gt;

&lt;h2 id=&quot;customizing-exclusions&quot;&gt;Customizing exclusions&lt;/h2&gt;

&lt;p&gt;You can configure which files and folders to exclude from synchronizing. You can configure it for a specific Live Repository or for all Live Repositories.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;For specific Live Repository&lt;/strong&gt;&lt;/p&gt;

&lt;p&gt;In order to configure exclusions for specific Live Repository, go to &lt;code class=&quot;language-plaintext highlighter-rouge&quot;&gt;.lv&lt;/code&gt; folder in that live repository and edit file named &lt;code class=&quot;language-plaintext highlighter-rouge&quot;&gt;exclude_rsync&lt;/code&gt;&lt;/p&gt;

&lt;p&gt;&lt;a href=&quot;/lv/images/lv-exclude-rsync-file.png&quot;&gt;&lt;img src=&quot;/lv/images/lv-exclude-rsync-file.png&quot; alt=&quot;&quot; /&gt;&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;You can add as many lines as you like using rsync exclude syntax. Run &lt;code class=&quot;language-plaintext highlighter-rouge&quot;&gt;man rsync&lt;/code&gt; and check &lt;code class=&quot;language-plaintext highlighter-rouge&quot;&gt;exclude-from FILE&lt;/code&gt; format for more details.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;For all Live Repositories&lt;/strong&gt;&lt;/p&gt;

&lt;p&gt;In this case, edit lv from &lt;code class=&quot;language-plaintext highlighter-rouge&quot;&gt;$HOME/bin&lt;/code&gt; folder (assuming that you already ran &lt;code class=&quot;language-plaintext highlighter-rouge&quot;&gt;source setup&lt;/code&gt;).&lt;/p&gt;

&lt;p&gt;&lt;a href=&quot;/lv/images/lv-exclude-rsync.png&quot;&gt;&lt;img src=&quot;/lv/images/lv-exclude-rsync.png&quot; alt=&quot;&quot; /&gt;&lt;/a&gt;&lt;/p&gt;

&lt;h2 id=&quot;keeping-certain-branch-for-eternity&quot;&gt;Keeping certain branch for eternity&lt;/h2&gt;

&lt;p&gt;What if you made some exceptional changes today and you want to keep the granular change record?
Yes, you can do it in following steps:&lt;/p&gt;

&lt;ol&gt;
  &lt;li&gt;Go to &lt;code class=&quot;language-plaintext highlighter-rouge&quot;&gt;.lv&lt;/code&gt; folder within your Live Repository.&lt;/li&gt;
  &lt;li&gt;Run &lt;code class=&quot;language-plaintext highlighter-rouge&quot;&gt;git branch&lt;/code&gt; to see which branch you want to keep.&lt;/li&gt;
  &lt;li&gt;Execute &lt;code class=&quot;language-plaintext highlighter-rouge&quot;&gt;echo &quot;branch_name&quot; &amp;gt;&amp;gt; keep_branch_always&lt;/code&gt;. Where &lt;code class=&quot;language-plaintext highlighter-rouge&quot;&gt;branch_name&lt;/code&gt; is the actual name of the branch you want to keep.&lt;/li&gt;
&lt;/ol&gt;


        </content>
    </entry>
    
    <entry>
        <title>Recovery</title>
        <link href="https://anupam-arohi.github.io/lv/documentation/Recovery/"/>
        <updated>2014-11-15T14:30:00+00:00</updated>
        <id>https://anupam-arohi.github.io/lv/documentation/Recovery</id>
        <author>
					<name>Anupam Arohi</name>
					<uri>https://anupam-arohi.github.io/lv/</uri>
					<email>arohi.misc@gmail.com</email>
				</author>
        <content type="html">
        	&lt;img src=&quot;https://anupam-arohi.github.io/lv/images/lv-recovery.png&quot;&gt;&lt;br/&gt;
        	&lt;p&gt;How do you I recover my work after a glitch or a goof-up?  I’ll explain that here with an example:&lt;/p&gt;

&lt;p&gt;On November 3rd, 2014. I had an impression that Apple fixed working of mailx within launch agents.
So, I wrote additional code to support emailing logs via Live Version. Later when I tested, I realized its not really fixed. In frustration, 
I threw away the functionality.&lt;/p&gt;

&lt;p&gt;After a while, I thought, well, Apple may support it or not, LV can still support it so people using LV via make files or other build scripts can leverage the functionality. Normally, I had to write that feature all over again! Since I track Live Version using Live Version, I receovered the feature.
This is how:&lt;/p&gt;

&lt;ol&gt;
  &lt;li&gt;Went to 3-Nov-2014 end of the day commit in Live Repository of LV.&lt;/li&gt;
  &lt;li&gt;Checked out that commit (53a3711)).&lt;/li&gt;
  &lt;li&gt;Copied lv from live repository to a temp location.&lt;/li&gt;
  &lt;li&gt;Tested lv against all test cases.&lt;/li&gt;
  &lt;li&gt;Copied lv to the original location.&lt;/li&gt;
  &lt;li&gt;Voila!&lt;/li&gt;
&lt;/ol&gt;

&lt;p&gt;Simplest way to recover your work is to look at it in Live Repository using a graphical git client, like &lt;a href=&quot;https://www.sourcetreeapp.com&quot;&gt;source tree&lt;/a&gt;.
There you can easily see the changes between commits. At times, you’ll just need to see the change and nothing else.&lt;/p&gt;

&lt;p&gt;If you feel lost and it’s challenging to find the commit you’re looking for, try &lt;a href=&quot;https://stackoverflow.com/questions/1337320/how-to-grep-git-commit-diffs-or-contents-for-a-certain-word&quot;&gt;&lt;code class=&quot;language-plaintext highlighter-rouge&quot;&gt;git log -p -SWord&lt;/code&gt;&lt;/a&gt; from command line.
For example, in this case described above, I’ll execute &lt;code class=&quot;language-plaintext highlighter-rouge&quot;&gt;git log -p -SEmail&lt;/code&gt;.&lt;/p&gt;


        </content>
    </entry>
    
    <entry>
        <title>Time Line</title>
        <link href="https://anupam-arohi.github.io/lv/documentation/Timeline/"/>
        <updated>2014-11-14T14:30:00+00:00</updated>
        <id>https://anupam-arohi.github.io/lv/documentation/Timeline</id>
        <author>
					<name>Anupam Arohi</name>
					<uri>https://anupam-arohi.github.io/lv/</uri>
					<email>arohi.misc@gmail.com</email>
				</author>
        <content type="html">
        	&lt;img src=&quot;https://anupam-arohi.github.io/lv/images/lv-timeline.png&quot;&gt;&lt;br/&gt;
        	&lt;p&gt;I often want to know and track the time I spent on developing certain feature. With live version, this is extremely easy.
Just look at the commit time stamps in the Live Repository.&lt;/p&gt;

&lt;p&gt;For example, in the picture above, I worked on lv on 18th November from 14:40 till 15:23. Then again, on the 22nd from 10:45 till 11:06.
Yeah, sometimes I work in very small chunks and think that I spent hours doing a feature, with Live Version, there is no escape from reality.&lt;/p&gt;

&lt;p&gt;It is specially useful feature if you’re developing professionally and billing on time.&lt;/p&gt;


        </content>
    </entry>
    
</feed>