This Bugzilla instance is a read-only archive of historic NetBeans bug reports. To report a bug in NetBeans please follow the project's instructions for reporting issues.
Reproducible with S1S build 030319 on Win2K platform. Mount generic CVS repository. Create a folder, add it to CVS. Now create a file in this folder. Add this file to CVS and call commit command. 'Wincat.bat' node will appear in the explorer view. But there is no such file on the host. It doesn't happen if we create a file in the root node.
I was able to reproduce it. It gets into Explorer due to the refresh called after commit, the physical file is deleted right after commit finish, but the file can not disappear from Explorer due to the default refresh time == 0. The fact, that Windows do not have a command like UNIX cat brings a lot of problems (associated issue #27102).
After the fix of issue #27102 the problem might be more important, so increasing the priority. It's almost impossible to do filtering in VcsFileSystem.children(), but maybe the refresh of the folder after commit is not necessary. If the refresh is not performed the wincat.bat should not appear in the Explorer at all.
isint windows 'type' command like UNIX 'cat' command? after commit the status must be changed, can this be done without refresh? I dont think CVS refresh is necessary but the nodes need updating.
'type' is not an editor which is required by cvs.exe binary. It's only command of cmd.exe. As for not calling refresh, I also proposed this to Martin in person but must investigate it first.
Why is cat needed and what is it doing anyway? I do not understand this because I have other cvs applications like wincvs that done seem to have issues.
> Why is cat needed and what is it doing anyway? It's a way how can I obtain the commit template and the list of committed files from CVS. I need to present the same information that you have when you do cvs ci on the command line. cvs.exe opens an editor (e.g. notepad.exe) and gives it some temporary file with some text. And I need to get that text and present it in NetBeans, not in Notepad. The simple solution in UNIX world is to supply 'cat' as the editor and then simply read the commit template from the standard output. This work reliably and it's easy. But what is easy on UNIX is a terrible overkill on Windows. Since 'type' on Windows is not an executable, cvs -e type does not work. So I've created an "executable" wincat.bat which is nothing more than 'type' wrapped in a batch file so that it gets interpretted by the shell. It works O.K., but there is one "small" problem: where to put that file??? The conclusion is, that it must be in all directories, that cvs inspects so that it will always find it. Because I can not pass the absolute path to that file because of the problem with space in path. I've no idea how wincvs solves this problem, but my impression is, that wincvs has some special access to cvs.exe. IMHO they're able to get the commit template directly, I doubt thay do some quirks with the template editor.
I think its worth investigation. I know wincvs does not have _any_ special access to cvs.exe. its a totally seperate program.
oups:/ I didn't find this issue so I anter a duplicat issue #32834 I'm gonna attach the Exception stack trace....
Created attachment 9891 [details] stacktrace
The IOException must occur, because the wincat.bat file is deleted as soon as the commit command finish. The exception can not be "fixed".
dnoeB: I've just played a while with wincvs 1.3.12.1. It does not seem to handle the templates like we do in NetBeans. Commit presents you an empty text area and in :local: connection method you will not get the template even if it's in rcsinfo. Perhaps it's reads just CVS/Template file if exists (in local mode CVS/Template file is not created on checkout). So, if we like to have the nice template in the commit dialog, we can not live without wincat.bat :-((( The problem that it stays in the explorer can be simply solved by renaming the file to some name that will not likely exist in the user directory and filter it by default. If we use a name like .nbcicat.bat it's a very low probability that the user will have a file of that name so we can filter it by default like we filter .nbattrs. Since I don't have a better solution and this is a quite nasty bug I'm going to solve it this way.
I am definetely for this. Even if there is a guy who has .nbcicat.bat file in his working directory and he won't see it in the IDE, he deserves it ! :-) In the worst case we will get another P1 issue ...
Fixed in the main trunk as proposed. The fix is trivial and seems to work O.K. However it's necessary to remount the CVS filesystem for the filtering to take effect, or you can add ".nbcicat.bat" to the value of LOCAL_FILES_FILTERED_OUT variable manually as it is in the contextual diff. Jiri or others, please adjust the priority accordingly if you want this to be fixed in NB 3.5. Checking in commands/CvsCommit.java; /cvs/vcsgeneric/profiles/cvsprofiles/src/org/netbeans/modules/vcs/profiles/cvsprofiles/commands/CvsCommit.java,v <-- CvsCommit.java new revision: 1.11; previous revision: 1.10 done Processing log script arguments... More commits to come... Checking in config/cvsWin.xml; /cvs/vcsgeneric/profiles/cvsprofiles/src/org/netbeans/modules/vcs/profiles/cvsprofiles/config/cvsWin.xml,v <-- cvsWin.xml new revision: 1.36; previous revision: 1.35 done Checking in config/cvsWin98.xml; /cvs/vcsgeneric/profiles/cvsprofiles/src/org/netbeans/modules/vcs/profiles/cvsprofiles/config/cvsWin98.xml,v <-- cvsWin98.xml new revision: 1.35; previous revision: 1.34 done
Created attachment 10022 [details] The contextual diff of the fix.
Created attachment 10023 [details] The binary patch. To apply, put into <NB-install>/modules/patches/org-netbeans-modules-vcs-profiles-cvsprofiles/ folder.
Created attachment 10024 [details] The updated cvs profiles. Unpack in <NB-user-dir>/system/vcs folder and remount the FS OR ajdust LOCAL_FILES_FILTERED_OUT variable as described above.
This is regression in functionality, annoying and visible enough to document it. Adding appropriate keyword. I honestly regret we didn't make it for FCS of Sun ONE Studio 5.0.
proposed relnote: A Wincat.bat node appears in the Explorer after you run the Commit command on a generic VCS filesystem. The node is harmless, so you can ignore it.
I think it's clear. However, it occurs only sometimes i.e. not all users will experience it. Can you Martin shed some light on this ? I know it happens on Windows only and with user dir containing space. Is it right ?
Yes, Jiri is right. It happens only under these two conditions. The wincat.bat nodes can be dismissed by Refresh.
Thanks for the info. Second attempt: "When running on Microsoft Windows systems and there is a space in the name of your user directory, a Wincat.bat node appears in the Explorer after you run the Commit command on a generic VCS filesystem. Workaround: The node is harmless, so you can ignore it. Or you can remove it by running the Refresh command on the filesystem." I think it's clear. However, it occurs only sometimes i.e. not all users will experience it. Can you Martin shed some light on this ? I know it happens on Windows only and with user dir containing space. Is it right ? ------- Additional Comments From Martin Entlicher 2003-04-25 06:43 PDT ------- Yes, Jiri is right. It happens only under these two conditions. The wincat.bat nodes can be dismissed by Refresh.
Excellent. I am ignoring the comments from Martin and me ... ;-)
Perfect, it works as intended. No .nbcicat.bat nodes appear in the explorer now. Verified in development build #200308060100 of NetBeans 4.0.
Confirmed as fixed in Sun ONE Studio 5.0 patched with Update 1.
Fixed also in Nevada Patch 1 and in Arrow. (and confirmed verfied by Jirka above...)
removing RELNOTE keyword