Beefy Boxes and Bandwidth Generously Provided by pair Networks
Keep It Simple, Stupid

Re^2: Learning How to Use CVS for Personal Perl Coding Practices

by neversaint (Deacon)
on Nov 03, 2005 at 16:23 UTC ( #505420=note: print w/replies, xml ) Need Help??

in reply to Re: Learning How to Use CVS for Personal Perl Coding Practices
in thread Learning How to Use CVS for Personal Perl Coding Practices

Dear tirwhan,
Let me make myself clear again. Please bear with me. Suppose I have the following directory which contain a file ( which I want to store them with SVN.
~/MyPerl | |__Project1 | |__ Note: ~/ = home/neversaint
Following your advice what I tried to do is following steps.

Step 1: Creating a subversion main repository and repository related to Project1
home/neversaint $ mkdir subversion home/neversaint $ cd subversion home/neversaint/subversion $ svnadmin create Project1
Listing them:
home/neversaint/subversion $ cd Project1 home/neversaint/subversion/Project1 $ ls README.txt conf dav db format hooks locks
Step 2: Attempting to create empty repository
home/neversaint/subversion $ cd ~/MyPerl/Project1 home/neversaint/MyPerl/Project1 $ svn import . file:///~/subversion/Pr +oject1 ^ | Note: did I get this right? ---------------------|
Now, at this point I encounter problem with this message:
svn: Could not use external editor to fetch log message; consider<br> setting the $SVN_EDITOR environment variable or using the --message (-m) or --file (-F) options svn: None of the environment variables SVN_EDITOR, VISUAL or EDITOR is set, and no 'editor-cmd' run-time configuration option was found
Is there anything wrong with my steps above? Did I misunderstood your advice above? Hope to hear from you again.

neversaint and everlastingly indebted.......

Replies are listed 'Best First'.
Re^3: Learning How to Use CVS for Personal Perl Coding Practices
by Rhose (Priest) on Nov 03, 2005 at 16:30 UTC
    Import (like commit) needs a log message. I'd use the -m switch on the import. (Although you can define the editor and enter the log message using it.)

    svn import . file:///~/subversion -m "Initial import"

      Hi Rhose,

      I tried this:
      svn import . file:///~/subversion/Project1 -m "Initial import"
      But it gave:
      svn: Unrecognized URL scheme 'file:///~/subversion/Project1'

      neversaint and everlastingly indebted.......

        Yeah, you need to give the full path, e.g.

        svn import . file:///home/neversaint/subversion/Project1 -m "Initial i +mport"
        Regarding the $EDITOR variable, you should set that to your favourite editor
        export EDITOR=/usr/bin/emacs
        export EDITOR=/usr/bin/vi
        then you can specify the subversion commands without the -m and have it call the editor for manual message entry automatically if you prefer. Add the line to .bashrc to have it done for you automatically when you log in.

        Debugging is twice as hard as writing the code in the first place. Therefore, if you write the code as cleverly as possible, you are, by definition, not smart enough to debug it. -- Brian W. Kernighan
        I have no experience using file: as I work with the daemon. However, I ran a quick test on another machine, and this worked.

        cd /home/rhose/tmp svnadmin create demo cd samples svn import . file:///home/rhose/tmp/demo -m "Initial import"

        I tried it as:

        svn import . file:///~/tmp/demo -m "Initial import"

        and I got the same error you are getting... looks like you need to specify the path to your home directory.


        Yeah, what tirwhan said. *Smiles* At least I had a reason to play with file: for a bit.

Log In?

What's my password?
Create A New User
Node Status?
node history
Node Type: note [id://505420]
and the web crawler heard nothing...

How do I use this? | Other CB clients
Other Users?
Others browsing the Monastery: (2)
As of 2019-08-25 07:16 GMT
Find Nodes?
    Voting Booth?

    No recent polls found