Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • Home
  • SEARCH
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 386177
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 12, 20262026-05-12T15:33:05+00:00 2026-05-12T15:33:05+00:00

I have a large application in a production environment that I’m trying to move

  • 0

I have a large application in a production environment that I’m trying to move under version control. So, I created a new repo and imported the app, minus various directories and files that shouldn’t be under version control. Now, I need to make the installed copy a checkout (but still retain the extra files). At this point, in a recent version of SVN, I’d simply do a checkout over top the existing directory using the –force option. But sadly, I have an ancient version of SVN, from before when the –force option was added (and can’t yet upgrade… long story).

So, I checked out the app to another directory, and want to simply copy all of the .svn directories into the original directory, thus turning the original into a checkout whilst leaving alone the extra files. Now, maybe I’m just having a rough day and missing something that’s in plain site, but I can’t seem to be able to figure this out. Here are the approaches I’ve tried so far:

  1. Use rsync: I can’t seem to hit the right combination of include and exclude directives to recursively capture all the .svn directories but nothing else.

  2. Use cp: I can’t figure out a good way to have it hit all the .svn directories across and down through the whole app.

  3. Use find with -exec cp: I’m running into trouble with the leading part of the pathnames of the found files messing up the destination paths. I can exclude it using -printf ‘%P’, but that doesn’t seem to go into the {} replacement for exec.

  4. Use find with xargs to cp: I’m running into trouble with find sending over child directories before sending their parents. Unfortunately, find does not have a –breadth option.

Any thoughts out there?

Other info:

  • bash 3.0.0.14
  • rsync 2.6.3 p28
  • cp 5.2.1
  • svn 1.3.2
  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-05-12T15:33:05+00:00Added an answer on May 12, 2026 at 3:33 pm

    Use tar and find to capture the .svn dirs in a clean checkout, then untar into your app.

    cd /tmp/
    svn co XXX
    cd XXX
    find . -name .svn -print0 | tar cf /tmp/XXX.tar --null -T -
    cd /to/your/app/
    tar xf /tmp/XXX.tar
    

    Edit: switched find/tar command to use NUL terminator for robustness in the face of filenames containing spaces. Original command was:

    tar cf /tmp/XXX.tar $(find . -name .svn)
    
    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Ask A Question

Stats

  • Questions 231k
  • Answers 231k
  • Best Answers 0
  • User 1
  • Popular
  • Answers
  • Editorial Team

    How to approach applying for a job at a company ...

    • 7 Answers
  • Editorial Team

    How to handle personal stress caused by utterly incompetent and ...

    • 5 Answers
  • Editorial Team

    What is a programmer’s life like?

    • 5 Answers
  • Editorial Team
    Editorial Team added an answer Use the following function like this: Image('/path/to/original.image', '1/1', '150*', './thumb.jpg');… May 13, 2026 at 2:13 am
  • Editorial Team
    Editorial Team added an answer Check you database schema to see if the field (referenced… May 13, 2026 at 2:13 am
  • Editorial Team
    Editorial Team added an answer I figured out the problem - there was a session… May 13, 2026 at 2:13 am

Related Questions

I have a large application in a production environment that I'm trying to move
I'm interested in parsing a fairly large text file in Java (1.6.x) and was
We a have a GDBM key-value database as the backend to a load-balanced web-facing
I think back to Joel Spolsky's article about never rewriting code from scratch. To
In a large corporation I worked in previously a manager purchased a $50,000+ Websphere

Trending Tags

analytics british company computer developers django employee employer english facebook french google interview javascript language life php programmer programs salary

Top Members

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.