SPSync v0.9 is now available

Ok, the last version is almost 9 month old, but now I finally had some time to look through all comments on uservoice and now proudly present the new version.

What's new?

The major change is: SPSync now supports Office 365 authentication which means, you can finally use SPSync with SharePoint Online and SkyDrive Pro. Just select "Office365" from the authentication list and enter your username (user@customdomain.com or user@customdomainpart.onmicrosoft.com) and your password. Domain is not required.

image

Also an issue with creating folders is now fixed and it doesn't matter anymore whether the title of a document library is not the same as the URL of the document library.

A reminder: The "Conflict Handling" is a setting just for conflicts. If you select "Overwrite local changes" it does not mean that a full sync is done. A conflict is if a file is modified locally and remotely. All other files are sync'ing independently from this setting.

Download the new version here: http://spsync.net and leave a comment or drop me a line at
support (at) spsync(dot) net

Windows Phone 8: StadtRAD Finder

Leider gibt es für das StadtRAD in Hamburg bisher nur iOS und Anroid Apps. Ich habe daher die Gelegenheit genutzt und eine Windows Phone 8 App gebaut. Sie zeigt den aktuellen Standort und alle Standorte der StadtRAD Stationen inkl. der Anzahl verfügbarer Fahrräder.

Einfach downloaden und testen:

258x67_WPS_Download_DE_cyan

stadtradfinderapp

Delete project from tfs.visualstudio.com

Just a short reminder for me, how to delete a project from tfs.visualstudio.com, because there is no UI to do that:

Open a Developer Command Prompt and type:

tfsdeleteproject /force /collection:https://xxx.visualstudio.com/DefaultCollection "YourProjectName"

Chocolatey: Package Manager für Windows

Aus Linux kennt man ggf. apt-get um Software/Tools zu installieren. Für Windows gibt es eine wirklich gute Alternative: https://chocolatey.org

Das ganze basiert auf http://nuget.org dem Microsoft .NET Package Manager. Es gibt bereits extrem viele Pakete und man kann problemlos eigene Pakete erstellen und hinzufügen.

Um Chocolatey zu installieren, einfach folgendes in die Kommandozeile eingeben:

@powershell -NoProfile -ExecutionPolicy unrestricted -Command "iex ((new-object net.webclient).DownloadString('https://chocolatey.org/install.ps1'))" && SET PATH=%PATH%;%systemdrive%\chocolatey\bin

Zum Test habe ich direkt Proxy Switcher als Paket hinzugefügt. Um Proxy Switcher zu installieren muss nun einfach folgendes eingegeben werden:

image

SPSync v0.8

SPSync is now available in version 0.8. It has a bunch of bug fixes and a better tested sync engine.
Also it is tested on Windows 7 and Windows 8 against SharePoint 2010 and SharePoint 2013.

With Office 2013 you get SkyDrive Pro for free which is the Microsoft tool to sync a local folder with a SharePoint document library. However, this tool has some disadvantages:

  • Obviously, you need Office 2013. SkyDrive Pro cannot be downloaded independently.
  • You can define only one root folder, where all of your document libraries will show up. With SPSync you can sync any folder you like.
  • With SkyDrivePro you have no control what happens with conflicts. In SPSync you can define whether you would like to see a conflict dialog, always overwrite local changes or always overwrite remote changes.

SPSync now has a new installer and is no longer a "ClickOnce" application. It does not require administrator rights.

Download here: http://spsync.net

To provide feedback use support (at) spsync(dot)net or the FEEDBACK button on http://spsync.net

Sync SharePoint Document Libraries in Windows Explorer like Dropbox

A few weeks ago I started working on a new tool. All of you know Dropbox: It has nearly zero UI and just do what it is supposed to do.

I’m working a lot with SharePoint 2010 as it is my job and I also really like it. What I don’t like is how to work with document libraries that are mainly used as a file store. Of course, I know meta data and all these stuff what you can do with SharePoint, but sometimes you just want to synchronize a folder within Windows Explorer with a document library in SharePoint.

Microsoft already created a tool for that (or better: bought it from Groove ;-) It is now called SharePoint Workspace. It can sync document libraries and also custom lists. You then have an offline copy of an entire SharePoint site. BUT: It is somewhere “within SharePoint Workspace”. You cannot define a “normal” folder on your hard disk as the sync target.

That’s why I’ve created a new tool called SPSync which is intended to close the gap.

User Interface

The UI of SPSync mainly consists of an icon in your taskbar:

image

 


It has a context menu, where you can manage all sync configurations:

image

image

 

 

 

 

 

 

A configuration consists of a name, the local folder, the SharePoint site URL, the title of the document library, the conflict handling mode and the credentials to use. If the conflict handling mode is set to manual, a balloon will popup on any conflict and you can choose what you want to do.

That’s all for now what you can configure, but I will extend it in the next weeks/months.

Technical Details

First of all: The password is stored encrypted with the Windows Data Protection API and bound to the current user. Therefore it cannot be decrypted on any other machine or by any other user on the same machine.

The communication with SharePoint is done by the SharePoint Client Object Model (Client OM). The sync core is built from scratch and contains a meta data store to also be able to handle deleted files. SPSync checks for changes automatically every 30 minutes and also actively monitors the local folder for any changes. That means local changes are sync’d immediately to SharePoint.

