<commit_before>// Copyright (c) .NET Foundation and contributors. All rights reserved.
// Licensed under the MIT license. See LICENSE file in the project root for full license information.

using System.Linq;
using Microsoft.DotNet.Cli.CommandLine;
using LocalizableStrings = Microsoft.DotNet.Tools.Cache.LocalizableStrings;

namespace Microsoft.DotNet.Cli
{
    internal static class CacheCommandParser
    {
        public static Command Cache() =>
            Create.Command(
                "cache",
                LocalizableStrings.AppDescription,
                Accept.ZeroOrMoreArguments,
                CommonOptions.HelpOption(),
                Create.Option(
                    "-e|--entries",
                    LocalizableStrings.ProjectEntryDescription,
                    Accept.OneOrMoreArguments
                        .With(name: LocalizableStrings.ProjectEntries)
                        .ForwardAs(o => 
                        {
                            var materializedString = $"{o.Arguments.First()}";

                            if (o.Arguments.Count() == 1) return materializedString;

                            var additionalProjects = string.Join("%3B", o.Arguments.Skip(1));

                            return $"{materializedString} /p:AdditionalProjects={additionalProjects}";
                        }),
                CommonOptions.FrameworkOption(),
                Create.Option(
                    "--framework-version",
                    LocalizableStrings.FrameworkVersionOptionDescription,
                    Accept.ExactlyOneArgument
                        .With(name: LocalizableStrings.FrameworkVersionOption)
                        .ForwardAs(o => $"/p:FX_Version={o.Arguments.Single()}")),
                CommonOptions.RuntimeOption(),
                CommonOptions.ConfigurationOption(),
                Create.Option(
                    "-o|--output",
                    LocalizableStrings.OutputOptionDescription,<commit_msg>missing peren<commit_after>// Copyright (c) .NET Foundation and contributors. All rights reserved.
// Licensed under the MIT license. See LICENSE file in the project root for full license information.

using System.Linq;
using Microsoft.DotNet.Cli.CommandLine;
using LocalizableStrings = Microsoft.DotNet.Tools.Cache.LocalizableStrings;

namespace Microsoft.DotNet.Cli
{
    internal static class CacheCommandParser
    {
        public static Command Cache() =>
            Create.Command(
                "cache",
                LocalizableStrings.AppDescription,
                Accept.ZeroOrMoreArguments,
                CommonOptions.HelpOption(),
                Create.Option(
                    "-e|--entries",
                    LocalizableStrings.ProjectEntryDescription,
                    Accept.OneOrMoreArguments
                        .With(name: LocalizableStrings.ProjectEntries)
                        .ForwardAs(o => 
                        {
                            var materializedString = $"{o.Arguments.First()}";

                            if (o.Arguments.Count() == 1) return materializedString;

                            var additionalProjects = string.Join("%3B", o.Arguments.Skip(1));

                            return $"{materializedString} /p:AdditionalProjects={additionalProjects}";
                        })),
                CommonOptions.FrameworkOption(),
                Create.Option(
                    "--framework-version",
                    LocalizableStrings.FrameworkVersionOptionDescription,
                    Accept.ExactlyOneArgument
                        .With(name: LocalizableStrings.FrameworkVersionOption)
                        .ForwardAs(o => $"/p:FX_Version={o.Arguments.Single()}")),
                CommonOptions.RuntimeOption(),
                CommonOptions.ConfigurationOption(),
                Create.Option(
                    "-o|--output",
                    LocalizableStrings.OutputOptionDescription,
{'fraction_non_alphanumeric': 0.08740295517155021, 'fraction_numerical': 0.0015026296018031556, 'mean_word_length': 1.6070496083550914, 'pattern_counts': {'":': 0, '<': 3, '<?xml version=': 0, '>': 9, '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': '3222988', 'n_tokens_mistral': 892, 'n_tokens_neox': 827, 'n_words': 168}