zsh-users
 help / color / mirror / code / Atom feed
* Keeping dot files in sync
@ 2008-02-18  0:05 Thorsten Kampe
  2008-02-18  1:45 ` Bart Schaefer
  2008-02-18  2:17 ` Robert McLay
  0 siblings, 2 replies; 7+ messages in thread
From: Thorsten Kampe @ 2008-02-18  0:05 UTC (permalink / raw)
  To: zsh-users

Hi,

I have a problem keeping my configuration files (mainly .zshrc and 
.bashrc) in sync on multiple computers.

I've got a central computer where I mainly work and do my .zshrc 
changes. I need a program to propagate these changes to the other 
computers (mainly virtual machines) to have the same zsh configuration 
there.

Unfortunately my main workstation and the other PCs are not directly 
connected (otherwise I'd simply rsync the changes).

I have a server "on the Internet" that is accessible via http/WebDAV 
and ftp. So I could push the changed files to this server from my main 
system and pull the changed files from there on the other machines.

Does anyone know of an application (Revision control or something 
similar) that does this kind of task or assists in it?


Thorsten


^ permalink raw reply	[flat|nested] 7+ messages in thread

* Re: Keeping dot files in sync
  2008-02-18  0:05 Keeping dot files in sync Thorsten Kampe
@ 2008-02-18  1:45 ` Bart Schaefer
  2008-02-18  2:00   ` Richard Hartmann
  2008-02-18  3:51   ` Thorsten Kampe
  2008-02-18  2:17 ` Robert McLay
  1 sibling, 2 replies; 7+ messages in thread
From: Bart Schaefer @ 2008-02-18  1:45 UTC (permalink / raw)
  To: zsh-users

On Feb 18, 12:05am, Thorsten Kampe wrote:
}
} I've got a central computer where I mainly work and do my .zshrc 
} changes. I need a program to propagate these changes to the other 
} computers (mainly virtual machines) to have the same zsh configuration 
} there.
} 
} Unfortunately my main workstation and the other PCs are not directly 
} connected (otherwise I'd simply rsync the changes).

rsync -e ssh ...
 
} Does anyone know of an application (Revision control or something 
} similar) that does this kind of task or assists in it?

I use CVS for this; SVN or just about any revision control system
with networking support ought to do fine.  I check out everthing
into a ~/.zsh/ directory and run from there a little installer script
that pokes a ZDOTDIR setting into the ~/.zshenv, thus leaving intact
whatever the default skeleton was in case I need to revert.

I haven't tried doing an equivalent for bash.


^ permalink raw reply	[flat|nested] 7+ messages in thread

* Re: Keeping dot files in sync
  2008-02-18  1:45 ` Bart Schaefer
@ 2008-02-18  2:00   ` Richard Hartmann
  2008-02-18  3:51   ` Thorsten Kampe
  1 sibling, 0 replies; 7+ messages in thread
From: Richard Hartmann @ 2008-02-18  2:00 UTC (permalink / raw)
  To: Bart Schaefer; +Cc: zsh-users

On Feb 18, 2008 2:45 AM, Bart Schaefer <schaefer@brasslantern.com> wrote:

> I use CVS for this; SVN or just about any revision control system
> with networking support ought to do fine.  I check out everthing
> into a ~/.zsh/ directory and run from there a little installer script
> that pokes a ZDOTDIR setting into the ~/.zshenv, thus leaving intact
> whatever the default skeleton was in case I need to revert.

You could also have your install scripts move all files you intend to link from
the repository. This has the advantage that you have your own setup in place
and still enables you to revert/merge changes.


RIchard


^ permalink raw reply	[flat|nested] 7+ messages in thread

* Re: Keeping dot files in sync
  2008-02-18  0:05 Keeping dot files in sync Thorsten Kampe
  2008-02-18  1:45 ` Bart Schaefer
