[Mono-bugs] [Bug 505341] The Windows Installer should generate relocatable BAT files

bugzilla_noreply at novell.com bugzilla_noreply at novell.com
Thu May 21 11:56:15 EDT 2009


http://bugzilla.novell.com/show_bug.cgi?id=505341

User kramieb at gmail.com added comment
http://bugzilla.novell.com/show_bug.cgi?id=505341#c3





--- Comment #3 from Dykam None <kramieb at gmail.com>  2009-05-21 09:56:14 MDT ---
Fixed script, contained gsharp characters:

Action<string> Recurse = delegate(string path) {
    if(File.Exists(path)) {
        string file = File.ReadAllText(path);
        file = file.Replace("C:\\PROGRA~1\\Mono-2.4\\bin\\", "%~dp0\\");
        file = file.Replace("C:\\PROGRA~1\\Mono-2.4\\lib\\",
"%~dp0\\..\\lib\\");
        File.WriteAllText(path, file);
        return;
    }
    if(Directory.Exists(path)) {
        foreach(string dir in Directory.GetDirectories(path)) {
        Recurse(dir);
        }
            foreach(string file in Directory.GetFiles(path, "*.bat")) {
            Recurse(file);
        }
    }
};
Recurse(@"L:\PortableApps\Mono-2.4\bin");

-- 
Configure bugmail: http://bugzilla.novell.com/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are the QA contact for the bug.


More information about the mono-bugs mailing list