Contact

admin

About Me · Send mail to the author(s) E-mail · Twitter

At GROSSWEBER we practice what we preach. We offer trainings for modern software technologies like Behavior Driven Development, Clean Code and Git. Our staff is fluent in a variety of languages, including English.

Feed Icon

Tags

Open Source Projects

Archives

Blogs of friends

Now playing [?]

Error retrieving information from external service.
Audioscrobbler/Last.fm

ClustrMap

Page 1 of 8 in the ToolsAndSoftware category Next Page

ChkDskAll ‒ ChkDsk For All Drives

Posted in .NET | Tools and Software | Windows at Saturday, 14 February 2009 16:41 W. Europe Standard Time

The Windows file systems (NTFS and FAT) are able to automatically detect if they are broken. You can even specify when that automatic check should be performed. But sometimes you would want to force a file system check, for example when Windows suddenly behaves strangely for no obvious reason. (For example last year, the day before I went on a month-long vacation, Vista suddenly refused to boot.)

In order to schedule a file system check for the next reboot you will have to

  1. Open an elevated command prompt or log in as an administrator,
  2. Run chkdsk <Drive>: /f,
  3. Rinse and repeat for all installed drives.

This task isn’t easy for inexperienced users, especially given that they might not know about the chkdsk command line tool in the first place. They could use the UI, but would have to repeat the process for each and every drive nonetheless.

Chkdsk UI

To make this task easier, I wrote a little .NET application that automates scheduling file system check for all drives at the next boot. Just double-click ChkDskAll.exe, enter administrative credentials and wait for the goodness to happen.

ChkDskAll In Action

If a drive has already been scheduled for scanning, it won’t be scheduled a second time. To exclude drives from being included in the scan, have a look at ChkdskAll.exe.config. For example, TrueCrypt drives should be excluded if you do not mount them as fixed drives.

<?xml version="1.0" encoding="utf-8" ?>
<configuration>
    <appSettings>
        <!-- The list of excluded drives, e. g. "CDE". -->
        <add key="ExcludeDrives" value="YZ"/>
    </appSettings>
</configuration>

Importing Subversion Repositories to Google Code

Posted in Tools and Software at Monday, 12 May 2008 15:19 W. Europe Daylight Time

I recently added two of my pet projects to Google Code. I chose Google's Open Source hosting because they  have a very clean UI with integrated issue tracking and also offer native support for Subversion. One of the many aspects that make Subversion a decent choice is the ability to import existing SVN repositories to Google Code. That is, the whole history is uploaded and your soon-to-be open source project doesn't loose valuable undo history. YAGNI? Maybe.

Importing a complete repository to Google Code is well documented, but what if your repository contains several projects and you just want to upload a certain one? Actually Subversion has all you need, there are just a couple of things to prepare. I will provide everything you need here, you may also want to use this excellent write-up (also look here) which I used as a reference. The syntax presented here works on Windows, whereas the author of the above articles was working on a *nix machine, so the command lines differ a bit.

Create your Google Code project and reset the Subversion repository to revision 0

After you created the project on Google Code you can find the "Reset Subversion Repository" link at the bottom of the "Source" tab.

Reset

Prepare your Subversion repository

You need local access to the Subversion server, a Remote Desktop or SSH connection would suffice. I'm assuming your repository is accessible over HTTPS on port 8443. Here are the paths used in the command lines below:

Property Value
SVN repositories root C:\Subversion\
SVN repository containing the project C:\Subversion\projects
Repository URL https://localhost:8443/svn/projects/
Project to import to Google Code https://localhost:8443/svn/projects/foo/Project-FooBar/
Google Code Subversion URL https://project-foobar.googlecode.com/svn/

Dump your repository filtering the project path

First you need to dump the SVN repository containing the project in question. svnadmin dump saves the contents of the repository to the C:\Subversion\project-foobar.dump file on disk. To only take the parts into account we're interested in, use svndumpfilter to exclude everything outside the project path.

Renumbering revisions and dropping empty revisions cleans up the resulting dump and prevents revisions with no changes.

svnadmin dump C:\Subversion\projects\ | svndumpfilter --drop-empty-revs --renumber-revs include /foo/Project-FooBar/ > C:\Subversion\project-foobar.dump

Including (and dropping empty revisions for) prefixes:
   'foo/Project-FooBar'

* Dumped revision 0.
Revision 0 committed as 0.
* Dumped revision 1.
Revision 1 skipped.
...

Create a new repository for the project

Now that you have dump in place, create a new repository for Project-FooBar.

svnadmin create C:\Subversion\project-foobar-import

Create directories needed to load the dump

To make the import process succeed, you have to create the paths that are not included in the dump, i.e. all directories above the path that was included by svndumpfilter. In the our case, this is the /foo directory.

svn mkdir https://localhost:8443/svn/project-foobar-import/foo/ -m "Folder created for import"

Committed revision 1.

Load the filtered dump

It's time to import the dump to the repository just created.

