Okay, here’s a comprehensive article on TortoiseSVN, designed to be a “Getting Started” guide, covering approximately 5000 words and focusing on practical usage and clear explanations:
TortoiseSVN Guide: Getting Started with Version Control
Introduction: Why Version Control and Why TortoiseSVN?
In the world of software development, writing, and any collaborative project involving files, managing changes efficiently is paramount. Imagine working on a large document with multiple collaborators:
- Scenario 1: The Email Chaos. You email versions back and forth (“Document_v1.docx,” “Document_v2_final.docx,” “Document_v2_final_REALLY_final.docx”). Confusion reigns. It’s impossible to track who made which changes, and merging different versions is a nightmare.
- Scenario 2: The Shared Drive Disaster. Everyone edits the same file on a shared network drive. Two people edit simultaneously, and someone’s changes are overwritten. Data is lost, and frustration abounds.
This is where Version Control Systems (VCS), also known as Revision Control Systems, come to the rescue. A VCS acts like a time machine for your files. It allows you to:
- Track Changes: Every modification, addition, and deletion is recorded, along with who made the change and when.
- Revert to Older Versions: Need to go back to a version from last week, last month, or even last year? No problem. A VCS lets you easily restore previous states.
- Branch and Merge: Work on different features or experimental changes in separate “branches” without affecting the main codebase. Later, you can merge these changes back into the main line.
- Collaborate Effectively: Multiple people can work on the same project simultaneously, and the VCS helps manage conflicts and merge changes smoothly.
- Backup and Recovery: Your project’s history is stored, providing a robust backup and recovery mechanism.
There are many VCS options available, broadly categorized as:
- Centralized VCS (CVCS): A single central server holds the entire project history. Examples include Subversion (SVN) and CVS.
- Distributed VCS (DVCS): Each user has a complete copy of the project history. Examples include Git, Mercurial, and Bazaar.
This guide focuses on TortoiseSVN, a popular and user-friendly client for the Subversion (SVN) version control system. SVN is a centralized VCS, meaning there’s a central repository (server) that stores the master copy of your project. TortoiseSVN provides a graphical interface integrated directly into the Windows Explorer, making it incredibly intuitive to use.
Why TortoiseSVN?
- Ease of Use: TortoiseSVN’s integration with Windows Explorer makes it exceptionally easy to learn and use. No command-line knowledge is required (though you can use SVN commands if you prefer).
- Visual Feedback: TortoiseSVN uses overlay icons on your files and folders to indicate their status (modified, up-to-date, conflicted, etc.). This provides instant visual feedback.
- Context Menu Integration: All SVN commands are accessible through the right-click context menu in Windows Explorer.
- Powerful Features: Despite its simplicity, TortoiseSVN offers a full range of SVN features, including branching, merging, tagging, and more.
- Free and Open Source: TortoiseSVN is free to use and open-source, meaning its source code is publicly available.
- Large Community and Support: A large and active community provides ample documentation, tutorials, and support forums.
This Guide’s Structure
This guide will walk you through the essential steps of using TortoiseSVN, from installation to daily workflow. We’ll cover:
- Installation and Setup: Installing TortoiseSVN and configuring basic settings.
- Creating a Repository: Setting up a central repository (either locally or on a server).
- Checking Out a Working Copy: Getting a local copy of the project from the repository.
- Basic Workflow: Adding, Modifying, and Committing Changes: The core cycle of version control.
- Understanding SVN Status Icons: Interpreting the visual cues provided by TortoiseSVN.
- Resolving Conflicts: Handling situations where multiple people have modified the same file.
- Reverting Changes: Undoing modifications and going back to previous versions.
- Branching and Merging: Working on separate lines of development and integrating them.
- Tagging and Releases: Creating snapshots of specific versions for releases.
- Using the Log and Revision Graph: Exploring the project’s history.
- Ignoring Files and Folders: Excluding specific items from version control.
- Best Practices and Tips: Recommendations for efficient and effective use of TortoiseSVN.
- Troubleshooting Common Issues: Addressing common problems and errors.
- Advanced Topics (Brief Overview): A glimpse into more advanced features like hooks, properties, and external repositories.
1. Installation and Setup
1.1 Downloading TortoiseSVN
- Go to the official TortoiseSVN website: https://tortoisesvn.net/downloads.html
- Download the appropriate installer for your Windows version (32-bit or 64-bit). It’s highly recommended to use the 64-bit version if your system supports it.
- It’s also recommended that you install the command line client tools. This can be useful for scripting or if you ever need to use SVN from the command line.
1.2 Installation Process
- Run the downloaded installer.
- Follow the on-screen instructions. In most cases, you can accept the default settings.
- Important: During installation, you’ll be asked if you want to install the command-line client tools. It’s generally a good idea to select this option, even if you don’t plan to use them immediately. They can be helpful for troubleshooting or advanced operations.
- You may be prompted to restart your computer after the installation is complete.
1.3 Basic Configuration (Optional)
After installation, you can customize TortoiseSVN’s settings:
- Right-click on any folder in Windows Explorer.
- Select TortoiseSVN → Settings.
- Explore the various settings categories:
- General: Language, default editor, diff/merge tool, etc.
- Icon Overlays: Customize the appearance of the overlay icons.
- Network: Configure proxy settings if you’re behind a proxy server.
- Diff Viewer / Merge Tool: Specify your preferred tools for comparing and merging files. (TortoiseSVN comes with TortoiseMerge, which is usually sufficient.)
- Hook Scripts: (Advanced) Configure scripts to be executed automatically on certain SVN events.
For most users, the default settings are perfectly fine. You can always adjust these settings later as needed.
2. Creating a Repository
Before you can start using version control, you need a repository. The repository is the central storage location for all your project’s files and their history. You have two main options for creating a repository:
2.1 Local Repository (For Personal Projects or Testing)
A local repository is stored directly on your computer. This is suitable for:
- Personal projects where you’re the only developer.
- Testing and learning TortoiseSVN without needing a server.
- Creating a quick, temporary repository.
To create a local repository:
- Create a Folder: Create an empty folder on your computer where you want to store the repository (e.g.,
C:\SVN_Repositories\MyProjectRepo
). It’s best to choose a location that’s not within a working copy (more on working copies later). A dedicated folder for repositories is a good practice. - Right-Click and Create: Right-click on the newly created folder.
- TortoiseSVN → Create repository here: Select this option from the context menu.
- Confirmation: You’ll see a confirmation message indicating that the repository has been created successfully. The folder will now contain several subfolders and files that make up the SVN repository structure. Do not directly modify these files.
The repository URL for a local repository uses the file:///
protocol. For example, the URL for the repository created above would be:
file:///C:/SVN_Repositories/MyProjectRepo
2.2 Server-Based Repository (For Collaboration)
For collaborative projects, you’ll need a server-based repository. This allows multiple users to access and work on the project simultaneously. Options include:
- Setting up your own SVN server: This requires some technical knowledge and server administration skills. You can use software like VisualSVN Server (Windows) or
svnserve
(cross-platform). - Using a hosted SVN service: Several providers offer hosted SVN repositories, often with free or paid plans. Examples include:
- Assembla: Offers SVN hosting along with other project management tools.
- Beanstalk: Another popular option for SVN and Git hosting.
- CloudForge: Provides SVN, Git, and other services.
The setup process for a server-based repository will vary depending on the chosen method. Generally, you’ll need:
- Server Address: The URL or IP address of the SVN server.
- Repository Path: The specific path to your repository on the server.
- Username and Password: Credentials for accessing the repository.
The repository URL for a server-based repository typically uses the http://
, https://
, or svn://
protocol. For example:
http://svn.example.com/repos/MyProject
https://svn.example.com/repos/MyProject
(secure connection)svn://svn.example.com/repos/MyProject
Important Considerations for Repository Creation:
-
Repository Structure: SVN repositories traditionally use a standard directory structure:
/trunk
: The main line of development. This is where the most stable and up-to-date code resides./branches
: Contains separate branches for working on new features, bug fixes, or experimental changes./tags
: Contains snapshots of specific versions, often used for releases.
While you can technically deviate from this structure, it’s highly recommended to follow it for better organization and compatibility with SVN tools and workflows. You don’t have to create this structure manually within the repository itself. TortoiseSVN, and SVN in general, encourage you to create this structure within your working copy after you’ve checked it out. The repository itself starts empty.
* Repository Location: Choose a location that’s backed up regularly. The repository contains your entire project history, so losing it would be disastrous.
* Repository Naming: Use descriptive names to easily distinguish between different projects, it can be usefull to version you repository, for instance:MyProjectRepo_v1
.
3. Checking Out a Working Copy
Once you have a repository, you need to create a working copy. The working copy is a local copy of the project files that you’ll actually work with on your computer. It’s linked to the repository, allowing you to synchronize your changes.
To check out a working copy:
- Create a Folder: Create an empty folder on your computer where you want to store your working copy (e.g.,
C:\Projects\MyProject
). This is where you will edit files. - Right-Click and Checkout: Right-click on the newly created folder.
- SVN Checkout…: Select this option from the context menu.
- Enter Repository URL: In the “URL of repository” field, enter the URL of your repository (either the
file:///
URL for a local repository or thehttp://
,https://
, orsvn://
URL for a server-based repository). - Checkout Directory: The “Checkout directory” field should automatically populate with the path to the folder you right-clicked on. You can change this if needed.
- Revision: Leave the “Revision” option set to “HEAD revision” to get the latest version from the repository. You can also choose a specific revision number if you want to check out an older version.
- Click OK: TortoiseSVN will connect to the repository and download the files to your working copy folder.
After the checkout is complete, you’ll notice:
- Overlay Icons: The files and folders in your working copy will have overlay icons indicating their status. Initially, they should have a green checkmark, meaning they are up-to-date with the repository.
- .svn Folder: A hidden folder named
.svn
will be created in the root of your working copy. Do not modify or delete this folder. It contains metadata that TortoiseSVN uses to track changes and communicate with the repository.
4. Basic Workflow: Adding, Modifying, and Committing Changes
The core workflow in TortoiseSVN involves these steps:
- Update (Optional but Recommended): Before you start working, it’s a good practice to update your working copy to get the latest changes from the repository. Right-click on your working copy folder and select SVN Update. This ensures you’re working with the most recent version and reduces the chance of conflicts.
- Modify Files: Make changes to the files in your working copy using your regular editors (text editors, IDEs, image editors, etc.).
- Add New Files/Folders (If Necessary): If you create new files or folders within your working copy, you need to tell SVN to track them.
- Right-click on the new file or folder.
- Select TortoiseSVN → Add.
- The file/folder will now be scheduled for addition to the repository on your next commit.
- Commit Changes: Once you’ve made changes and are ready to save them to the repository:
- Right-click on your working copy folder (or a specific file/folder you want to commit).
- Select SVN Commit….
- Commit Message: A dialog box will appear. This is crucial: Enter a clear and descriptive commit message explaining the changes you made. Good commit messages are essential for understanding the project’s history.
- Files to Commit: The dialog box will list all modified, added, and deleted files. You can select or deselect specific files if you don’t want to commit them yet.
- Click OK: TortoiseSVN will send your changes to the repository, creating a new revision.
Example:
Let’s say you have a text file named readme.txt
in your working copy.
- Update: You right-click on your working copy folder and select SVN Update.
- Modify: You open
readme.txt
in a text editor and add a new line of text. - Commit: You right-click on your working copy folder and select SVN Commit….
- Commit Message: You enter the message: “Added a new line to the readme file explaining the project’s purpose.”
- Click OK: Your changes are committed to the repository.
5. Understanding SVN Status Icons
TortoiseSVN uses overlay icons on your files and folders to visually indicate their status relative to the repository. Here’s a breakdown of the most common icons:
- Green Checkmark: The file or folder is up-to-date with the repository. No local changes have been made.
- Blue Plus Sign: The file or folder has been added locally and is scheduled to be added to the repository on the next commit.
- Red Exclamation Mark: The file has been modified locally. Changes have been made, but they haven’t been committed to the repository yet.
- Yellow Question Mark: The file or folder is not under version control. SVN doesn’t know about it. This often happens with temporary files or build output.
- Red Circle with a White Bar: The file or folder has been deleted locally and is scheduled to be removed from the repository on the next commit.
- Purple Diamond with a white arrow: The file or folder has been replaced. Meaning it was deleted, and a new one with the same name was added.
- Red Exclamation Mark with a Yellow Triangle: There’s a conflict. This means someone else has committed changes to the same file, and your local changes overlap with theirs. You need to resolve the conflict before committing.
- Gray Circle: The file or folder is ignored. It’s intentionally excluded from version control (more on ignoring files later).
- Locked (padlock) The file or folder has been locked.
These icons provide instant visual feedback about the state of your working copy, making it easy to see what’s changed and what needs to be committed.
6. Resolving Conflicts
Conflicts are a natural part of collaborative development. They occur when two or more people modify the same lines in a file, and SVN can’t automatically merge the changes.
6.1 How Conflicts Arise
- You Update: You update your working copy (SVN Update).
- Conflict Detected: TortoiseSVN detects that someone else has committed changes to a file you’ve also modified.
- Conflict Icon: The file’s icon changes to the conflict icon (red exclamation mark with a yellow triangle).
- Conflict Files: TortoiseSVN creates three temporary files in your working copy:
filename.ext.mine
: Your version of the file before the update.filename.ext.rOLDREV
: The version of the file from the repository before the conflicting commit.filename.ext.rNEWREV
: The latest version of the file from the repository (the one that caused the conflict).
6.2 Resolving Conflicts with TortoiseMerge
The easiest way to resolve conflicts is to use TortoiseMerge, TortoiseSVN’s built-in diff/merge tool:
- Right-Click and Edit Conflicts: Right-click on the conflicted file and select TortoiseSVN → Edit conflicts.
- TortoiseMerge Opens: TortoiseMerge will open, showing a three-pane view:
- Left Pane: The
OLDREV
version (the base version). - Right Pane: The
NEWREV
version (the version from the repository with the conflicting changes). - Bottom Pane: Your working copy version (where you’ll make the merged changes).
- Left Pane: The
- Merge Changes: Carefully examine the differences between the left and right panes. Use the buttons and context menu options in TortoiseMerge to:
- Take Left Block: Use the change from the
OLDREV
version. - Take Right Block: Use the change from the
NEWREV
version. - Take Left Then Right: Use both changes, with the
OLDREV
change first. - Take Right Then Left: Use both changes, with the
NEWREV
change first. - Edit Manually: Directly edit the text in the bottom pane to create the desired merged version.
- Take Left Block: Use the change from the
- Save Changes: Once you’ve resolved all the conflicts, save the changes in the bottom pane.
- Mark as Resolved: Close TortoiseMerge. Right-click on the conflicted file and select TortoiseSVN → Resolved. This tells SVN that you’ve finished resolving the conflict. The temporary files will be deleted.
- Commit: Commit the resolved file (SVN Commit…) with a descriptive commit message explaining how you resolved the conflict.
6.3 Manual Conflict Resolution (Advanced)
If you prefer, you can resolve conflicts manually using a text editor:
- Open the Conflicted File: Open the original conflicted file (not the temporary files) in your text editor.
-
Conflict Markers: You’ll see conflict markers inserted by SVN:
“`
<<<<<<< .mine
Your changes here
=======
Changes from the repository here.rNEWREV
``
<<<<<<<
3. **Edit and Remove Markers:** Carefully edit the file to combine your changes and the changes from the repository. **Remove all the conflict markers (,
=======,
>>>>>>>`) once you’re done.
4. Save: Save the file.
5. Mark as Resolved: Right-click on the file and select TortoiseSVN → Resolved.
6. Commit:** Commit the resolved file.
Important Notes on Conflicts:
- Communication is Key: If you encounter conflicts frequently, it’s a sign that you and your collaborators should communicate more often about who’s working on what.
- Update Frequently: Updating your working copy regularly reduces the likelihood of conflicts.
- Commit Small, Frequent Changes: Smaller, more frequent commits make conflicts easier to resolve.
- Don’t Panic: Conflicts are a normal part of version control. Take your time, understand the changes, and resolve them carefully.
7. Reverting Changes
TortoiseSVN makes it easy to undo changes and revert to previous versions of files or folders.
7.1 Reverting Local Modifications (Before Commit)
If you’ve made changes to a file but haven’t committed them yet, you can revert them to the last updated version from the repository:
- Right-click on the modified file or folder.
- Select TortoiseSVN → Revert….
- A dialog box will appear listing the files that will be reverted.
- Click OK. Your local changes will be discarded, and the file will be restored to the version from the last update.
7.2 Reverting to a Specific Revision (After Commit)
If you’ve committed changes that you want to undo, you can revert to a specific revision:
- Show Log: Right-click on the file or folder and select TortoiseSVN → Show log.
- Select Revision: The log dialog will show the history of the file or folder. Select the revision you want to revert to.
- Revert to This Revision: Right-click on the selected revision and choose Revert to this revision. This will apply the reverse of the changes made in that revision to your working copy. The file’s content will be as it was before the chosen revision.
- Commit: Since the
Revert to this revision
only changes your working copy. You will need toCommit
so these changes get to the repository.
7.3 Reverting Changes from a Specific Revision (Undoing a Commit)
If you want to undo the changes made in a specific commit, without reverting everything to that older state, use the “Revert changes from this revision” option:
- Show Log: Right-click on the file or folder and select TortoiseSVN → Show log.
- Select Revision: Select the revision containing the changes you want to undo.
- Revert Changes from This Revision: Right-click on the selected revision and choose Revert changes from this revision. This will apply only the inverse of the changes made in that specific revision to your working copy. Think of it as creating a “counter-commit.”
- Commit You will still need to commit these changes.
Important Notes on Reverting:
- Reverting creates new revisions: Reverting doesn’t delete the original revisions from the history. It creates new revisions that undo the changes.
- Be Careful with Reverting: Reverting can affect other people’s work if you’re collaborating on a project. Communicate with your team before reverting significant changes.
- Use Update to this Revision to Inspect: If you want to see the contents of a previous revision without modifying your working copy, you can use the “Update item to revision” option in the log dialog. This will temporarily change your working copy to that revision, but you won’t be able to commit from that state directly. You’d need to use “Revert” to make those changes permanent and committable.
8. Branching and Merging
Branching and merging are powerful features that allow you to work on separate lines of development without affecting the main codebase (the trunk
).
8.1 What is a Branch?
A branch is a separate line of development that diverges from the main line (trunk) or another branch. It’s like creating a parallel universe for your project. You can make changes on a branch without affecting the trunk, and later you can merge those changes back into the trunk (or another branch).
8.2 Why Use Branches?
- Feature Development: Develop new features in isolation without disrupting the stable code in the trunk.
- Bug Fixes: Fix bugs on a separate branch, test them thoroughly, and then merge them back into the trunk.
- Experimental Changes: Try out new ideas or refactor code without risking the stability of the main codebase.
- Release Branches: Create branches to prepare for releases, allowing you to continue development on the trunk while stabilizing the release branch.
8.3 Creating a Branch
- Right-Click and Branch/Tag: Right-click on the folder in your working copy that you want to branch (usually the root of your project). Select TortoiseSVN → Branch/Tag….
- From: The
From WC at URL
will show your current working copy. - To URL: Enter the URL where you want to create the branch within the repository. Follow the standard SVN structure:
.../trunk
(for the main line).../branches/MyNewFeatureBranch
(for a new branch).../tags/Release1.0
(for a tag)
- Specific revision in repository: If you want to branch from a specific moment, not your working copy. Change the
From
to this option, and select the revision you want. - Log Message: Enter a log message explaining why you’re creating the branch.
- Click OK: TortoiseSVN will create the branch in the repository. This operation doesn’t automatically change your working copy.
- Switch (Important): To start working on the branch, you need to switch your working copy to the branch:
- Right-click on your working copy folder.
- Select TortoiseSVN → Switch….
- To URL: Enter the URL of the branch you just created (e.g.,
.../branches/MyNewFeatureBranch
). - Click OK: Your working copy will be updated to reflect the contents of the branch. The overlay icons will update to show that you’re now on the branch.
8.4 Merging Changes
Once you’ve made changes on a branch, you can merge them back into the trunk (or another branch).
- Update: Update your working copy of the target branch (the branch you want to merge into, usually the trunk) to the latest revision.
- Right-Click and Merge: Right-click on the working copy folder of the target branch and select TortoiseSVN → Merge….
- Merge Type: You’ll see several merge options:
- Merge a range of revisions: This is the most common option. It allows you to merge specific revisions from one branch to another.
- Merge two different trees: This is used for more complex scenarios, such as merging unrelated branches.
- Reintegrate a branch: This option is used after feature development is complete.
- Range of revisions: If you chose
Merge a range of revisions
:- From URL: Enter the URL of the branch you want to merge from (e.g.,
.../branches/MyNewFeatureBranch
). - Revision range: Leave blank to merge all revisions, or specify a range (e.g.,
123-456
) or a comma-separated list of revisions (e.g.,123,125,128
).
- From URL: Enter the URL of the branch you want to merge from (e.g.,
- Click “Next” and then “Merge”.
- Test: After the merge, it’s crucial to test your code thoroughly to ensure that the merge didn’t introduce any problems.
- Commit: If everything looks good, commit the merged changes to the target branch.
8.5 Reintegrate a branch
When a feature branch is complete and has been fully tested, you should use the “Reintegrate a branch” option for merging. This type of merge handles the complexities of merging a branch back into its origin (usually the trunk) after multiple merges might have occurred in both directions.
- Update: Update your trunk working copy.
- Right-Click and Merge: Right-click on the trunk working copy and select TortoiseSVN → Merge…
- Choose Reintegrate: Select the “Reintegrate a branch” option.
- From URL: Enter the URL of the feature branch you want to reintegrate.
- Click “Merge”. TortoiseSVN will handle the merge.
- Test: As always, test thoroughly after the merge.
- Commit: Commit the changes to the trunk.
- Delete the Branch (Optional): After a successful reintegration, it’s common practice to delete the feature branch from the repository to keep things tidy. You can do this with TortoiseSVN → Repo-browser, navigating to the branch, right-clicking, and choosing “Delete.”
9. Tagging and Releases
Tags are used to create snapshots of specific versions of your project, typically for releases. A tag is like a branch that’s not intended to be modified. It marks a point in time.
9.1 Creating a Tag
- Right-Click and Branch/Tag: Right-click on the folder in your working copy that you want to tag (usually the root of your project or a specific branch). Select TortoiseSVN → Branch/Tag….
- From: Select the part of your project you want to tag, either the
Working Copy
, or a specificrevision
. - To URL: Enter the URL where you want to create the tag within the repository. Follow the standard SVN structure:
.../tags/Release1.0
(for a tag named “Release1.0”)
- Log Message: Enter a log message explaining the purpose of the tag (e.g., “Release 1.0”).
- Click OK: TortoiseSVN will create the tag in the repository.
9.2 Checking Out a Tag
You can check out a tag to get a specific version of your project:
- Use the SVN Checkout… command as you would for a regular checkout.
- Enter the URL of the tag in the “URL of repository” field (e.g.,
.../tags/Release1.0
).
Important Note: You should not commit changes to a tag. Tags are meant to be immutable snapshots. If you need to make changes, create a branch from the tag, make the changes on the branch, and then create a new tag if necessary.
10. Using the Log and Revision Graph
TortoiseSVN provides powerful tools for exploring your project’s history.
10.1 The Log Dialog
- Access: Right-click on a file or folder and select TortoiseSVN → Show log.
- Information: The log dialog displays:
- Revision Number: A unique number assigned to each commit.
- Author: The user who made the commit.
- Date and Time: When the commit was made.
- Commit Message: The message entered by the user describing the changes.
- Changed Paths: A list of the files that were modified in the commit.
- Filtering: You can filter the log by:
- Date Range: Show commits within a specific period.
- Author: Show commits by a particular user.
- Message: Search for commits containing specific text in the commit message.
- Stop on copy/rename: This option controls whether the log follows a file’s history across renames or copies.
- Actions: From the log dialog, you can:
- View Differences: Compare two revisions to see the changes made.
- Revert Changes: Undo changes made in a specific revision.
- Blame/Annotate: See who last modified each line of a file.
- Create Branch/Tag: Create a branch or tag from a specific revision.
- Update to Revision: Temporarily update your working copy to a specific revision.
- Export: Export a specific revision to a separate folder.
10.2 The Revision Graph
- Access: In the log dialog, click the Revision Graph button.
- Visualization: The revision graph provides a visual representation of your project’s history, showing branches, merges, and tags.
- Navigation: You can click on nodes in the graph to see details about specific revisions.
- Understanding Branching and Merging: The revision graph is particularly useful for understanding the relationships between branches and merges.
11. Ignoring Files and Folders
It’s often necessary to exclude certain files or folders from version control. These might include:
- Build Output: Files generated by your build process (e.g.,
.obj
,.exe
,.class
files). - Temporary Files: Files created by your editor or other tools (e.g.,
~
backup files). - User-Specific Settings: Configuration files that are specific to your local environment.
- Large Binary Files: Files that are very large and don’t change often (e.g., large media files).
11.1 Using svn:ignore
Property
The most common way to ignore files is to use the svn:ignore
property:
- Right-Click and Properties: Right-click on the folder where you want to set the ignore pattern. Select TortoiseSVN → Properties.
- Add Property:
- Property Name: Enter
svn:ignore
. - Property Value: Enter a list of file or folder patterns, one per line. You can use wildcards:
*
: Matches any characters.?
: Matches a single character.[ ]
: Matches a set of characters.
- Examples:
*.exe
*.obj
temp/
*.log
[Bb]in
- Property Name: Enter
- Click OK: The
svn:ignore
property will be added to the folder. - Commit: This property is part of your version control, so you will need to commit it.
11.2 Global Ignore Pattern
You can also set a global ignore pattern that applies to all your working copies:
- TortoiseSVN → Settings → General → Global ignore pattern: Enter the patterns here.
The global ignore pattern is useful