The Wiert Corner – irregular stream of stuff

Jeroen W. Pluimers on .NET, C#, Delphi, databases, and personal interests

  • My badges

  • Twitter Updates

  • My Flickr Stream

  • Pages

  • All categories

  • Enter your email address to subscribe to this blog and receive notifications of new posts by email.

    Join 1,860 other subscribers

Archive for the ‘Delphi’ Category

I’m Speaking at EKON 17; early bird ends on Friday October 4th 2013: save EUR 100 and get a free Android tablet.

Posted by jpluimers on 2013/10/03

Early bird ends October 4th: get an Android tablet for free and save EUR 100!

Early bird ends October 4th: get an Android tablet for free and save EUR 100!

EKON17 (from November 4-6 in Cologne, Germany) will be a fun event this year: lots of nice sessions and workshops, a lovely city (not just the Dom Cathedral), and a great group of speakers.

Since there are so many speakers that are able to speak English, it is interesting for non-German attendees as too, especially the post-conference workshop from Nick Hodges.

I’ll be speaking too (more on that below) and will be there all 3 days (plus the evening before and morning after to aid people with their Delphi related questions).

Among the speakers, these will do their sessions in English:

Posted in Conferences, Delphi, Delphi XE5, Development, EKON, Event, Software Development | Tagged: , , | Leave a Comment »

Some notes and links on DVCS (distributed version control systems)

Posted by jpluimers on 2013/10/01

I love DVCS for one single reason: merges are so much easier than with traditional version control systems, and you can use it in a disconnected way for almost 100% of the time. Coming from a traditional world, interoperability is key. So here are some links that greatly helped my getting started with DVCS (a really long while ago; this post has been way overdue).

The meaning of D

Usually, the D in DVCS is regarded as distributed. But it can have multiple meanings (even at the same time), depending on how you use it.

  • Distributed (the repository is available on all systems that have forked it, lessening the need centralized backups)
  • Decentralized (there is no need for a central server, though a certain structure in how you fork, pull and push (or pull request) can make life a lot easier)
  • Disconnected (a big plus: you can work off-line most of the time, and still perform your day to day work, but sometimes you want it to be truly distributed, and tools for that exist too)
  • Dynamic (especially for open source projects: being able to fork projects and perform pull requests has allowed to open source world to work in a much more dynamic way)

The reason to go D

Because it leads to experimenting, which makes you a better programmer: Version Control Makes You A Better Programmer | Cocoa Is My Girlfriend.

Because you will never lose your repository: Embarcadero Discussion Forums: XanaNews users ….

Because… Intro to Distributed Version Control (Illustrated) | BetterExplained.

Because of the demise of traditional version control systems: SVN projects on SourceForge, CodePlex and other sites are massively migrated to DVCS.

Hosting

Note that for by hosting on USA based or USA related providers, NSA can probably do whatever they please.

There are various lists of hosting sites, for instance:

I have experience with the sites I mention below. When time permits, I’m going to try some non-USA hosted providers as well.

Bitbucket.org

can host both GIT and HG for you. (it is from Atlassian; both public and private projects; free for private projects up to 5 users).

Notes:

Tip for a first commit: make sure you have a good README file in your rout (you can use various extensions), as it will get a prominent place at your bitbucket repository page.

GitHub.com

can host GIT for you. It can also hosts GISTs (small code snippets). Note it is USA based too.

tfs.VisualStudio.com

can host both TFVC and GIT for you (it is from Microsoft; payed if you have over 5 developers). Note it is USA based as well.

www.CodePlex.com

can host TFVC, GIT and Mercurial for you (also from Microsoft, but free, though supports only public projects) . Note it is USA based.

Bridging / conversion

SVN2TFS

can put migrate from SVN to TFVC in TFS. I have not used this myself, but did use:

SVNBridge

an SVN front-end to TFVC. CodePlex uses this a lot, and I used it client-side to pull a TFS 2005 repository to a user that could only do SVN. I could never get this to work on TFS 2005 server side, then never bothered as I switched to GIT/Mercurial soon after.

SVN to Mercurial: HGSVN and HGSubversion

There are three  tools that can help you integrate SVN and Mercurial:

GIT and Visual Studio / TFS

