Take the 2-minute tour ×
Unix & Linux Stack Exchange is a question and answer site for users of Linux, FreeBSD and other Un*x-like operating systems.. It's 100% free, no registration required.

CVS doesn't list unversioned files in the status output by default, so how can I get a list of all unversioned files? This is the best I've come up with so far:

while IFS= read -r -d '' -u 9
do
    2>/dev/null cvs status "$REPLY" | >/dev/null grep Unknown && echo "$REPLY"
done 9< <( find . \( -type d -name CVS -prune -false \) -o -type f -print0 )

Surely there must be a simpler way?

share|improve this question

1 Answer 1

up vote 1 down vote accepted

Found a solution: cvs -qn update

share|improve this answer
2  
I have alias cvss='cvs -nq update', and an alias for cvs -nq update | grep -v '^?' for when I work with people who haven't heard of .cvsignore. And, strictly speaking, the answer to your question is cvs -nq update | grep '^?'. –  Gilles Apr 27 '11 at 19:57

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.