Help!

looking for editors with automatic diff (cvs) support


Post new topic   General Reply to Topic (not reply to a specific post)    Forums Home -> General Discussions (archive 1) RSS
Next:  Stats comp.os.linux.misc (last 7 days)  
Author Message
FangQ
External


Since: May 07, 2006
Posts: 2



PostPosted: Sun May 07, 2006 4:05 pm    Post subject: looking for editors with automatic diff (cvs) support
Archived from groups: comp>editors, others (more info?)

hi

I am looking for an text editor under GNU/Linux with the following
features:

1. when saving a text file, automatically do a diff with its
pre-modified verion and save the output to a file (for example
filename.diff)

2. if a text file has the corresponding diff file, this editor allow
users to switch between all saved "versions".

3. provide some tools to merge multiple diff file if the file were
edited at multiple computers (optional)

basically, the goal is to have a good version control to my program,
but I haven't got use to cvs, if there is such an editor can do the
job, I would be very happy.

thank you and eager to learn your feedback.

Qianqian
Back to top
jindi.li
External


Since: May 07, 2006
Posts: 1



PostPosted: Sun May 07, 2006 5:40 pm    Post subject: Re: looking for editors with automatic diff (cvs) support [Login to view extended thread Info.]
Archived from groups: per prev. post (more info?)

try TortoiseSVN,easy to use yet powerful

since all it's operations are controlled through command line
parameters .so you can easily integrate it with gvim.
Back to top
FangQ
External


Since: May 07, 2006
Posts: 2



PostPosted: Sun May 07, 2006 7:05 pm    Post subject: Re: looking for editors with automatic diff (cvs) support [Login to view extended thread Info.]
Archived from groups: per prev. post (more info?)

thanks for all your replies. it was actually my question confusing Smile

in another word, I want to keep all modifications of my codes, but
don't want to do "check in" "check out" stuff with cvs commands. As
Grant mentioned ealier, I am looking for editors integrated with simple
CVS-like features (as a built-in feature is preferred).

seems TortoiseSVN only has windows version?
Back to top
John Hasler
External


Since: Mar 25, 2004
Posts: 1319



PostPosted: Sun May 07, 2006 7:31 pm    Post subject: Re: looking for editors with automatic diff (cvs) support [Login to view extended thread Info.]
Archived from groups: comp>os>linux>misc (more info?)

Dan Espen writes:
> Sounds like you want to use CVS but you don't want to use CVS.

Sounds to me like he wants to use Emacs with one of its CVS modes.
--
John Hasler
john RemoveThis @dhh.gt.org
Dancing Horse Hill
Elmwood, WI USA
Back to top
Dan Espen
External


Since: Jan 16, 2006
Posts: 495



PostPosted: Sun May 07, 2006 7:52 pm    Post subject: Re: looking for editors with automatic diff (cvs) support [Login to view extended thread Info.]
Archived from groups: comp>editors, others (more info?)

"FangQ" <fangqq.DeleteThis@gmail.com> writes:

> hi
>
> I am looking for an text editor under GNU/Linux with the following
> features:
>
> 1. when saving a text file, automatically do a diff with its
> pre-modified verion and save the output to a file (for example
> filename.diff)
>
> 2. if a text file has the corresponding diff file, this editor allow
> users to switch between all saved "versions".
>
> 3. provide some tools to merge multiple diff file if the file were
> edited at multiple computers (optional)
>
> basically, the goal is to have a good version control to my program,
> but I haven't got use to cvs, if there is such an editor can do the
> job, I would be very happy.

Sounds like you want to use CVS but you don't want to use CVS.

Is it me that is confused or is it you?
Back to top
Grant Edwards
External


Since: Jun 08, 2004
Posts: 1264



PostPosted: Mon May 08, 2006 12:52 am    Post subject: Re: looking for editors with automatic diff (cvs) support [Login to view extended thread Info.]
Archived from groups: per prev. post (more info?)

On 2006-05-07, FangQ <fangqq.DeleteThis@gmail.com> wrote:

> basically, the goal is to have a good version control to my program,

Then use a version control system.

> but I haven't got use to cvs,

Then use SVN.

> if there is such an editor can do the job, I would be very
> happy.

There quite a few programming editors that have integrated CVS
and/or SVN support.

--
Grant Edwards
grante.DeleteThis@visi.com
Back to top
bakert
External