Currently there are no overlay icons within the Windows Explorer (like you have it for the Dropbox folder), because those Explorer Shell Extensions require a native (C++) implementation.

How to get it?

Visit http://spsync.net to get more information.

Visual Studio Achievements

Viele kennen sicher diesen Blog Eintrag. Sehr lustig, und nun gibt es sie wirklich, die VS Achievements.

Dank Channel9 gibt es neben der Visual Studio Extension auch noch eine REST API und ein fertiges Widget. Meine Achievements seht ihr rechts in der Leiste. Einige sollten aber eher Minuspunkte geben... ;-)

Also ladet euch die Extension runter und sammelt fleißig Achievements.

Neues Jahr, neue Blog Engine - Roadmap für 2012

Ich möchte dieses Jahr wieder mehr zu meinen Projekten schreiben. Ich habe da einige gute Ideen.

Das erste Projekt auf der Liste: Mein etwas angestaubtes Blog, basierend auf dasBlog durch eine neuere Engine ersetzen. Das habe ich nun gemacht und wenn du das hier liest, funktioniert BlogEngine.NET wohl. Das letzte dasBlog Release ist von 2009, wobei auf Codeplex weiter fleißig auch am Source gearbeitet wird. Dennoch habe ich mich entschieden zu wechseln. Das einzige was ich bisher vermisse ist die OpenId Integration. BlogEngine.NET hat da leider noch nichts. Zumindest konnte ich nichts finden.

Außerdem habe ich bei der Gelegenheit das Application Request Routing (ARR) Modul für den IIS installiert, damit die meisten alten Blog Links auch weiterhin funktionieren. Dazu habe ich einfach ein paar Redirect Rules erstellt. Somit funktionieren die alten Artikel Links auch weiterhin.

Eine weitere Neuigkeit ist: Proxy Switcher hat nun auch eine eigene URL (http://proxyswitcher.net). Das Ziel ist dort auch bald nicht nur einen Redirect zu haben, sondern eine eigene Seite.

NuGet Package Manager or How to make “source code sharing” across projects much better

Introduction

In a company with more than one development project sometime it happens that someone says: Hey, we need a common logging component shared across all projects.
Now the solution could be to develop such a logging component and share the assembly with all projects. However, if there is some code that should/must be unique to each project it is a bit more complicated. If you want to do that with SharePoint 2010 and build a logging component on top of the ULS log and want each project to be configurable in the Central Administration you need to know all future projects and categories or you need some unique code.

Note: The logging component is only a very easy example and might not be the best one.

NuGet

Microsoft created NuGet. A package manager for Visual Studio. Quote of the official site:

NuGet is a Visual Studio extension that makes it easy to install and update open source libraries and tools in Visual Studio.

You can add it easily to Visual Studio 2010 by Tools->Extension Manager. Search for “NuGet”. After it is installed, you can add packages to a project by right clicking on a project in the Solution Explorer and click “Add Library Package Reference…”

image

Now as a company you don’t want your super-fancy code to show up for everyone as open-source. Therefore, NuGet can have more than one package source. You can even use a file share. Open Tools->Library Package Manager->Package Manager Settings:

image image

Bring it together

To get rid of “each project copy the source from the source of the other project from the source of the source of the source from another project” you can now use NuGet.

The idea is:
- Create the Logger.cs file
- Add TODOs to the code where the developer need to change something
- Make a NuGet package from it
- Let the project teams use the NuGet package (and distribute updates to the source automatically as well!)

Advantage: There is only one source! And if the owner of the NuGet package updates it, all project teams will be automatically notified about an update!

Create the NuGet package

In my example I talk about the comon logger component. A single Logger.cs file. However, NuGet can handle even more complex packages with PowerShell code, etc.

So download the NuGet command-line tool and create a new folder where all the stuff for the package will go to.

Open a command prompt and enter:

nuget spec

This will automatically create an empty package specification file called Package.nuspec. Open this file in notepad and modify the required values. Also rename the file to match the id property.

image

Now create a folder called “content”. Everything in this folder will be merged into the solution on installation of the package. So I put the file Logger.cs in this folder.
However, I don’t want that all users are required to use the same namespace, so you can change the file extension to “.cs.pp” to let NuGet “pre-process” the file.

Within the file you can then set some tokens to be replaced on installation. You can find a list of available properties here on MSDN.

The folder structure looks like this:

image

And the Logger.cs.pp in the content folder:

image

As you can see, I used the token $rootnamespace$. That one will be replaced by the root namespace of the target project.

Ok, lets make a package:

nuget pack

The output is a file called SPLogger.1.0.nupkg. You can publish it to the official NuGet package server or use it only internally by copying it to a file share.
Now open Visual Studio add the file share as a package source and search for it in the “Add Library Package Reference” window or open the NuGet console in Visual Studio (View->Other Windows->Package Manager Console) and type:

Install-Package SPLogger

image

That’s it. If you change the version number in your .nuspec file, create a new package and copy it also to your file share, the project team can decide to update to the latest version in the “Library Package Reference” dialog. You can even uninstall the package and everything will be removed from the project without leaving anything behind.