Artificial Intelligence

Adding a directory to subversion, and ignoring the directory contents

Sometimes when committing things to svn you want to commit a directory, but ignore all of the files inside it. Here's how.


Filed under:

Metal Toad is an AWS Managed Services provider. In addition to this article on svn we recommend checking out our article on how to host a website on AWS in 5 minutes.

Sometimes when committing things to svn you want to commit a directory, but ignore all of the files inside it. The /sites/default/files/ directory within Drupal is a perfect example. Here's how:

  1. Add the directory, while ignoring all of the files it contains:
    svn add -N [directory]
  2. After adding the directory enter the directory and run the following command:
    svn propset svn:ignore '*.*' .
  3. Commit your changes:
    svn commit -m "Added the directory and set the files within it to be ignored"

All better now...!

Similar posts

Get notified on new marketing insights

Be the first to know about new B2B SaaS Marketing insights to build or refine your marketing function with the tools and knowledge of today’s industry.