@ 2008-02-18  2:17 ` Robert McLay
  1 sibling, 0 replies; 7+ messages in thread
From: Robert McLay @ 2008-02-18  2:17 UTC (permalink / raw)
  To: zsh-users


On Mon, 2008-02-18 at 00:05 +0000, Thorsten Kampe wrote:
> Hi,
> 
> I have a problem keeping my configuration files (mainly .zshrc and 
> .bashrc) in sync on multiple computers.
> 
> I've got a central computer where I mainly work and do my .zshrc 
> changes. I need a program to propagate these changes to the other 
> computers (mainly virtual machines) to have the same zsh configuration 
> there.
> 
> Unfortunately my main workstation and the other PCs are not directly 
> connected (otherwise I'd simply rsync the changes).
> 
> I have a server "on the Internet" that is accessible via http/WebDAV 
> and ftp. So I could push the changed files to this server from my main 
> system and pull the changed files from there on the other machines.
> 
> Does anyone know of an application (Revision control or something 
> similar) that does this kind of task or assists in it?

I also keep my dot files in sync.   Since my computers are accessible on
the Net.  I use subversion.  I place my dot files in a sub-directory
and symbolically link to my home directory.

% ls -aF ~/.dotfiles

.bashrc    .zshrc .zshenv  .svn/

% ls -l ~/.bashrc

lrwxrwxrwx   ...     ~/.bashrc  -> .dotfiles/.bashrc

The .dotfiles directory is managed by subversion.  Any changes made on
any computer can checked-in.   To update any computer just requires a
"svn update" in the ~/.dotfiles directory.   If you have control of your
server "on the Internet" then you can run subversion via http or https.

You may also consider the distributive version control system that the
linux kernel uses namely "git".   You can have multiple repositories and
pass around "patch" or "diff"s around.  The diff's can be emailed.




^ permalink raw reply	[flat|nested] 7+ messages in thread

* Re: Keeping dot files in sync
  2008-02-18  1:45 ` Bart Schaefer
  2008-02-18  2:00   ` Richard Hartmann
@ 2008-02-18  3:51   ` Thorsten Kampe
  2008-02-18  4:14     ` Anonymous bin ich
  1 sibling, 1 reply; 7+ messages in thread
From: Thorsten Kampe @ 2008-02-18  3:51 UTC (permalink / raw)
  To: zsh-users

* Bart Schaefer (Sun, 17 Feb 2008 17:45:50 -0800)
> On Feb 18, 12:05am, Thorsten Kampe wrote:
> } I've got a central computer where I mainly work and do my .zshrc 
> } changes. I need a program to propagate these changes to the other 
> } computers (mainly virtual machines) to have the same zsh configuration 
> } there.
> } 
> } Unfortunately my main workstation and the other PCs are not directly 
> } connected (otherwise I'd simply rsync the changes).
> 
> rsync -e ssh ...

As I said: no rsync, no ssh on the Internet server, only http and ftp.
  
> } Does anyone know of an application (Revision control or something 
> } similar) that does this kind of task or assists in it?
> 
> I use CVS for this; SVN or just about any revision control system
> with networking support ought to do fine.

Can't be done when there is no CVS or SVN at the side where you want 
to upload.

I figured out that sitecopy[1] is probably the best choice:

1. I symlink all the files I want to synchronize into an empty 
directory ("ln -s ~/.zshrc ~/.sitecopy/sync/.zshrc"), then

2. I sync this directory to the WebDAV server ("sitecopy -u mysite")

3. Sync from the WebDAV server on the remote side into 
~/.sitecopy/sync: "sitecopy -f mysite && sitecopy -s mysite"
(can't use ~ (the real target) because sitecopy would delete all the 
other files in ~)

4. and then rsync all the files from ~/.sitecopy/sync to ~

Done


Thorsten
[1] http://www.manyfish.co.uk/sitecopy/why.html


^ permalink raw reply	[flat|nested] 7+ messages in thread

* Re: Keeping dot files in sync
  2008-02-18  3:51   ` Thorsten Kampe
@ 2008-02-18  4:14     ` Anonymous bin ich
  2008-02-18  4:24       ` William Scott
  0 siblings, 1 reply; 7+ messages in thread
From: Anonymous bin ich @ 2008-02-18  4:14 UTC (permalink / raw)
  To: Thorsten Kampe; +Cc: zsh-users

On Feb 18, 2008 4:51 AM, Thorsten Kampe <thorsten@thorstenkampe.de> wrote:
> * Bart Schaefer (Sun, 17 Feb 2008 17:45:50 -0800)
> > On Feb 18, 12:05am, Thorsten Kampe wrote:
> > } I've got a central computer where I mainly work and do my .zshrc
> > } changes. I need a program to propagate these changes to the other
> > } computers (mainly virtual machines) to have the same zsh configuration
> > } there.
> > }
> > } Unfortunately my main workstation and the other PCs are not directly
> > } connected (otherwise I'd simply rsync the changes).
> >
> > rsync -e ssh ...
>
> As I said: no rsync, no ssh on the Internet server, only http and ftp.
>
> > } Does anyone know of an application (Revision control or something
> > } similar) that does this kind of task or assists in it?
> >
> > I use CVS for this; SVN or just about any revision control system
> > with networking support ought to do fine.
>
> Can't be done when there is no CVS or SVN at the side where you want
> to upload.
>
> I figured out that sitecopy[1] is probably the best choice:
>
> 1. I symlink all the files I want to synchronize into an empty
> directory ("ln -s ~/.zshrc ~/.sitecopy/sync/.zshrc"), then
>
> 2. I sync this directory to the WebDAV server ("sitecopy -u mysite")
>
> 3. Sync from the WebDAV server on the remote side into
> ~/.sitecopy/sync: "sitecopy -f mysite && sitecopy -s mysite"
> (can't use ~ (the real target) because sitecopy would delete all the
> other files in ~)
>
> 4. and then rsync all the files from ~/.sitecopy/sync to ~
>
> Done
>
>
> Thorsten
> [1] http://www.manyfish.co.uk/sitecopy/why.html
>
>
I used to use SVN for this purpose, though I have my home directory
mounted as NFS over a network. Recently I have switched to git. Here
is what I think can be done.
1) Create a remote directory. In this case, it is created in my /tmp
directory, or anywher. I just want to create a barebone repository.
2) Push everything to this repository.
3) upload this directory to your server

