Automatic project detection