svnadmin load C:\Subversion\project-foobar-import < C:\Subversion\project-foobar.dump

<<< Started new transaction, based on original revision 1
     * adding path : foo/Project-FooBar ... done.
     * adding path : foo/Project-FooBar/trunk ... done.
...

If you didn't create all necessary directories in the last step, you will receive an error message like this:

<<< Started new transaction, based on original revision 1
     * adding path : foo/Project-FooBar ...svnadmin: File not found: transaction '1-1', path 'foo/Project-FooBar'

Move directories such that they follow the standard Subversion directory structure

Your can now have a look at the new repository by pointing your browser to https://localhost:8443/svn/project-foobar-import/ where you only should see Project-FooBar.

The next step moves the project to the root of the repository and aligns the directory structure with Subversion's default directory layout.

svn move https://localhost:8443/svn/project-foobar-import/foo/Project-FooBar/trunk/ https://localhost:8443/svn/project-foobar-import/trunk/ -m "Folder moved"
svn move https://localhost:8443/svn/project-foobar-import/foo/Project-FooBar/tags/ https://localhost:8443/svn/project-foobar-import/tags/ -m "Folder moved"
svn move https://localhost:8443/svn/project-foobar-import/foo/Project-FooBar/branches/ https://localhost:8443/svn/project-foobar-import/branches/ -m "Folder moved"
svn delete https://localhost:8443/svn/project-foobar-import/foo/Project-FooBar/ -m "Folder deleted"

Upload your Subversion repository to Google Code using svnsync

All set. The last step is to upload your Subversion repository to Google Code using the documented command line below.

svnsync init https://project-foobar.googlecode.com/svn/ https://localhost:8443/svn/project-foobar-import/
Copied properties for revision 0.

svnsync sync https://project-foobar.googlecode.com/svn/
Committed revision 1.
Copied properties for revision 1.
...

The whole import process will take a little bit, depending on the size of your repository. It took me about 40 minutes for a repository with about 100 revisions, time to grab a cup of coffee.

The script

Of course you can script the whole process:

@rem Create dump
svnadmin dump C:\Subversion\projects\ | svndumpfilter --drop-empty-revs --renumber-revs include /foo/Project-FooBar/ > C:\Subversion\project-foobar.dump

@rem Create repository for import
svnadmin create C:\Subversion\project-foobar-import

@rem Create directories needed for the import to succeed
svn mkdir https://localhost:8443/svn/project-foobar-import/foo/ -m "Folder created for import"

@rem Load dump
svnadmin load C:\Subversion\project-foobar-import < C:\Subversion\project-foobar.dump

@rem Move folders around
svn move https://localhost:8443/svn/project-foobar-import/foo/Project-FooBar/trunk/ https://localhost:8443/svn/project-foobar-import/trunk/ -m "Folder moved"
svn move https://localhost:8443/svn/project-foobar-import/foo/Project-FooBar/tags/ https://localhost:8443/svn/project-foobar-import/tags/ -m "Folder moved"
svn move https://localhost:8443/svn/project-foobar-import/foo/Project-FooBar/branches/ https://localhost:8443/svn/project-foobar-import/branches/ -m "Folder moved"

svn delete https://localhost:8443/svn/project-foobar-import/foo/Project-FooBar/ -m "Folder deleted"

@rem Sync with Google Code
svnsync init https://project-foobar.googlecode.com/svn/ https://localhost:8443/svn/project-foobar-import/
svnsync sync https://project-foobar.googlecode.com/svn/

Siemens Gigaset QuickSync on Vista x64

Posted in Hardware | Tools and Software | x64 at Saturday, 19 January 2008 16:12 W. Europe Standard Time

Siemens Gigaset SL 370I recently purchased the Siemens Gigaset SL 370 phone for home telecommunications. The SL 370 is Siemens' premier DECT phone with a form factor comparable to mobile phones. It has plenty of advanced features, the most appealing one being Bluetooth support for headsets and, more importantly, syncing abilities with Outlook contacts. That is, you can sync your Windows Vista Contacts folder or Outlook contacts wirelessly over a Bluetooth connection.

On the SL 370 product support site there's a download option for the Gigaset QuickSync software needed for synchronizing the contact stores on your computer and the handset device. The software version I'm using is the current version 2.0 which needs the .NET Framework 2.0 to run (which is a good thing, see below).

The SL 370 is a great piece of hardware, good sound quality, very light, well thought out and with outstanding battery life.

However, there are some issues with the QuickSync software with Outlook 2007:

Gigaset QuickSync refuses to run on x64 versions of Windows Vista

After launching QuickSync on Vista x64, Windows instantly shows the generic "Program stopped working" dialog.

Gigaset QuickSync stopped working

After clicking the "Debug" button Visual Studio starts up revealing that an assembly of the Gigaset QuickSync package refused to load. When the application's main executable (GigasetQuickSync.exe) tries loading PCABManager.dll a BadImageFormatException is thrown.

BadImageFormatException

