LXF 165: Typos in Unison Tutorial

Comments, suggestions and questions about Linux Format magazine and the coverdiscs

Moderators: ChrisThornett, LXF moderators

LXF 165: Typos in Unison Tutorial

Postby maverickprowls » Sat Nov 10, 2012 12:01 pm

Hi there,

I've been running through James Litton's excellent Unison tutorial, and I've got everything working beautifully, synchronising a folder on 3 machines with a central server. I'd been trying to roll my own solution with rsync for a couple of weeks without much luck, so the tutorial was perfectly timed.

I noticed two things in the shell script provided in the article. One I know is a typo, the other was my mistake, but is down to the poor differentiation between 1 and l in the font used for code in the article.

Line 11 of the script
Code: Select all
if [${stst:0:7}] == "Nothing"]; then

should be
Code: Select all
if [${stat:0:7}] == "Nothing"]; then


However, when I initially copied out the script, I noticed that I was getting a notification even when the script had nothing to do. After a bit of poking around I realised that line 6 ends with
Code: Select all
tail -1
but I had written
Code: Select all
tail -l
with the letter L. After I made this correction, the script worked correctly.

Once again, many thanks for a really useful tutorial, and I hope the above helps anyone else who's having trouble getting this working.
maverickprowls
 
Posts: 3
Joined: Thu Jan 11, 2007 7:07 pm

Postby guttagrynna » Thu Nov 15, 2012 8:58 pm

Thnks for this post. I ran the tutorial myself today, and got the sam two errors in my code. Correcting the second one makes no difference that I can detect, though. Which is odd and worrying.

I have used unison the manual way before, which has been working as expected. My problem now is that in batch mode it doesn't handle deletes right. If I delete a file on one computer it gets copied from the server on sync. I have version 2.32 (as opposed to 2.40) running - could it be an explanation?
guttagrynna
 
Posts: 3
Joined: Thu Nov 15, 2012 8:41 pm
Location: Stockholm, Sweden


Return to Magazine and coverdiscs

Who is online

Users browsing this forum: Bing [Bot], Exabot [Bot] and 3 guests