<commit_before>// <copyright file="PostExecute.cs" company="<NAME>">
//  Opus package
// </copyright>
// <summary>QMakeBuilder package</summary>
// <author><NAME></author>
namespace QMakeBuilder
{
    public sealed partial class QMakeBuilder : Opus.Core.IBuilderPostExecute
    {
        #region IBuilderPostExecute Members

        void Opus.Core.IBuilderPostExecute.PostExecute(Opus.Core.DependencyNodeCollection executedNodes)
        {
            Opus.Core.Log.DebugMessage("PostExecute for QMakeBuilder");

            // find all nodes with the same unique name
            System.Collections.Generic.Dictionary<string, Opus.Core.Array<QMakeData>> similarNodes = new System.Collections.Generic.Dictionary<string, Opus.Core.Array<QMakeData>>();
            foreach (var node in executedNodes)
            {
                if (null == node.Data)
                {
                    Opus.Core.Log.DebugMessage("*** Null data for node {0}", node.UniqueModuleName);
                    continue;
                }

                if (similarNodes.ContainsKey(node.UniqueModuleName))
                {
                    similarNodes[node.UniqueModuleName].Add(node.Data as QMakeData);
                }
                else
                {
                    similarNodes[node.UniqueModuleName] = new Opus.Core.Array<QMakeData>(node.Data as QMakeData);
                }
            }

            foreach (var keyPair in similarNodes)
            {
                Opus.Core.Log.DebugMessage("{0} : {1} nodes", keyPair.Key, keyPair.Value.Count);
                QMakeData.Write(keyPair.Value);
            }

            var mainPackage = Opus.Core.State.PackageInfo[0];
            string proFileName = mainPackage + ".pro";
            string rootDirectory = mainPackage.BuildDirectory;
            string proFilePath = System.IO.Path.Combine(rootDirectory, proFileName);

            // relative paths need a trailing slash to work
            rootDirectory += System.IO.Path.DirectorySeparatorChar;

            using (var proWriter = new System.IO.StreamWriter(proFilePath))<commit_msg>[trunk] Put the QMake top level .pro file into the build root, so that subdirs do not contain special characters.<commit_after>// <copyright file="PostExecute.cs" company="<NAME>">
//  Opus package
// </copyright>
// <summary>QMakeBuilder package</summary>
// <author><NAME></author>
namespace QMakeBuilder
{
    public sealed partial class QMakeBuilder : Opus.Core.IBuilderPostExecute
    {
        #region IBuilderPostExecute Members

        void Opus.Core.IBuilderPostExecute.PostExecute(Opus.Core.DependencyNodeCollection executedNodes)
        {
            Opus.Core.Log.DebugMessage("PostExecute for QMakeBuilder");

            // find all nodes with the same unique name
            System.Collections.Generic.Dictionary<string, Opus.Core.Array<QMakeData>> similarNodes = new System.Collections.Generic.Dictionary<string, Opus.Core.Array<QMakeData>>();
            foreach (var node in executedNodes)
            {
                if (null == node.Data)
                {
                    Opus.Core.Log.DebugMessage("*** Null data for node {0}", node.UniqueModuleName);
                    continue;
                }

                if (similarNodes.ContainsKey(node.UniqueModuleName))
                {
                    similarNodes[node.UniqueModuleName].Add(node.Data as QMakeData);
                }
                else
                {
                    similarNodes[node.UniqueModuleName] = new Opus.Core.Array<QMakeData>(node.Data as QMakeData);
                }
            }

            foreach (var keyPair in similarNodes)
            {
                Opus.Core.Log.DebugMessage("{0} : {1} nodes", keyPair.Key, keyPair.Value.Count);
                QMakeData.Write(keyPair.Value);
            }

            var mainPackage = Opus.Core.State.PackageInfo[0];
            string proFileName = mainPackage + ".pro";
            string rootDirectory = Opus.Core.State.BuildRoot;
            string proFilePath = System.IO.Path.Combine(rootDirectory, proFileName);

            // relative paths need a trailing slash to work
            rootDirectory += System.IO.Path.DirectorySeparatorChar;

            using (var proWriter = new System.IO.StreamWriter(proFilePath))
{'fraction_non_alphanumeric': 0.09923309319079712, 'fraction_numerical': 0.0018591680223100163, 'mean_word_length': 2.026722925457103, 'pattern_counts': {'":': 0, '<': 29, '<?xml version=': 0, '>': 29, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '6606664', 'n_tokens_mistral': 1120, 'n_tokens_neox': 1076, 'n_words': 234}