Getting Started with Git in Visual Studio and Team Foundation Service – Visual Studio ALM + Team Foundation Server Blog – Site Home – MSDN Blogs. GIT TF: Announcing Git Integration with TFS – Brian Harry’s blog – Site Home – MSDN Blogs. GIT TFS: similar to GIT-TF, but works cross platform. git-tfsHow do I use git-tfs and idiomatic git branching against a TFS repository? – Stack Overflow.

GIT / Mercurial

GIT and Mercurial are so so similar that there is both a Hg-Git Mercurial Plugin (free command-line tool) and Kiln Harmony (payed hosting service, but free for teams up to 2 developers).

D Workflow

Normally you work on a local for of a more global repository. Locally you branch/tag on work (then merge back into a more mainstream branch) and finally push your work (or create a pull request) to integrated it in other repositories. But if you are going to do major work that you are not sure you are willing to push back, then you are going to fork locally as well: Forking a Repository – Bitbucket – Atlassian Documentation.

Note that pull requests between BitBucket/GitHub/GoogleCode are not possible (hopefully yet). Actually it takes a bit of effort to push to multiple servers so I’ll ever that to another blog post.

Currently, the best practice is to use either of these two workflow models:

Both are a set of  scripts (Python for HG Flow, Shell for Git flow) assisting in managing your workflow.

The concept behind HG Flow is based on Git Flow, which has been made after the article A successful Git branching model » nvie.com (see also the list below).

For an example, examine the commit flow of the HG Flow project itself.

There are various pages with nice graphs and diagrams on what kind of workflows you can use, for instance:

Fork, Pull request: the Integrators workflow

The best is to do all your work in feature branches, as that makes working with pull requests a lot easier.

Even in a shared repository model, forks and pull requests have benefit as they allow for discussion / mentoring / code review.

Various VCS/DVCS links

Maintain the integrity of your .hg, .git and .svn directories

One of the drawbacks of files-based repository databases is that if they get damaged, you are hosed as downloading a fresh repository can take a long time. HG, GIT and SVN store their database in local directories named .hg, .git and .svn. You should be extra careful with them. So first and for all: make backups! Then: make sure you disable virus scanners for your .hg, .git and .svn directories.

SourceTree GUI on a Mac

SourceTree GUI on a Mac

GUI Installation / Commandline versions

