Private source control with TortoiseGit and Dropbox

One of the most important parts of a software development project is how source control is used. This is how you manage the actual resources of the implementation of your project. There are several options and I will describe how I setup a private source control repository using TortoiseGit and Dropbox.

There are free options to host your repositories online but they are usually also asking you to open it to the public. Great for open source projects but not if you just want to hack away on your own project.

I have come to use a solution where I create a bare bone Git repository in my Dropbox folder. Then I clone this to a working folder and use it as my home folder for development. I use the features of TortoiseGit to commit and sync any changes.

This way I can simply share a repository between my desktop and laptop by using Dropbox to sync on both and then clone the bare bone Git repository to a working folder on each computer.

This solution gives me all of the benefits of Git source control and I keep the repository on several locations as it is copied to both my computers and the Dropbox cloud storage. This fulfills the basic requirement for any professional software development setup.

Setting up the content manager server…NOT!

Time to get back to installing Tridion in my virtual machine. This is to be able to learn more and to do some testing and development locally.

I setup the webserver and application server roles, with the required features as in the installation manual.

After having followed the installation manual it seem the only missing components are java, I decided to try to use the latest, 32 bit version, of java. Java 7u9.

First time running the installer, all default settings and complete installation. Though I opted to install into C:Tridion instead of in program files folder. It turns out I am missing a few prerequisites. Since I prefer to control the installation as much as possible I will go ahead and install them manually.

I did not manage to get them all installed and detected by the installer and went ahead anyway and hoping the installer would sort it out.

After having filled in all passwords for the various features I needed to add an entry in the hosts file for tridioncme as I named the site that. In IIS manager I remove the default website.

And I am stuck, the installer is for vanilla Tridion 2011 and I need a fixed installer to get it up and running on Windows Server 2012.

Installing the Tridion 2011 databases

I have had to adjust the settings for SQL Server to allow also SQL Server authentication. I also set the password for the sa user account. Same as the password I will use for all accounts. I also neede to enable the account.

The next issue I ran into was that it need MSXML 4 installed, which was quickly solved by downloading it from Microsofts site and installing it. I also managed to install the VMWare tools, finally. They were unavailable when I started this project but not I got them, not sure what they will improve but it feels better to have them in place.

When I ran the database manager tool, I installed all types of databases using all default settings. As password I kept on using Tridion2011. I am getting fast at typing that on my gaming keyboard. 🙂

Technology Specialist

Almost exactly 10 years ago I got my first and only Microsoft certification. I took and passed the exam Microsoft Certified Professional for Designing and Implementing Desktop Applications with Microsoft Visual Basic 6.0. Today I took and passed my second certification, Microsoft Certified Technology Specialist Web Applications Development with Microsoft .NET Framework 4. Now I just need to make sure it isn’t 10 years to next certification.

 

I missed a few

I went through my backup from the blog I had over at live.com and notices I missed quite a few posts. I am not a very regular blogger but have managed to get a few written over the years.

These are the ones I missed to copy here:

  • How many beers does it take to install Windows Vista?
  • MSDN Wiki beta
  • Building Rotor (SSCLI) on Windows Vista
  • WebBrowser and the DocumentCompleted event
  • A neat little calculator
  • Dialogs that pop up while typing
  • Did you win the Microsoft Lottery?
  • Visual Studio Orcas Beta 1
  • Shell context menu sample in C#
  • Mobile phones used as boomboxes
  • Vista UAC
  • Visual Studio Orcas March CTP
  • Pentax Optio E20 quickly changed to Samsung Digimax S700
  • Making life easier with Vista UAC
  • Why are everyone bashing Vista?
  • Vista is nice, but not all the time
  • Vista is here
  • Catching WM_MOUSEWHEEL and redirect it in .NET (C#/VB)
  • Have you seen my january MSDN shipment?
  • Windows 7 Here We Go!
There are some interesting topics. I will add the backlog of these posts soon.

MySql with entity framework under partial trust hosting

I have a few websites like this blog hosted at a site where my web application must be able to run under partial trust and other limitations as I share the server with many other websites. It would be way to expensive to use dedicated hosting as my sites are non-commercial.

I am now studying to take a couple of exams and decided to come up with a few ideas and try to realize them. One idea was a link shortener and when I deployed an alpha version to my hosting provider I started to run into all sorts of issues. I had it already running well in Cassini, the development webserver for Visual Studio, using MySQL backend and entity framework under .NET 3.5.

First of all it was the issue that later versions of the .NET Connector for MySQL requires full trust and that is not about to happen. All used assemblies must define that it allows to be called in a partial trust scenario. The specific assembly that was the culprit was MySql.Data.Entity.dll. I downloaded the source for the connector and added it to my solution. Then I was able to add the line to allow partial trust callers. In AssemblyInfo.cs I added the following:

using System.Security;
[assembly: AllowPartiallyTrustedCallers()]

Now I ran into another issue, the DbProviderFactory no longer had a public key and I had to adjust it in the web.config file. Just replace the key with null.

<add name=”MySQL Data Provider” invariant=”MySql.Data.MySqlClient” description=”.Net Framework Data Provider for MySQL” type=”MySql.Data.MySqlClient.MySqlClientFactory, MySql.Data, Version=6.3.6.0, Culture=neutral, PublicKeyToken=null” />

I yet again deployed it and tried to run into another security exception. This time in the MySqlTrace class. It is a set of static methods to help trace runtime information. I don’t need it and noticed that by commenting out all code in the constructor it would be disabled.

static MySqlTrace()
{
    //foreach (TraceListener listener in source.Listeners)
    //{
    //    if (listener.GetType().ToString().Contains(“MySql.EMTrace.EMTraceListener”))
    //    {
    //        qaEnabled = true;
    //        break;
    //    }
    //}
}

This time everything worked as it should and I am now able to use MySql and entity framework in a .NET 3.5 web application that is hosted with only partial trust allowed. A few more tweaks and the link shortener should be ready!