As one can glimpse from the screenshot above the PCABManager.dll assembly is not strong named (PublicKeyToken=null), so I could leverage some of the .NET Framework SDK tools to make QuickSync behave on Vista x64.

Open up a Visual Studio Command Prompt and run corflags.exe on the GigasetQuickSync.exe and PCABManager.dll assemblies.

corflags /32bit+ GigasetQuickSync.exe
corflags /32bit+ PCABManager.dll

The 32-bitness flags should be set afterwards

>corflags GigasetQuickSync.exe
Microsoft (R) .NET Framework CorFlags Conversion Tool.  Version  3.5.21022.8
Copyright (c) Microsoft Corporation.  All rights reserved.

Version   : v2.0.50727
CLR Header: 2.5
PE        : PE32
CorFlags  : 1
ILONLY    : 1
32BIT     : 1
Signed    : 0

This resolves the load errors on Vista x64 as we now force the 32-bit .NET Framework runtime to load. More technical details can be found on Scott Hanselman's blog (about 50% into the post).

Deleted Outlook contacts sync back

Because the phone has only a limited number of contacts (250) there's a filter dialog that can be used to tell the Gigaset QuickSync software which contacts should not be transmitted to the handset. Note that QuickSync will only load contacts that have a telephone number, so the contact count might differ from what Outlook reports.

QuickSync Contact Filter Reports 198 Contacts

Outlook Reports 219 Contacts

Nice, but today flash memory is cheaper than ever before. Why did the SL 370 product designers choose to have only 250 contacts on a 120 € phone?

One (unresolved) problem I experience with the "syncing" ability is that if you delete an Outlook contact and re-sync the previously deleted contact will be recreated in Outlook. I suppose this is a known bug. One work-around is to delete all contacts on the phone before syncing.

Conclusion

The SL 370 is a great phone: I adore its flyweight, the clean UI, the great battery power and the rich set of options like turning down the ringtone volume at nighttime. The weaknesses on the Windows software side should be fixed in the next release of the QuickSync.

Now Playing [?]: Sie – Ruban D'AlphaCiru catena

Session Manager Available On CodePlex

Posted in ASP.NET | DNUG Leipzig | Tools and Software at Monday, 10 September 2007 20:09 W. Europe Daylight Time

Our Dilemma

For this year's .NET Summercamp 2007 we find ourselves in the lucky position of having more speakers and session suggestions than slots available. What we needed was a session suggestion and rating system allowing our speakers to submit proposals that could later be approved by us. Of course there are large conference management systems out there, often with boatloads of unneeded functionality like billing. We rather wanted to use a simple tool at no cost.

The Solution

So I went and wrote it myself an ASP.NET 2.0 web application. The outcome of my efforts, named Session Manager, is available on CodePlex. Session Manager is free software licensed under the BSD License.

Session Manager Screen Shot

If you're running a user group or plan to organize larger events besides regular user group meetings, Session Manager certainly is worth a try. If you find it not yet perfect, please go ahead grab the source code and customize it to your needs or post a suggestion. I already wrote down some ideas on improvements.

Session Manager was a great opportunity to build an application with the Model View Presenter and WebNavigator patterns in mind. One has to write a little more code (mostly interface definitions) but gains great testability and portability across web and rich clients.

Demo

I've created a demo installation based on the current version. Go ahead and fiddle, you can't damage anything.

Have fun!

Folien meines Vortrags vom .NET Wintercamp 2007 in Leipzig

Posted in DNUG Leipzig | Presentations | Tools and Software at Thursday, 22 March 2007 19:34 W. Europe Standard Time

Der Foliensatz des heutigen Vortrags mit dem Titel Tools aus dem Basement kann nun heruntergeladen werden. Ich hoffe alle Teilnehmer hatten so viel Spaß wie ich. Für Rückfragen stehe ich natürlich per E-Mail oder Kommentarfunktion zur Verfügung. Noch einmal der Hinweis zu den orangefarbigen Links in der Präsentation: Das Kürzel einfach hinter den URL http://www.shrinkster.com/ setzen und Sie gelangen zur referenzierten Seite. Oder nutzen Sie alternativ einen der unten aufgeführten URLs.

Bisher schätze ich das .NET Wintercamp als sehr gelungene Veranstaltung ein, auch wenn ich aufgrund meiner Arbeit nur Abends anwesend sein kann. Gerade die gut besuchten Abendveranstaltungen, wie z. B. das Buffet der ECG Erdgas-Consult GmbH aus Leipzig, das Spanferkel, gesponsert durch Microsoft Deutschland und die gestrige Brauereiführung mit anschließendem Abendessen im Restaurant FELIS zeigen, dass es in Leipzig eine große Anzahl an .NET Technologien interessierter Entwickler und Studenten gibt. Ich freue mich auf Anmeldungen bei der .NET User Group Leipzig!

Links

Now Playing [?]: BonoboDays to comeIf you stayed over (featuring Fink)

Page 1 of 8 in the ToolsAndSoftware category Next Page