Since: May 08, 2006
Posts: 1



PostPosted: Mon May 08, 2006 2:02 am    Post subject: Re: looking for editors with automatic diff (cvs) support [Login to view extended thread Info.]
Archived from groups: per prev. post (more info?)

Perhaps you can use autocmd in your vim configuration file to call

!cvs commit -m "..."

when you save a file

????

Seems a bit crazy but could possibly work.

What's the problem with CVS/svn?
Back to top
Dan Espen
External


Since: Jan 16, 2006
Posts: 495



PostPosted: Mon May 08, 2006 9:21 am    Post subject: Re: looking for editors with automatic diff (cvs) support [Login to view extended thread Info.]
Archived from groups: per prev. post (more info?)

"FangQ" <fangqq.RemoveThis@gmail.com> writes:

> thanks for all your replies. it was actually my question confusing Smile
>
> in another word, I want to keep all modifications of my codes, but
> don't want to do "check in" "check out" stuff with cvs commands. As
> Grant mentioned ealier, I am looking for editors integrated with simple
> CVS-like features (as a built-in feature is preferred).

"Keeping all modifications" still doesn't make sense to me.

If you type a letter and then hit backspace, do you want to keep
that? I think not.

Take a look at emacs (or XEmacs). Using CVS (or SCCS, or RCS),
you can do a delta with a few keystrokes.
Back to top
Grant
External


Since: Jan 04, 2006
Posts: 622



PostPosted: Mon May 08, 2006 10:02 am    Post subject: Re: looking for editors with automatic diff (cvs) support [Login to view extended thread Info.]
Archived from groups: comp>os>linux>misc (more info?)

On Sun, 07 May 2006 19:52:04 -0400, Dan Espen <daneNO RemoveThis @MORE.mk.SPAMtelcordia.com> wrote:

>"FangQ" <fangqq RemoveThis @gmail.com> writes:
>
>> hi
>>
>> I am looking for an text editor under GNU/Linux with the following
>> features:
>>
>> 1. when saving a text file, automatically do a diff with its
>> pre-modified verion and save the output to a file (for example
>> filename.diff)
>>
>> 2. if a text file has the corresponding diff file, this editor allow
>> users to switch between all saved "versions".
>>
>> 3. provide some tools to merge multiple diff file if the file were
>> edited at multiple computers (optional)

To OP:

Unix-like OS uses a toolbox approach, therefore you can build the
editing tool you seek by simply connecting an editor (whatever your
poison) to diff with a shell script.

An untested starting point:

#!/bin/bash

if [ -f "$1" ] && [ -n "$2" ]; then ## check edit file, non-empty diff out name
vim $1
diff -u "${1}~" $1 > $2
fi

Grant.
--
Memory fault -- brain fried
Back to top
Grant Edwards
External


Since: Jun 08, 2004
Posts: 1264



PostPosted: Mon May 08, 2006 2:19 pm    Post subject: Re: looking for editors with automatic diff (cvs) support [Login to view extended thread Info.]
Archived from groups: comp>editors, others (more info?)

On 2006-05-08, bakert <bakert RemoveThis @gmail.com> wrote:
> Perhaps you can use autocmd in your vim configuration file to call
>
> !cvs commit -m "..."
>
> when you save a file

He could wrap any editor he likes in a shell script that does a
commit after the editor exits. He wouldn't have snapshots of
intermediate versions that were saved without exiting the
editor...

--
Grant Edwards grante Yow! Do you guys know we
at just passed thru a BLACK
visi.com HOLE in space?
Back to top
rpilkey
External


Since: May 15, 2006
Posts: 1



PostPosted: Mon May 15, 2006 8:45 am    Post subject: Re: looking for editors with automatic diff (cvs) support [Login to view extended thread Info.]
Archived from groups: per prev. post (more info?)

If you are using Vim, perhaps this is what you are looking for:

http://www.vim.org/scripts/script.php?script_id=563

rcsvers.vim : Use RCS to make a backup whenever you save a file

It automatically creates new revisions in an RCS file whenever you
save. It also lets you view/diff any version of a file that you have
saved.

Roger
Back to top
Display posts from previous:   
Post new topic   General Reply to Topic (not reply to a specific post)    Forums Home -> General Discussions (archive 1) All times are: Eastern Time (US & Canada) (change)
Page 1 of 1

 
You can post new topics in this forum
You can reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum