From: John Tapsell Date: Tue, 24 Mar 2009 02:08:37 GMT Subject: Re: .gitk should created hidden in windows Message-ID: <43d8ce650903231908y54bb1c34t45a78f218b2ccd9f@mail.gmail.com> In-Reply-To: <18887.26239.115820.450313@cargo.ozlabs.ibm.com> 2009/3/23 Paul Mackerras : > Steve Wagner writes: > >> The problem is that windows dose not hides files beginning with a dot as >> it is in unix. So the .gitk file is created as visible in the windows >> user profile. Problematic too is that i can no set the hidden attribute >> to this file, because it is recreated every time i start gitk, so the >> hidden attribute gets lost. >> >> Can you control this and create the file with the hidden attribute on >> windows? > > Please try this patch and let me know if it does what you want. > > Paul. > > diff --git a/gitk b/gitk > index d7de27e..54f3f2b 100755 > --- a/gitk > +++ b/gitk > @@ -2487,6 +2487,9 @@ proc savestuff {w} { >     if {![winfo viewable .]} return >     catch { >        set f [open "~/.gitk-new" w] > +       if {$::tcl_platform(platform) eq {windows}} { > +           file attributes "~/.gitk-new" -hidden true > +       } >        puts $f [list set mainfont $mainfont] >        puts $f [list set textfont $textfont] >        puts $f [list set uifont $uifont] How about making all files beginning with . hidden? .gitignore for example