Login | Join Now
Click here to access Issue tracker direct from Eclipse or Visual Studio
and to obtain other CollabNet integrations.

ankhsvn
Issue 619

Query | Reports | My votes | My issues
Edit Prefs
Queries: Wix

Issue 619

Issue #: 619   Platform: VS2005   Reporter: arcadius (Arcadiy Fedushin)
Component: AnkhSVN   OS: Windows XP  
Subcomponent: AnkhSVN   Version: unspecified   CC: None defined
Status: RESOLVED   Priority: P3  
Resolution: FIXED   Issue type: DEFECT  
 Target milestone:2.0 Bugfix 
Assigned to: issues@ankhsvn
QA Contact: issues@ankhsvn
URL:
* Summary: Bad work with read-only files
Status whiteboard:
Keywords:
Attachments:
Date/filename: Description: Submitted by:
Sat Mar 6 15:29:00 -0700 2010: Untitled.png Dialog that shows up with option "allow edit" is off (image/png) Sander Rijken
Issue 619 depends on: Show dependency tree
Issue 619 blocks:
Votes for issue 619:

View issue activity   |   Format for printing   |   Format as XML

Description: Opened: Sat Mar 6 14:35:00 -0700 2010 Sort by: Oldest first | Newest first

I've got into the way of assigning Read-only attribute to source files that are
not currently modified. I'v written a little C# VS Addin for things like that
and make files (not) Read-only by shortkey.
But when I installed AnkhSVN, things became bad: VS began to allow editing of
read-only files. In fact, there's such VS option, Tools > Options > Enviroment >
Documents > "Allow editing of read-only files; warn when attempt to save". I'm
used to disable it, but with AnkhSVN this setting ignored.
Maybe the cause is not AnkhSVN, but bad VS source-control processing - I don't
know, 'cos I never used SCC or smth of that kind before.
Uninstalled AnkhSVN - the problem disappeared...

Config:
Microsoft Visual Studio 2005
Version 8.0.50727.762  (SP.050727-7600)

AnkhSVN - Subversion Support for Visual Studio 2.1.7819.411 
 * Ankh.Package 2.1.7819.411
 * Subversion 1.6.9 via SharpSvn 1.6009.1478.9090

SharpSvn is linked to: Apr 1.3.8, Apr-util 1.3.9, Neon 0.29.3, OpenSSL 0.9.8l 5
Nov 2009, serf 0.3.0, SQLite 3.6.22, Subversion 1.6.9-SharpSvn-tag-1.6.9@909007,
ZLib 1.2.3
SharpSvn is dynamically linked to: Cyrus Sasl 2.1.23
SharpSvn is optionally linked to: Berkeley DB 4.4.20, SharpPlink 1.6009.1478.9090

------- Additional comments from Sander Rijken Sat Mar 6 15:29:49 -0700 2010 -------

Created an attachment (id=52)
Dialog that shows up with option "allow edit" is off

------- Additional comments from Sander Rijken Sat Mar 6 15:38:07 -0700 2010 -------

It seems to be caused by AnkhSVN, we respond to QueryEditFiles that it's OK to edit this file. In order to 
keep the same behavior as Visual Studio without AnkhSVN, it seems that we will need to read the setting 
you described, as well as offer a similar dialog as shown in the attachment. The call to QueryEditFiles does 
not include information that tells us wether the setting is on or off.

------- Additional comments from Arcadiy Fedushin Sat Mar 6 16:14:29 -0700 2010 -------

On one hand it's no problem to read this flag from VS setting at your level
(VSPackage?).
On the other hand, there is another 3rd handy behaviour, not implemented in VS.
It's implemented in IDE "Source Insight": it SILENTLY aborts users if they try
to modify read-only files.
For me, this is much more handy. I need not to press Cancel in dialog from your
attachment every time I mistake.

So, if you'll realize VS-like dialog, please add checkbox "Don't ask more,
remember choice". And if user selected to silently cancel editing of read-only
files, and tries to do so, it would be reasonable to display a warning in statusbar.

As for me, this is one of wanted & handy features, missing in VS.

------- Additional comments from Sander Rijken Sat Mar 6 16:45:34 -0700 2010 -------

Fixed in r7884. Should be available in the upcoming daily build, 2.1.7884 or higher

------- Additional comments from Sander Rijken Sat Mar 6 16:48:08 -0700 2010 -------

I didn't see the request to silently block in time, so that's not part of the commit. I'm not quite sure wether 
we should allow it either. The SDK is pretty explicit in how to implement query edit and query save.

Queries: My issues | Wix