CVS Checkout script for OS X

When trying the checkout.sh script in OSX, I get the following errors:

    : command not foundwnloads/checkout.sh: line 6: 
    /Users/nnhubbard/Downloads/checkout.sh: line 7: syntax error near unexpected tok'n `
    'Users/nnhubbard/Downloads/checkout.sh: line 7: `print_usage()


Both my work and home computer did this, does something need to be fixed in the script?

Looks like the script was committed with Windows newlines for some reason. OS X is not liking them. If you open it in a text editor and switch to Unix newlines, it works fine.


I'll fix the script when I remember where the read/write Matrix repo is :slight_smile:



EDIT: Actually, that will have to wait until Monday because access is blocked off from outside and I'm not heading to the office :slight_smile:

Thanks Greg, I will make the changes to my copy. :slight_smile:

Ok, fixed that issue. Now, when running:

    sh ~/Downloads/checkout.sh mysource_3-24-2 ~/Downloads/matrix


I get the error:

    /Users/nnhubbard/Downloads/checkout.sh: line 50: /usr/bin/cvs: No such file or directory
    There was a problem checking out the matrix core


Ideas?

[quote]
Ok, fixed that issue. Now, when running:


    sh ~/Downloads/checkout.sh mysource_3-24-2 ~/Downloads/matrix


I get the error:

    /Users/nnhubbard/Downloads/checkout.sh: line 50: /usr/bin/cvs: No such file or directory
    There was a problem checking out the matrix core


Ideas?
[/quote]

Is cvs installed into /usr/bin ? Sorry I don't know the command in OSX to find an app, but if it is any help in Linux you could use locate or whereis

Do you have CVS installed on your Mac? I cant remember for sure, but I think you might need to install the developer tools on the OS X DVD to get it.


EDIT: Once you do, typing "which cvs" should bring up "/usr/bin/cvs"

[quote]
Do you have CVS installed on your Mac? I cant remember for sure, but I think you might need to install the developer tools on the OS X DVD to get it.



EDIT: Once you do, typing “which cvs” should bring up “/usr/bin/cvs”

[/quote]

I had to install it from Macports(osx disk images at the top) - I do not think it comes with the developer tools.



I installed cvsps from source too (git uses it) , as that can be useful too…





R

Sorry, could be Xcode tools: http://developer.apple.com/internet/opensource/cvsoverview.html
I know that I've never had to install CVS on OS X, but I always install the full developer/Xcode packages as well.

Thanks guys, wasn't thinking about the cvs binary on my machine. I did have dev tools installed, but I needed to move cvs from that to /usr/bin/ rather than in the developer tools usr/bin.


All is working now. :slight_smile:

The script has now been committed in UNIX-friendly form.
I'm sorry about the newline issue, it came from copying from email on Windows.



The modified script (rev. 1.2) should be available for download / updating from the repository within the hour.