This will in effect create a remote repository. You have to do it only
once. Then add this http repository as remote. Now you can push and
pull all you want.

It probably needs webdav support. But I guess you have it already.

Ref.:
http://www.kernel.org/pub/software/scm/git/docs/howto/setup-git-server-over-http.txt
-- 
Regards,


^ permalink raw reply	[flat|nested] 7+ messages in thread

* Re: Keeping dot files in sync
  2008-02-18  4:14     ` Anonymous bin ich
@ 2008-02-18  4:24       ` William Scott
  0 siblings, 0 replies; 7+ messages in thread
From: William Scott @ 2008-02-18  4:24 UTC (permalink / raw)
  To: zsh-users

Another option is unison

http://www.cis.upenn.edu/~bcpierce/unison/

Anonymous bin ich wrote:
> On Feb 18, 2008 4:51 AM, Thorsten Kampe <thorsten@thorstenkampe.de> wrote:
>> * Bart Schaefer (Sun, 17 Feb 2008 17:45:50 -0800)
>> > On Feb 18, 12:05am, Thorsten Kampe wrote:
>> > } I've got a central computer where I mainly work and do my .zshrc
>> > } changes. I need a program to propagate these changes to the other
>> > } computers (mainly virtual machines) to have the same zsh
>> configuration
>> > } there.
>> > }
>> > } Unfortunately my main workstation and the other PCs are not directly
>> > } connected (otherwise I'd simply rsync the changes).
>> >
>> > rsync -e ssh ...
>>
>> As I said: no rsync, no ssh on the Internet server, only http and ftp.
>>
>> > } Does anyone know of an application (Revision control or something
>> > } similar) that does this kind of task or assists in it?
>> >
>> > I use CVS for this; SVN or just about any revision control system
>> > with networking support ought to do fine.
>>
>> Can't be done when there is no CVS or SVN at the side where you want
>> to upload.
>>
>> I figured out that sitecopy[1] is probably the best choice:
>>
>> 1. I symlink all the files I want to synchronize into an empty
>> directory ("ln -s ~/.zshrc ~/.sitecopy/sync/.zshrc"), then
>>
>> 2. I sync this directory to the WebDAV server ("sitecopy -u mysite")
>>
>> 3. Sync from the WebDAV server on the remote side into
>> ~/.sitecopy/sync: "sitecopy -f mysite && sitecopy -s mysite"
>> (can't use ~ (the real target) because sitecopy would delete all the
>> other files in ~)
>>
>> 4. and then rsync all the files from ~/.sitecopy/sync to ~
>>
>> Done
>>
>>
>> Thorsten
>> [1] http://www.manyfish.co.uk/sitecopy/why.html
>>
>>
> I used to use SVN for this purpose, though I have my home directory
> mounted as NFS over a network. Recently I have switched to git. Here
> is what I think can be done.
> 1) Create a remote directory. In this case, it is created in my /tmp
> directory, or anywher. I just want to create a barebone repository.
> 2) Push everything to this repository.
> 3) upload this directory to your server
>
> This will in effect create a remote repository. You have to do it only
> once. Then add this http repository as remote. Now you can push and
> pull all you want.
>
> It probably needs webdav support. But I guess you have it already.
>
> Ref.:
> http://www.kernel.org/pub/software/scm/git/docs/howto/setup-git-server-over-http.txt
> --
> Regards,
>


^ permalink raw reply	[flat|nested] 7+ messages in thread

end of thread, other threads:[~2008-02-18  4:24 UTC | newest]

Thread overview: 7+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2008-02-18  0:05 Keeping dot files in sync Thorsten Kampe
2008-02-18  1:45 ` Bart Schaefer
2008-02-18  2:00   ` Richard Hartmann
2008-02-18  3:51   ` Thorsten Kampe
2008-02-18  4:14     ` Anonymous bin ich
2008-02-18  4:24       ` William Scott
2008-02-18  2:17 ` Robert McLay

Code repositories for project(s) associated with this public inbox

	https://git.vuxu.org/mirror/zsh/

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).