For GUI tools, I’ve switched from TortoiseGit and TortoiseHG to SourceTree: see image on the right. It is the most powerful standalone VCS GUI I know about, and is available both on Windows (written in .NET using WPF controls; supporting HG and Git) and Mac OS X (supporting HG and Git, and importing from SVN). Actually, the Mac version was there first; the Windows version got released in March 2013 (:

For both SourceTree for Windows and Mac OS X, you can choose to use System (pre-existing) command-line versions of HG and Git, or embedded versions of HG and Git. Their clear aim here is that you should seldom be bothered with using the command-line tools, and that indeed works for most of the time.

Another very strong feature is that SourceTree supports both HG Flow and Git Flow out of the box: no need to use the flow command-line tools here. There is a good Git Flow guide here: Smart branching with SourceTree and Git-flow | SourceTree Blog.

Finally, SourceTree has some extra built-in support for the repository hosters Bitbucket and GitHub making it easier to interact with those.

All Tortoise* downloads, except TortoiseGit (go figure!) can install command-line versions of the tools. TortoiseGIT requires the commandline tools for msysgit to function at all.

Tortoise HG Werkbench

Tortoise HG Werkbench

In my experience (before discovering SourceTree), I needed to go to the command-line a lot, especially for TortoiseGit and TortoiseSVN. TortoiseHG has a way better GUI: they include HG Workbench – see image on the right – , which none of the other Tortoise implementations have leaving a clear gap for SourceTree (next to the virtually non-existence of good other GUI based VCS tools on Mac OS X).

If you want to do command-line only, here are some sources:

Encoding

The best is to use ASCII filenames and comments. Be very careful when using non-ASCII filenames, especially across operating systems. The main reason is that the Windows Console does not use the UTF-8 codepage. Some links (mainly about HG, but all version control systems have issues here):

Be careful with file content. For instance, TortoiseHG does not like UTF-16 files with BOM: it thinks they are binary: Converted `GroupProj.xsd` from UTF-16 to UTF-8 as TortoiseHg does not like UTF-16 files (it thinks they are binary).

Atomicity

Since the local operations are on your file system, they are not atomic. Which means that when a command is interrupted, your local state can be corrupted. This can hold for any version control (SVN, GIT, HG, TFS, etc). This leads to answers and comments like with these questions:

Status info

One of the really powerful features of SVN is that you can get status info in XML format for easier parsing. Without it, you get questions like these:

For GIT and HG you need this a lot less, but when you need it, they don’t have it.

Relative URLs

SVN 1.5 added a great feature (improved with 1.6) called relative URLs (they start with ^, .., / or //) which made a lot of commands easier. Since HG and GIT contain the complete repository history, virtually any path can be relative.

Ignore lists

Ignore lists are path patterns to ignore in your version control system. There is a whole bunch of pattern examples for various languages at Github. Setting up Ignore lists under GIT and Mercurial is easy: add a .gitignore or .hgignore file in the root of your repository. They are version controlled, so apply to all clients. HG ignore allows to kinds of patterns: glob and regex. For SVN it is a lot harder, so here are some links that can serve as a good starting point:

For all version control systems: Don’t use a client-side global ignore list; they only apply at that particular client. Even if you have ignore lists, thinks can seem to be strange. A few examples:

Renaming / Moving files

This is a bit tricky as the standard rename/move in Windows explorer does not notify the version control system about the operation. So you have to perform the rename or move in your version control tool or on the commandline.

Cheat sheets

Version control Icon overlays in the Windows Explorer

Version control Icon overlays in the Windows Explorer

Explorer overlay icons

Version control Icon overlays in the Windows Explorer can have a big system impact. TortoiseHG does handle this in a very smart way, that’s why TortoiseHG does not have Icon Overlay include, exclude paths. TortoiseSVN and TortoiseGIT however do, as they share large parts of the code (hence the dialogs look very similar), and this is how you configure them:

  • Both:
    • Disable default showing on all kinds of media.
    • Exclude all paths.
    • Include only the paths you perform version control in.
  • TortoiseGIT: Make sure that you have a * at the end of the include paths:

    20130820-TortoiseGit-overlay-icons-setti ngs (click to enlarge)

    20130820-TortoiseGit-overlay-icons-setti ngs (click to enlarge)

  • TortoiseSVN: No need to include a * at the end of the include paths:

    20130820-TortoiseSVN-overlay-icons-setti ngs (click to enlarge)

    20130820-TortoiseSVN-overlay-icons-setti ngs (click to enlarge)

For all three, there can be various reasons for overlay icons not to show up, varying from wrong configuration to crossing the Windows limit of 15 overlay icons (which is the reason that all three use the same overlay icon set).

External Comparison Tools example: Beyond Compare integration

I love Beyond Compare very much as a diff/merge tool as it supports to many file and archive formats.

Their support list lists a large number of other tools they integrate with, including many version control systems.

Integration screenshots (click on each to get a larger version):

TortoiseHG

  • A dropbox selection

    Select

    Select “beyondcompare3” from the dropdowns in both “Three-way Merge Tool” and “Visual Diff Tool”

TortoiseGit

  • Compare: Fill in the path plus parameters:
    “C:\Program Files (x86)\Beyond Compare 3\BComp.exe”  %base %mine /title1=%bname /title2=%yname /leftreadonly

    Select

    Switch the radiobutton to “External” then fill in the path and parameters.

  • Diff: Fill in the path plus parameters:
    “C:\Program Files (x86)\Beyond Compare 3\BComp.exe” %mine %theirs %base %merged /title1=%yname /title2=%tname /title3=%bname /title4=%mname

    Switch the radiobutton to

    Switch the radiobutton to “External” then fill in the path and parameters.

TortoiseSVN

  • Compare: Fill in the path plus parameters:
    “C:\Program Files (x86)\Beyond Compare 3\BComp.exe”  %base %mine /title1=%bname /title2=%yname /leftreadonly

    Switch the radiobutton to

    Switch the radiobutton to “External” then fill in the path and parameters.

  • Diff: Fill in the path plus parameters:
    “C:\Program Files (x86)\Beyond Compare 3\BComp.exe” %mine %theirs %base %merged /title1=%yname /title2=%tname /title3=%bname /title4=%mname

    Switch the radiobutton to

    Switch the radiobutton to “External” then fill in the path and parameters.

Line ending conversion

Be careful that you do not accidentally change CRLF line endings into LF ones: Delphi still does not like those. See You Clumsy GIT – DelphiFeeds.com.

Multiple upstreams

Both Mercurial/HG and GIT support multiple upstreams.

I need to put some more research in this though.

Making the move from SVN to HG (or GIT)

Mercurial/HG

  1. HgInit: Subversion Re-education.
  2. HgInit: Ground Up Mercurial.
  3. HgInit: Setting up for a Team.
  4. HgInit: Fixing Goofs.
  5. HgInit: Merging.
  6. HgInit: Repository Architecture.
  7. Mercurial: The Definitive Guide. (hosted at Red Bean, see below)
  8. Mercurial repository identification – Stack Overflow.
  9. Do not fork an empty repository: as soon as you commit changes to both, they loose their connection because an empty repository has a nullid first changeset to which the fork is bound, but the nullid gets overwritten at the first commit.

GIT

  1. Learning GIT | gitmap.
  2. Git Workflows, Branching & Merging Q&A – blogs.collab.netblogs.collab.net.
  3. Introduction to Git Concepts | Intertech Blog.

Red Bean: Books and more about VCS and OSS

Next to Mercurial: The Definitive Guide, there is quite bit of other stuff around version control and open source software at Red Bean, for instance these three books are great:

DVCS differences

Syncing a fork on BitBucket HG or GitHub GIT

You use forks when you do not have write access to a public repository. Pull requests than allows you to offer your changes back to the original repository. But what if the original repository changes? You want to sync your fork, right? On BitBucket with HG, this is easy: they offer a sync button. On GitHub with GIT it is a bit more work: you have to sync through your local clone through what is usually called the `upstream` (the original repository), then push the changes back to your fork. GitHub explains this using the command-line tools at Syncing a fork · GitHub Help, and manojlds for TortoiseGit at github – Can I update a forked project, on git, to the original/master copy? – Stack Overflow.

TFS and Mercurial, SVN, and GIT

Real-World use of Mercurial with a Team Foundation Server? – Stack Overflow. This explains how to use HG, and how to push/pull from the TFVC. The comments and answers also talk about SVN, and other version control systems.

TFS migration itself

–jeroen

Posted in .NET, CodePlex, Delphi, Development, DVCS - Distributed Version Control, Encoding, git, Mercurial/Hg, Software Development, Source Code Management, Subversion/SVN, TFS (Team Foundation System), Unicode, Visual Studio 11, Visual Studio 2005, Visual Studio 2008, Visual Studio 2010, Visual Studio and tools | 3 Comments »

Just filed Mercurial Bug 4043 – HG 2.7.x cannot convert a local file based SVN repository with db format 6 (works fine with db format 4)

Posted by jpluimers on 2013/09/26

Converting SVN repositories to HG isn’t always as straight forward as you want to.

GExperts and GExperts-Formatter succeeded a while ago, but DSharp (a very nice library by Stefan Glienke) failed at first.

It so happens that in the mean time, I switched VM’s to Delphi XE5 with a fresh list of VCS installs:

That was the cause: this new setup caused a new SVN db format for local synced file based SVN repositories that HG cannot not cope with.

It worked fine when I went back to a VM that had this config:

So I won’t forget to keep an eye on progress, I filed this Bug 4043 – HG 2.7.x cannot convert a local file based SVN repository with db format 6 (works fine with db format 4):

HG 2.6.x and 2.7.x cannot convert SVN repositories with db format 6 that SVN 1.8.x defaults to.

(SVN db format list: see http://svn.apache.org/repos/asf/subversion/trunk/subversion/libsvn_fs_fs/structure)

This works fine when performing svnadmin/svnsync on SVN 1.7.5 (they will get a db format 4), but fails when performing svnadmin/svnsync on SVN 1.8.x (they will get a db format 6)

I’ve tried the matrix of SVN versions 1.7.5, 1.8.1 and 1.8.2 versus HG 2.6.2, 2.7 and 2.7. HG consistently fails with db format 6.

The error message you get is this:

file:///C:/Users/developer/Versioned/DSharp.svn does not look like a Subversion repository

from the command here:

C:\Users\developer\Versioned>hg convert --verbose file:///C:/Users/developer/Versioned/DSharp.svn DSharp
file:///C:/Users/developer/Versioned/DSharp.svn does not look like a CVS checkout
file:///C:/Users/developer/Versioned/DSharp.svn does not look like a Git repository
file:///C:/Users/developer/Versioned/DSharp.svn does not look like a Subversion repository
file:///C:/Users/developer/Versioned/DSharp.svn is not a local Mercurial repository
file:///C:/Users/developer/Versioned/DSharp.svn does not look like a darcs repository
file:///C:/Users/developer/Versioned/DSharp.svn does not look like a monotone repository
file:///C:/Users/developer/Versioned/DSharp.svn does not look like a GNU Arch repository
file:///C:/Users/developer/Versioned/DSharp.svn does not look like a Bazaar repository
file:///C:/Users/developer/Versioned/DSharp.svn does not look like a P4 repository
abort: file:///C:/Users/developer/Versioned/DSharp.svn: missing or unsupported repository

Two of my tries that shows success/failure and got me in the right direction:

Success:


C:\Users\Developer\Versioned>svnadmin create DSharp.svn
C:\Users\Developer\Versioned>echo exit 0 1>DSharp.svn\hooks\pre-revprop-change.bat
C:\Users\Developer\Versioned>svnsync init file:///C:/Users/Developer/Versioned/DSharp.svn http://delphisorcery.googlecode.com/svn
Copied properties for revision 0.
C:\Users\Developer\Versioned>svnsync sync file:///C:/Users/Developer/Versioned/DSharp.svn http://delphisorcery.googlecode.com/svn
Committed revision 1.
Copied properties for revision 1.
Transmitting file data ……….
Committed revision 630.
Copied properties for revision 630.
C:\Users\Developer\Versioned>hg clone https://bitbucket.org/jeroenp/dsharp DSharp.hg
no changes found
updating to branch default
0 files updated, 0 files merged, 0 files removed, 0 files unresolved
C:\Users\Developer\Versioned>hg convert file:///C:/Users/Developer/Versioned/DSharp.svn DSharp.hg
scanning source…
sorting…
converting…
628 Initial directory structure.
627 First version
1 – refactoring for yield support (renamed DSharp.Collections.Yield.pas to DSharp.Collections.Iterators.pas)
0 – added XE4 packages
C:\Users\Developer\Versioned>svn –version
svn, version 1.7.5 (r1336830)
compiled May 11 2012, 02:21:17
Copyright (C) 2012 The Apache Software Foundation.
This software consists of contributions made by many people; see the NOTICE
file for more information.
Subversion is open source software, see http://subversion.apache.org/
The following repository access (RA) modules are available:
* ra_neon : Module for accessing a repository via WebDAV protocol using Neon.
– handles 'http' scheme
– handles 'https' scheme
* ra_svn : Module for accessing a repository using the svn network protocol.
– with Cyrus SASL authentication
– handles 'svn' scheme
* ra_local : Module for accessing a repository on local disk.
– handles 'file' scheme
* ra_serf : Module for accessing a repository via WebDAV protocol using serf.
– handles 'http' scheme
– handles 'https' scheme
C:\Users\Developer\Versioned>hg –version
Mercurial Distributed SCM (version 2.6.2)
(see http://mercurial.selenic.com for more information)
Copyright (C) 2005-2012 Matt Mackall and others
This is free software; see the source for copying conditions. There is NO
warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.
C:\Users\Developer\Versioned>type DSharp.svn\format
5
C:\Users\Developer\Versioned>type DSharp.svn\db\format
4
layout sharded 1000
C:\Users\Developer\Versioned>type DSharp.svn\db\fs-type
fsfs
C:\Users\Developer\Versioned>type DSharp.svn\db\min-unpacked-rev
0
C:\Users\Developer\Versioned>dir DSharp.svn DSharp.svn\db
Volume in drive C has no label.
Volume Serial Number is 4665-BAA1
Directory of C:\Users\Developer\Versioned\DSharp.svn
09/26/2013 08:47 AM <DIR> .
09/26/2013 08:47 AM <DIR> ..
09/26/2013 08:47 AM <DIR> conf
09/26/2013 08:55 AM <DIR> db
09/26/2013 08:47 AM 2 format
09/26/2013 08:47 AM <DIR> hooks
09/26/2013 08:47 AM <DIR> locks
09/26/2013 08:47 AM 234 README.txt
2 File(s) 236 bytes
Directory of C:\Users\Developer\Versioned\DSharp.svn\db
09/26/2013 08:55 AM <DIR> .
09/26/2013 08:55 AM <DIR> ..
09/26/2013 08:55 AM 4 current
09/26/2013 08:47 AM 22 format
09/26/2013 08:47 AM 5 fs-type
09/26/2013 08:47 AM 1,997 fsfs.conf
09/26/2013 08:47 AM 2 min-unpacked-rev
09/26/2013 08:55 AM 235,520 rep-cache.db
09/26/2013 08:47 AM <DIR> revprops
09/26/2013 08:47 AM <DIR> revs
09/26/2013 08:55 AM <DIR> transactions
09/26/2013 08:55 AM 3 txn-current
09/26/2013 08:47 AM 0 txn-current-lock
09/26/2013 08:55 AM <DIR> txn-protorevs
09/26/2013 08:47 AM 37 uuid
09/26/2013 08:47 AM 0 write-lock
10 File(s) 237,590 bytes
6 Dir(s) 2,377,388,032 bytes free
C:\Users\Developer\Versioned>

Failure:


C:\Users\developer\Versioned>svnadmin create DSharp.svn
C:\Users\developer\Versioned>echo exit 0 1>DSharp.svn\hooks\pre-revprop-change.bat
C:\Users\developer\Versioned>svnsync init file:///C:/Users/developer/Versioned/DSharp.svn http://delphisorcery.googlecode.com/svn
Copied properties for revision 0.
C:\Users\developer\Versioned>svnsync sync file:///C:/Users/developer/Versioned/DSharp.svn http://delphisorcery.googlecode.com/svn
Committed revision 1.
Copied properties for revision 1.
Transmitting file data ……….
Committed revision 630.
Copied properties for revision 630.
C:\Users\developer\Versioned>hg clone https://bitbucket.org/jeroenp/dsharp DSharp.hg
no changes found
updating to branch default
0 files updated, 0 files merged, 0 files removed, 0 files unresolved
C:\Users\developer\Versioned>hg convert –verbose file:///C:/Users/developer/Versioned/DSharp.svn DSharp
file:///C:/Users/developer/Versioned/DSharp.svn does not look like a CVS checkout
file:///C:/Users/developer/Versioned/DSharp.svn does not look like a Git repository
file:///C:/Users/developer/Versioned/DSharp.svn does not look like a Subversion repository
file:///C:/Users/developer/Versioned/DSharp.svn is not a local Mercurial repository
file:///C:/Users/developer/Versioned/DSharp.svn does not look like a darcs repository
file:///C:/Users/developer/Versioned/DSharp.svn does not look like a monotone repository
file:///C:/Users/developer/Versioned/DSharp.svn does not look like a GNU Arch repository
file:///C:/Users/developer/Versioned/DSharp.svn does not look like a Bazaar repository
file:///C:/Users/developer/Versioned/DSharp.svn does not look like a P4 repository
abort: file:///C:/Users/developer/Versioned/DSharp.svn: missing or unsupported repository
C:\Users\developer\Versioned>svn –version
svn, version 1.8.1 (r1503906)
compiled Jul 22 2013, 19:58:17 on x86-microsoft-windows
Copyright (C) 2013 The Apache Software Foundation.
This software consists of contributions made by many people;
see the NOTICE file for more information.
Subversion is open source software, see http://subversion.apache.org/
The following repository access (RA) modules are available:
* ra_svn : Module for accessing a repository using the svn network protocol.
– with Cyrus SASL authentication
– handles 'svn' scheme
* ra_local : Module for accessing a repository on local disk.
– handles 'file' scheme
* ra_serf : Module for accessing a repository via WebDAV protocol using serf.
– handles 'http' scheme
– handles 'https' scheme
C:\Users\developer\Versioned>hg –version
Mercurial Distributed SCM (version 2.7)
(see http://mercurial.selenic.com for more information)
Copyright (C) 2005-2013 Matt Mackall and others
This is free software; see the source for copying conditions. There is NO
warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.
C:\Users\developer\Versioned>type DSharp.svn\format
5
C:\Users\developer\Versioned>type DSharp.svn\db\format
6
layout sharded 1000
C:\Users\developer\Versioned>type DSharp.svn\db\fs-type
fsfs
C:\Users\developer\Versioned>type DSharp.svn\db\min-unpacked-rev
0
C:\Users\developer\Versioned>dir DSharp.svn DSharp.svn\db
Volume in drive C has no label.
Volume Serial Number is A855-3C2D
Directory of C:\Users\developer\Versioned\DSharp.svn
09/25/2013 09:52 PM <DIR> .
09/25/2013 09:52 PM <DIR> ..
09/25/2013 07:38 PM <DIR> conf
09/25/2013 07:44 PM <DIR> db
09/25/2013 07:38 PM 2 format
09/25/2013 07:38 PM <DIR> hooks
09/25/2013 07:38 PM <DIR> locks
09/25/2013 07:38 PM 251 README.txt
2 File(s) 253 bytes
Directory of C:\Users\developer\Versioned\DSharp.svn\db
09/25/2013 07:44 PM <DIR> .
09/25/2013 07:44 PM <DIR> ..
09/25/2013 07:44 PM 4 current
09/25/2013 07:38 PM 22 format
09/25/2013 07:38 PM 5 fs-type
09/25/2013 07:38 PM 6,963 fsfs.conf
09/25/2013 07:38 PM 2 min-unpacked-rev
09/25/2013 07:44 PM 232,448 rep-cache.db
09/25/2013 07:38 PM <DIR> revprops
09/25/2013 07:38 PM <DIR> revs
09/25/2013 07:44 PM <DIR> transactions
09/25/2013 07:44 PM 3 txn-current
09/25/2013 07:38 PM 0 txn-current-lock
09/25/2013 07:44 PM <DIR> txn-protorevs
09/25/2013 07:38 PM 37 uuid
09/25/2013 07:38 PM 0 write-lock
10 File(s) 239,484 bytes

.

–jeroen

via: Bug 4043 – HG 2.7.x cannot convert a local file based SVN repository with db format 6 (works fine with db format 4).

Posted in Delphi, Development, DVCS - Distributed Version Control, Mercurial/Hg, Software Development, Source Code Management, Subversion/SVN | Tagged: , , | 1 Comment »

.NET/C#: Igor Ostrovsky wrote a few great MSDN magazine articles helping you write better threading code

Posted by jpluimers on 2013/09/17

Igor Ostrovsky wrote a few very nice MSDN magazine articles. Not all of them have ended up in the list at MSDN magazine, so here is a more complete list:

Though the articles show the majority of sample code in C#, the actual topics are of great interest to any developer writing .NET code or interfacing to it.

Some keywords in his articles: Read the rest of this entry »

Posted in .NET, .NET 1.x, .NET 2.0, .NET 3.0, .NET 3.5, .NET 4.0, .NET 4.5, .NET CF, C, C#, C# 1.0, C# 2.0, C# 3.0, C# 4.0, C# 5.0, C++, Delphi, Development, F#, LINQ, PLINQ, Prism, Software Development, VB.NET, VB.NET 10.0, VB.NET 11.0, VB.NET 7.0, VB.NET 7.1, VB.NET 8.0, VB.NET 9.0 | Leave a Comment »

Delphi Mobile (NEXTGEN) compiler: the risk of a changed TSymbolName; unsupported data types means unsupported RTTI as well

Posted by jpluimers on 2013/09/05

The NEXTGEN family of Delphi compilers for the Mobile platforms changed quite a bit of things.

Most of it has been covered by various blogs posts. A non exhaustive list of ones I liked:

Those articles do not contain two things I had’t found about yet though that are important when you do RTTI using NEXTGEN in Delphi XE4: Read the rest of this entry »

Posted in Delphi, Delphi XE3, Delphi XE4, Development, Encoding, Software Development, Unicode, UTF-8 | 2 Comments »

Prepping for Delphi XE5 beta blogging; PasCon / RAD Studio In Action discount

Posted by jpluimers on 2013/09/04

You will see a few Delphi XE5 pre-release related updates here soon. That is part of the Delphi XE5 beta blogging permission I have been given so I can show new Delphi XE5 features. Those updates are from a pre-release version of Delphi XE5 and will be replaced with a final update when Delphi XE5 is being released.

For more information about Delphi XE5 and the Android support, please visit http://embt.co/RADAndroid.

Though not as fast as I hoped (I’ve slept most of the past days), I’m already preparing my Mercurial repositories at https://bitbucket.org/jeroenp, and preparing for the PasCon / RAD Studio In Action in Leiden, The Netherlands next saturday so stay tuned.

About this event: there are a few seats left, and a last-minute discount recently launched. Book your tickets through the on-line links for EUR 35 excluding VAT (normallu EUR 49 excluding VAT): Read the rest of this entry »

Posted in Delphi, Delphi XE5, Development, Software Development | Tagged: , , | Leave a Comment »

XSD/XML Schemas: resolving `Namespace ” is not available to be referenced in this schema` (via: StackOverflow)

Posted by jpluimers on 2013/09/01

While working on my Delphi: First try on an XSD for .groupproj files, I bumped into an error `Namespace ” is not available to be referenced in this schema`.

I added a targetNamespace attribute to the GroupProj.xsd so the .grouproj files would use the right namespace.

That resulted into two funny errors:

  1. Namespace ” is not available to be referenced in this schema.
    Visual Studio (which I normally use for editing XSD) would only throw this error on these elements:
    <xsd:element ...>
    So it would not throw them on nodes using the empty namespace.
    That was really confusing!
  2. When validating .grouproj files using this GroupProj.xsd, I would get this error for all .groupproj files:
    System.Xml.Schema.XmlSchemaValidationException: Type ‘<type>’ is not declared. (in this case for ‘<type>’  ‘ProjectType’).
    That was odd too: the ‘ProjectType’ was indeed declared, and should be valid.

I could hardly find any information about the latter error, but the former gave a few useful hits.

Thanks User weston – Stack Overflow. for answering this: it made me smack to my head (like usual, a case of EBCAK). Read the rest of this entry »

Posted in Delphi, Delphi 2007, Delphi 2009, Delphi 2010, Delphi XE, Delphi XE2, Delphi XE3, Delphi XE4, Delphi XE5, Development, Software Development, XML/XSD, XSD | Tagged: , , | 2 Comments »

Delphi: First try on an XSD for .groupproj files

Posted by jpluimers on 2013/08/31

Delphi introduced the .groupproj files to support MSBUILD.

I couldn’t find an XSD for it, but need to do some fiddling with those files, so I created one. It’s not very detailed, I think it gets most of the definition right.

The checkin is on my BeSharp.net mercurial repository on BitBucket:

First try on an XSD for .groupproj files.

–jeroen

via: jeroenp / BeSharp.net / commit / c122bbdef42e — Bitbucket.

Posted in Delphi, Delphi 2007, Delphi 2009, Delphi 2010, Delphi XE, Delphi XE2, Delphi XE3, Delphi XE4, Delphi XE5, Development, Software Development | Leave a Comment »

More Delphi PDF manuals (via: Cape Cod Gunny Does Delphi: The One Manual Every Delphi Programmer Should Have!)

Posted by jpluimers on 2013/08/29

Cape Cod Gunny found the PDF of the Delphi 7 Developer’s Guide (1100+ pages of good reading): Cape Cod Gunny Does Delphi: The One Manual Every Delphi Programmer Should Have!.

There are in fact quite a few more PDF manuals of older Borland/CodeGear/Embarcadero products:

site:http://docs.embarcadero.com/products/rad_studio filetype:pdf

These I like most: Read the rest of this entry »

Posted in Delphi, Development, Software Development | Leave a Comment »

Delphi: about 3 weeks ago, the XE5 branch was added to the RadStudioDemos repository:

Posted by jpluimers on 2013/08/29

Too bad the Sourceforge does not do stats pages any more, so you it is a lot harder to correlate project activity with potential release dates any more.

But: about 3 weeks ago, the XE5 branch was added to the RadStudioDemos repository:

http://sourceforge.net/p/radstudiodemos/code/788/tree/branches/RadStudio_XE5/

–jeroen

via: Correlation of Delphi Release/Update dates and activity on SourceForge project “RAD Studio Demo Code” « The Wiert Corner – irregular stream of stuff.

Posted in Delphi, Delphi XE5, Development, Software Development | 2 Comments »