This is an automated email from the ASF dual-hosted git repository.

paulirwin pushed a commit to branch issue/911
in repository https://gitbox.apache.org/repos/asf/lucenenet.git


The following commit(s) were added to refs/heads/issue/911 by this push:
     new a87d8d783 Use EnvVar:LuceneNetVersion in CLI docs, remove old files
a87d8d783 is described below

commit a87d8d783b656e2d3a297985a6cb0e86362114d8
Author: Paul Irwin <[email protected]>
AuthorDate: Tue Sep 17 15:07:39 2024 -0600

    Use EnvVar:LuceneNetVersion in CLI docs, remove old files
---
 .../LuceneDocsPlugins/AggregatePostProcessor.cs    |  1 -
 .../EnvironmentVariableDfmTextInlineRule.cs        | 49 -----------
 .../EnvironmentVariableInCodeBlockRule.cs          | 47 -----------
 .../EnvironmentVariableInLinkInlineRule.cs         | 96 ----------------------
 .../EnvironmentVariableInlineRule.cs               | 52 ------------
 .../EnvironmentVariableRendererPart.cs             | 40 ---------
 .../LuceneDocsPlugins/LuceneDfmEngineCustomizer.cs | 69 ----------------
 src/docs/LuceneDocsPlugins/LuceneNoteBlockRule.cs  | 46 -----------
 src/docs/LuceneDocsPlugins/LuceneNoteBlockToken.cs | 44 ----------
 .../LuceneNoteTokenRendererPart.cs                 | 52 ------------
 src/docs/LuceneDocsPlugins/RendererPartProvider.cs | 40 ---------
 src/dotnet/tools/lucene-cli/docs/index.md          |  2 +-
 websites/apidocs/docs.ps1                          |  4 -
 13 files changed, 1 insertion(+), 541 deletions(-)

diff --git a/src/docs/LuceneDocsPlugins/AggregatePostProcessor.cs 
b/src/docs/LuceneDocsPlugins/AggregatePostProcessor.cs
index c2bafd98a..675434b12 100644
--- a/src/docs/LuceneDocsPlugins/AggregatePostProcessor.cs
+++ b/src/docs/LuceneDocsPlugins/AggregatePostProcessor.cs
@@ -16,7 +16,6 @@
  */
 
 using Docfx.Plugins;
-using System;
 using System.Collections.Immutable;
 using System.Composition;
 
diff --git a/src/docs/LuceneDocsPlugins/EnvironmentVariableDfmTextInlineRule.cs 
b/src/docs/LuceneDocsPlugins/EnvironmentVariableDfmTextInlineRule.cs
deleted file mode 100644
index e68145c42..000000000
--- a/src/docs/LuceneDocsPlugins/EnvironmentVariableDfmTextInlineRule.cs
+++ /dev/null
@@ -1,49 +0,0 @@
-//using Microsoft.DocAsCode.Dfm;
-//using Microsoft.DocAsCode.MarkdownLite;
-//using System;
-//using System.Text;
-//using System.Text.RegularExpressions;
-
-//namespace LuceneDocsPlugins
-//{
-//    // LUCENENET TODO: This is not functional yet
-
-//    /*
-//     * Licensed to the Apache Software Foundation (ASF) under one or more
-//     * contributor license agreements.  See the NOTICE file distributed with
-//     * this work for additional information regarding copyright ownership.
-//     * The ASF licenses this file to You under the Apache License, Version 
2.0
-//     * (the "License"); you may not use this file except in compliance with
-//     * the License.  You may obtain a copy of the License at
-//     *
-//     *     http://www.apache.org/licenses/LICENSE-2.0
-//     *
-//     * Unless required by applicable law or agreed to in writing, software
-//     * distributed under the License is distributed on an "AS IS" BASIS,
-//     * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or 
implied.
-//     * See the License for the specific language governing permissions and
-//     * limitations under the License.
-//     */
-
-//    public class EnvironmentVariableDfmTextInlineRule : DfmTextInlineRule
-//    {
-//        public static readonly Regex EnvVar = 
EnvironmentVariableUtil.EnvVarRegexInline;
-
-//        public override IMarkdownToken TryMatch(IMarkdownParser parser, 
IMarkdownParsingContext context)
-//        {
-//            var match = Text.Match(context.CurrentMarkdown);
-//            if (match.Length == 0)
-//            {
-//                return null;
-//            }
-//            var sourceInfo = context.Consume(match.Length);
-
-//            //Console.WriteLine("Hey!!!!");
-
-//            var environmentVariableMatch = 
EnvVar.Match(match.Groups[0].Value);
-//            //Console.WriteLine(environmentVariableMatch.Success);
-//            string replacement = environmentVariableMatch.Success ? 
EnvironmentVariableUtil.ReplaceEnvironmentVariables(match.Groups[0].Value, 
match, new StringBuilder(match.Groups[0].Value.Length)) : match.Groups[0].Value;
-//            return new MarkdownTextToken(this, parser.Context, 
StringHelper.Escape(Smartypants(parser.Options, replacement)), sourceInfo);
-//        }
-//    }
-//}
diff --git a/src/docs/LuceneDocsPlugins/EnvironmentVariableInCodeBlockRule.cs 
b/src/docs/LuceneDocsPlugins/EnvironmentVariableInCodeBlockRule.cs
deleted file mode 100644
index 9d648928e..000000000
--- a/src/docs/LuceneDocsPlugins/EnvironmentVariableInCodeBlockRule.cs
+++ /dev/null
@@ -1,47 +0,0 @@
-//using Microsoft.DocAsCode.MarkdownLite;
-//using System.Text.RegularExpressions;
-
-//namespace LuceneDocsPlugins
-//{
-//    // LUCENENET TODO: This is not functional yet
-
-//    /*
-//     * Licensed to the Apache Software Foundation (ASF) under one or more
-//     * contributor license agreements.  See the NOTICE file distributed with
-//     * this work for additional information regarding copyright ownership.
-//     * The ASF licenses this file to You under the Apache License, Version 
2.0
-//     * (the "License"); you may not use this file except in compliance with
-//     * the License.  You may obtain a copy of the License at
-//     *
-//     *     http://www.apache.org/licenses/LICENSE-2.0
-//     *
-//     * Unless required by applicable law or agreed to in writing, software
-//     * distributed under the License is distributed on an "AS IS" BASIS,
-//     * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or 
implied.
-//     * See the License for the specific language governing permissions and
-//     * limitations under the License.
-//     */
-
-//    public class EnvironmentVariableInCodeBlockRule : MarkdownCodeBlockRule
-//    {
-//        public static readonly Regex EnvVarRegex = 
EnvironmentVariableUtil.EnvVarRegexInline;
-
-//        public override IMarkdownToken TryMatch(IMarkdownParser parser, 
IMarkdownParsingContext context)
-//        {
-//            //Console.WriteLine("Hello World!");
-
-//            var token = base.TryMatch(parser, context) as 
MarkdownCodeBlockToken;
-//            if (token is null) return null;
-
-//            //Console.WriteLine("Alert: Code.");
-//            //Console.WriteLine(token.Code);
-
-//            var environmentVariableMatch = EnvVarRegex.Match(token.Code);
-//            if (!environmentVariableMatch.Success) return token;
-
-//            var code = 
EnvironmentVariableUtil.ReplaceEnvironmentVariables(token.Code, 
environmentVariableMatch);
-
-//            return new MarkdownCodeBlockToken(token.Rule, token.Context, 
code, token.Lang, token.SourceInfo);
-//        }
-//    }
-//}
diff --git a/src/docs/LuceneDocsPlugins/EnvironmentVariableInLinkInlineRule.cs 
b/src/docs/LuceneDocsPlugins/EnvironmentVariableInLinkInlineRule.cs
deleted file mode 100644
index ed873bb78..000000000
--- a/src/docs/LuceneDocsPlugins/EnvironmentVariableInLinkInlineRule.cs
+++ /dev/null
@@ -1,96 +0,0 @@
-using System.Text;
-using System.Text.RegularExpressions;
-
-namespace LuceneDocsPlugins
-{
-    /*
-     * Licensed to the Apache Software Foundation (ASF) under one or more
-     * contributor license agreements.  See the NOTICE file distributed with
-     * this work for additional information regarding copyright ownership.
-     * The ASF licenses this file to You under the Apache License, Version 2.0
-     * (the "License"); you may not use this file except in compliance with
-     * the License.  You may obtain a copy of the License at
-     *
-     *     http://www.apache.org/licenses/LICENSE-2.0
-     *
-     * Unless required by applicable law or agreed to in writing, software
-     * distributed under the License is distributed on an "AS IS" BASIS,
-     * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-     * See the License for the specific language governing permissions and
-     * limitations under the License.
-     */
-
-    /// <summary>
-    /// Replaces an environment variables that are nested within the text, 
href, or title of a Markdown link.
-    /// </summary>
-    public class EnvironmentVariableInLinkInlineRule : MarkdownLinkInlineRule
-    {
-        public override string Name => "EnvVar.Link";
-
-        public static readonly Regex EnvVarRegex = 
EnvironmentVariableUtil.EnvVarRegexInline;
-
-        public override IMarkdownToken TryMatch(IMarkdownParser parser, 
IMarkdownParsingContext context)
-        {
-            // NOTE: This copies the logic from MarkdownLinkInlineRule, but 
does not match if there are no links to replace.
-            // This isn't perfect, but at least it ensures we only match the 
one [Changes]() link it is intended to match
-            // and replaces multiple environment variables if they exist.
-
-            // The when the Consume() method below is called, there doesn't 
appear to be any way to make the cursor backtrack,
-            // and the scan is only performed once. This is why we have to 
resort to this. Not sure if there is a better way to make
-            // nested tokens than this, but it doesn't seem like there is.
-
-            var match = Link.Match(context.CurrentMarkdown);
-            if (match.Length == 0)
-            {
-                return null;
-            }
-            if (MarkdownInlineContext.GetIsInLink(parser.Context) && 
match.Value[0] != '!')
-            {
-                return null;
-            }
-            if (IsEscape(match.Groups[1].Value) || 
IsEscape(match.Groups[2].Value))
-            {
-                return null;
-            }
-
-            var text = match.Groups[1].Value;
-            var title = match.Groups[4].Value;
-            var href = match.Groups[2].Value;
-
-            var textMatch = EnvVarRegex.Match(text);
-            var titleMatch = EnvVarRegex.Match(title);
-            var hrefMatch = EnvVarRegex.Match(href);
-
-            // Don't match unless we have a match for our EnvVar pattern in 
any part of the link
-            if (!textMatch.Success && !titleMatch.Success && 
!hrefMatch.Success)
-                return null;
-
-            StringBuilder scratch = null;
-
-            if (textMatch.Success || titleMatch.Success || hrefMatch.Success)
-                scratch = new StringBuilder();
-
-            if (textMatch.Success)
-                text = 
EnvironmentVariableUtil.ReplaceEnvironmentVariables(text, textMatch, scratch);
-            if (titleMatch.Success)
-                title = 
EnvironmentVariableUtil.ReplaceEnvironmentVariables(title, titleMatch, scratch);
-            if (hrefMatch.Success)
-                href = 
EnvironmentVariableUtil.ReplaceEnvironmentVariables(href, hrefMatch, scratch);
-
-            var sourceInfo = context.Consume(match.Length);
-            return GenerateToken(parser, href, title, text, match.Value[0] == 
'!', sourceInfo, MarkdownLinkType.NormalLink, null);
-        }
-
-        private bool IsEscape(string text)
-        {
-            for (int i = text.Length - 1; i >= 0; i--)
-            {
-                if (text[i] != '\\')
-                {
-                    return (text.Length - i) % 2 == 0;
-                }
-            }
-            return text.Length % 2 == 1;
-        }
-    }
-}
diff --git a/src/docs/LuceneDocsPlugins/EnvironmentVariableInlineRule.cs 
b/src/docs/LuceneDocsPlugins/EnvironmentVariableInlineRule.cs
deleted file mode 100644
index 5085b3df7..000000000
--- a/src/docs/LuceneDocsPlugins/EnvironmentVariableInlineRule.cs
+++ /dev/null
@@ -1,52 +0,0 @@
-using System;
-
-namespace LuceneDocsPlugins
-{
-    /*
-     * Licensed to the Apache Software Foundation (ASF) under one or more
-     * contributor license agreements.  See the NOTICE file distributed with
-     * this work for additional information regarding copyright ownership.
-     * The ASF licenses this file to You under the Apache License, Version 2.0
-     * (the "License"); you may not use this file except in compliance with
-     * the License.  You may obtain a copy of the License at
-     *
-     *     http://www.apache.org/licenses/LICENSE-2.0
-     *
-     * Unless required by applicable law or agreed to in writing, software
-     * distributed under the License is distributed on an "AS IS" BASIS,
-     * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-     * See the License for the specific language governing permissions and
-     * limitations under the License.
-     */
-
-    public class EnvironmentVariableInlineRule : IMarkdownRule
-    {
-        // give it a name
-        public string Name => "EnvVarToken";
-
-        // process the match
-        public IMarkdownToken TryMatch(IMarkdownParser parser, 
IMarkdownParsingContext context)
-        {
-            // TODO: This does not process this token from within a code block 
like
-
-            // ```
-            // dotnet tool install lucene-cli -g --version [EnvVar: 
LuceneNetVersion]
-            // ```
-
-            //Console.Write(context.CurrentMarkdown);
-            
//Console.WriteLine("------------------------------------------------------------------------------");
-
-            var match = 
EnvironmentVariableUtil.EnvVarRegex.Match(context.CurrentMarkdown);
-
-            if (!match.Success) return null;
-
-            var envVar = match.Groups[1].Value;
-            var text = Environment.GetEnvironmentVariable(envVar);
-            if (text == null) return null;
-
-            // 'eat' the characters of the current markdown token so they anr
-            var sourceInfo = context.Consume(match.Length);
-            return new MarkdownTextToken(this, parser.Context, text, 
sourceInfo);
-        }
-    }
-}
diff --git a/src/docs/LuceneDocsPlugins/EnvironmentVariableRendererPart.cs 
b/src/docs/LuceneDocsPlugins/EnvironmentVariableRendererPart.cs
deleted file mode 100644
index 9fa48b613..000000000
--- a/src/docs/LuceneDocsPlugins/EnvironmentVariableRendererPart.cs
+++ /dev/null
@@ -1,40 +0,0 @@
-//using Microsoft.DocAsCode.Dfm;
-//using Microsoft.DocAsCode.MarkdownLite;
-
-//namespace LuceneDocsPlugins
-//{
-//    /*
-//     * Licensed to the Apache Software Foundation (ASF) under one or more
-//     * contributor license agreements.  See the NOTICE file distributed with
-//     * this work for additional information regarding copyright ownership.
-//     * The ASF licenses this file to You under the Apache License, Version 
2.0
-//     * (the "License"); you may not use this file except in compliance with
-//     * the License.  You may obtain a copy of the License at
-//     *
-//     *     http://www.apache.org/licenses/LICENSE-2.0
-//     *
-//     * Unless required by applicable law or agreed to in writing, software
-//     * distributed under the License is distributed on an "AS IS" BASIS,
-//     * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or 
implied.
-//     * See the License for the specific language governing permissions and
-//     * limitations under the License.
-//     */
-
-//    // TODO: this is actually not needed since we are inserting our own 
inline rule, although the docs
-//    // claim we need it 
https://dotnet.github.io/docfx/tutorial/howto_customize_docfx_flavored_markdown.html
-//    // maybe that is only the case for block level items? I cannot quite 
figure it out looking at the docfx code
-
-//    /// <summary>
-//    /// Used to replace environment variables tokens with their values
-//    /// </summary>
-//    public sealed class EnvironmentVariableRendererPart : 
DfmCustomizedRendererPartBase<IMarkdownRenderer, MarkdownTextToken, 
MarkdownInlineContext>
-//    {
-//        public override string Name => "EnvironmentVariableRendererPart";
-
-//        public override bool Match(IMarkdownRenderer renderer, 
MarkdownTextToken token, MarkdownInlineContext context)
-//            => true;
-
-//        public override StringBuffer Render(IMarkdownRenderer renderer, 
MarkdownTextToken token, MarkdownInlineContext context)
-//            => token.Content;
-//    }
-//}
\ No newline at end of file
diff --git a/src/docs/LuceneDocsPlugins/LuceneDfmEngineCustomizer.cs 
b/src/docs/LuceneDocsPlugins/LuceneDfmEngineCustomizer.cs
deleted file mode 100644
index 5c0b8a617..000000000
--- a/src/docs/LuceneDocsPlugins/LuceneDfmEngineCustomizer.cs
+++ /dev/null
@@ -1,69 +0,0 @@
-//using System;
-//using System.Collections.Generic;
-//using System.Collections.Immutable;
-//using System.Composition;
-//using Microsoft.DocAsCode.Dfm;
-//using Microsoft.DocAsCode.MarkdownLite;
-
-//namespace LuceneDocsPlugins
-//{
-//    /*
-//     * Licensed to the Apache Software Foundation (ASF) under one or more
-//     * contributor license agreements.  See the NOTICE file distributed with
-//     * this work for additional information regarding copyright ownership.
-//     * The ASF licenses this file to You under the Apache License, Version 
2.0
-//     * (the "License"); you may not use this file except in compliance with
-//     * the License.  You may obtain a copy of the License at
-//     *
-//     *     http://www.apache.org/licenses/LICENSE-2.0
-//     *
-//     * Unless required by applicable law or agreed to in writing, software
-//     * distributed under the License is distributed on an "AS IS" BASIS,
-//     * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or 
implied.
-//     * See the License for the specific language governing permissions and
-//     * limitations under the License.
-//     */
-
-//    /// <summary>
-//    /// Exports our custom markdown parser via MEF to DocFx
-//    /// </summary>
-//    [Export(typeof(IDfmEngineCustomizer))]
-//    public class LuceneDfmEngineCustomizer : IDfmEngineCustomizer
-//    {
-//        public void Customize(DfmEngineBuilder builder, 
IReadOnlyDictionary<string, object> parameters)
-//        {
-//            // insert inline rule at the top
-//            builder.InlineRules = builder.InlineRules.Insert(0, new 
EnvironmentVariableInLinkInlineRule());
-//            builder.InlineRules = builder.InlineRules.Insert(0, new 
EnvironmentVariableInlineRule());
-//            // LUCENENET TODO: The inline text replacement still isn't 
working. Not sure why.
-//            //builder.InlineRules = builder.InlineRules.Insert(0, new 
EnvironmentVariableDfmTextInlineRule());
-
-//            //// Find the MarkdownLinkInlineRule position, and insert rules 
to replace text within the link before it
-//            //var markdownLinkInlineRuleIndex = 
builder.InlineRules.FindIndex(r => r is MarkdownLinkInlineRule);
-//            //builder.InlineRules.Insert(markdownLinkInlineRuleIndex, new 
EnvironmentVariableInLinkInlineRule());
-
-//            //builder.InlineRules = Replace<DfmTextInlineRule, 
EnvironmentVariableDfmTextInlineRule>(builder.InlineRules);
-
-//            // insert block rule above header rule. Why? I dunno, that's 
what the docs say: 
-//            // 
https://dotnet.github.io/docfx/tutorial/intro_markdown_lite.html#select-token-kind
-//            var blockIndex = builder.BlockRules.FindIndex(r => r is 
MarkdownHeadingBlockRule);
-//            builder.BlockRules = builder.BlockRules.Insert(blockIndex, new 
LuceneNoteBlockRule());
-
-//            // LUCENENET TODO: The code replacement still isn't working (or 
even matching). Not sure why.
-//            //builder.BlockRules = Replace<MarkdownCodeBlockRule, 
EnvironmentVariableInCodeBlockRule>(builder.BlockRules);
-//        }
-
-//        private static ImmutableList<IMarkdownRule> Replace<TSource, 
TReplacement>(ImmutableList<IMarkdownRule> blockRules)
-//            where TSource : IMarkdownRule
-//            where TReplacement : IMarkdownRule, new()
-//        {
-//            var index = blockRules.FindIndex(item => item is TSource);
-//            if (index < 0)
-//            {
-//                throw new ArgumentException($"{typeof(TSource).Name} should 
exist!");
-//            }
-//            blockRules = blockRules.Insert(index, new TReplacement());
-//            return blockRules.RemoveAt(index + 1);
-//        }
-//    }
-//}
diff --git a/src/docs/LuceneDocsPlugins/LuceneNoteBlockRule.cs 
b/src/docs/LuceneDocsPlugins/LuceneNoteBlockRule.cs
deleted file mode 100644
index 15cb039c2..000000000
--- a/src/docs/LuceneDocsPlugins/LuceneNoteBlockRule.cs
+++ /dev/null
@@ -1,46 +0,0 @@
-//using System.Text.RegularExpressions;
-//using Microsoft.DocAsCode.MarkdownLite;
-
-//namespace LuceneDocsPlugins
-//{
-//    /*
-//     * Licensed to the Apache Software Foundation (ASF) under one or more
-//     * contributor license agreements.  See the NOTICE file distributed with
-//     * this work for additional information regarding copyright ownership.
-//     * The ASF licenses this file to You under the Apache License, Version 
2.0
-//     * (the "License"); you may not use this file except in compliance with
-//     * the License.  You may obtain a copy of the License at
-//     *
-//     *     http://www.apache.org/licenses/LICENSE-2.0
-//     *
-//     * Unless required by applicable law or agreed to in writing, software
-//     * distributed under the License is distributed on an "AS IS" BASIS,
-//     * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or 
implied.
-//     * See the License for the specific language governing permissions and
-//     * limitations under the License.
-//     */
-
-//    /// <summary>
-//    /// The regex rule to parse out the custom Lucene tokens
-//    /// </summary>
-//    public class LuceneNoteBlockRule : IMarkdownRule
-//    {
-//        // TODO: I think there's an issue with this regex and multi-line or 
something, for example see: DrillDownQuery class
-//        // since this isn't matching it's experimental tag (there's lots of 
others too)
-//        public virtual Regex LabelRegex { get; } = new 
Regex("^@lucene\\.(?<notetype>(experimental|internal))", RegexOptions.Compiled);
-
-//        public virtual IMarkdownToken TryMatch(IMarkdownParser parser, 
IMarkdownParsingContext context)
-//        {
-
-//            var match = LabelRegex.Match(context.CurrentMarkdown);
-//            if (match.Length == 0)
-//            {
-//                return null;
-//            }
-//            var sourceInfo = context.Consume(match.Length);
-//            return new LuceneNoteBlockToken(this, parser.Context, 
match.Groups[1].Value, sourceInfo);
-//        }
-
-//        public virtual string Name => "LuceneNote";
-//    }
-//}
diff --git a/src/docs/LuceneDocsPlugins/LuceneNoteBlockToken.cs 
b/src/docs/LuceneDocsPlugins/LuceneNoteBlockToken.cs
deleted file mode 100644
index dffcfb6a6..000000000
--- a/src/docs/LuceneDocsPlugins/LuceneNoteBlockToken.cs
+++ /dev/null
@@ -1,44 +0,0 @@
-//using Microsoft.DocAsCode.MarkdownLite;
-
-//namespace LuceneDocsPlugins
-//{
-//    /*
-//     * Licensed to the Apache Software Foundation (ASF) under one or more
-//     * contributor license agreements.  See the NOTICE file distributed with
-//     * this work for additional information regarding copyright ownership.
-//     * The ASF licenses this file to You under the Apache License, Version 
2.0
-//     * (the "License"); you may not use this file except in compliance with
-//     * the License.  You may obtain a copy of the License at
-//     *
-//     *     http://www.apache.org/licenses/LICENSE-2.0
-//     *
-//     * Unless required by applicable law or agreed to in writing, software
-//     * distributed under the License is distributed on an "AS IS" BASIS,
-//     * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or 
implied.
-//     * See the License for the specific language governing permissions and
-//     * limitations under the License.
-//     */
-
-//    /// <summary>
-//    /// A custom token class representing our custom Lucene tokens
-//    /// </summary>
-//    public class LuceneNoteBlockToken : IMarkdownToken
-//    {
-//        public LuceneNoteBlockToken(IMarkdownRule rule, IMarkdownContext 
context, string label, SourceInfo sourceInfo)
-//        {
-//            Rule = rule;
-//            Context = context;
-//            Label = label;
-//            SourceInfo = sourceInfo;
-//        }
-
-//        public IMarkdownRule Rule { get; }
-
-//        public IMarkdownContext Context { get; }
-
-//        public string Label { get; }
-
-//        public SourceInfo SourceInfo { get; }
-//    }
-
-//}
diff --git a/src/docs/LuceneDocsPlugins/LuceneNoteTokenRendererPart.cs 
b/src/docs/LuceneDocsPlugins/LuceneNoteTokenRendererPart.cs
deleted file mode 100644
index 95fb04dca..000000000
--- a/src/docs/LuceneDocsPlugins/LuceneNoteTokenRendererPart.cs
+++ /dev/null
@@ -1,52 +0,0 @@
-//using Microsoft.DocAsCode.Dfm;
-//using Microsoft.DocAsCode.MarkdownLite;
-//using System.Text;
-
-//namespace LuceneDocsPlugins
-//{
-//    /*
-//     * Licensed to the Apache Software Foundation (ASF) under one or more
-//     * contributor license agreements.  See the NOTICE file distributed with
-//     * this work for additional information regarding copyright ownership.
-//     * The ASF licenses this file to You under the Apache License, Version 
2.0
-//     * (the "License"); you may not use this file except in compliance with
-//     * the License.  You may obtain a copy of the License at
-//     *
-//     *     http://www.apache.org/licenses/LICENSE-2.0
-//     *
-//     * Unless required by applicable law or agreed to in writing, software
-//     * distributed under the License is distributed on an "AS IS" BASIS,
-//     * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or 
implied.
-//     * See the License for the specific language governing permissions and
-//     * limitations under the License.
-//     */
-
-//    /// <summary>
-//    /// Used to replace custom Lucene tokens with custom HTML markup
-//    /// </summary>
-//    public sealed class LuceneNoteTokenRendererPart : 
DfmCustomizedRendererPartBase<IMarkdownRenderer, LuceneNoteBlockToken, 
MarkdownBlockContext>
-//    {
-//        private const string ExperimentalMessage = "This API is experimental 
and might change in incompatible ways in the next release.";
-//        private const string InternalMessage = "This API is for internal 
purposes only and might change in incompatible ways in the next release.";
-
-//        private readonly StringBuilder builder = new StringBuilder();
-
-//        public override string Name => "LuceneTokenRendererPart";
-
-//        public override bool Match(IMarkdownRenderer renderer, 
LuceneNoteBlockToken token, MarkdownBlockContext context) 
-//            => true;
-
-//        public override StringBuffer Render(IMarkdownRenderer renderer, 
LuceneNoteBlockToken token, MarkdownBlockContext context)
-//        {
-//            string message = token.Label.ToUpperInvariant() == "INTERNAL" ? 
InternalMessage : ExperimentalMessage;
-
-//            builder.Clear(); // Reuse string builder
-//            builder.AppendLine("<div class=\"NOTE\">");
-//            builder.AppendLine("<h5>Note</h5>");
-//            builder.Append("<p>").Append(message).AppendLine("</p>");
-//            builder.AppendLine("</div>");
-//            return builder.ToString();
-//            //return "<div class=\"lucene-block lucene-" + 
token.Label.ToLower() + "\">" + string.Format(Message, token.Label.ToUpper()) + 
"</div>";
-//        }
-//    }
-//}
diff --git a/src/docs/LuceneDocsPlugins/RendererPartProvider.cs 
b/src/docs/LuceneDocsPlugins/RendererPartProvider.cs
deleted file mode 100644
index aa778c54f..000000000
--- a/src/docs/LuceneDocsPlugins/RendererPartProvider.cs
+++ /dev/null
@@ -1,40 +0,0 @@
-//using System.Collections.Generic;
-//using System.Composition;
-//using Microsoft.DocAsCode.Dfm;
-
-//namespace LuceneDocsPlugins
-//{
-//    /*
-//     * Licensed to the Apache Software Foundation (ASF) under one or more
-//     * contributor license agreements.  See the NOTICE file distributed with
-//     * this work for additional information regarding copyright ownership.
-//     * The ASF licenses this file to You under the Apache License, Version 
2.0
-//     * (the "License"); you may not use this file except in compliance with
-//     * the License.  You may obtain a copy of the License at
-//     *
-//     *     http://www.apache.org/licenses/LICENSE-2.0
-//     *
-//     * Unless required by applicable law or agreed to in writing, software
-//     * distributed under the License is distributed on an "AS IS" BASIS,
-//     * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or 
implied.
-//     * See the License for the specific language governing permissions and
-//     * limitations under the License.
-//     */
-
-//    /// <summary>
-//    /// Exports our custom renderer via MEF to DocFx
-//    /// </summary>
-//    [Export(typeof(IDfmCustomizedRendererPartProvider))]
-//    public class RendererPartProvider : IDfmCustomizedRendererPartProvider
-//    {
-//        private readonly LuceneNoteTokenRendererPart 
luceneNoteTokenRendererPart = new LuceneNoteTokenRendererPart();
-
-//        public IEnumerable<IDfmCustomizedRendererPart> 
CreateParts(IReadOnlyDictionary<string, object> parameters)
-//        {
-//            yield return luceneNoteTokenRendererPart;
-//            //yield return new EnvironmentVariableRendererPart();
-//            //yield return new EnvironmentVariableBlockRendererPart();
-//        }
-//    }
-
-//}
diff --git a/src/dotnet/tools/lucene-cli/docs/index.md 
b/src/dotnet/tools/lucene-cli/docs/index.md
index 88da7a3a9..054f22a94 100644
--- a/src/dotnet/tools/lucene-cli/docs/index.md
+++ b/src/dotnet/tools/lucene-cli/docs/index.md
@@ -11,7 +11,7 @@ The Lucene.NET command line interface (CLI) is a new 
cross-platform toolchain wi
 Perform a one-time install of the lucene-cli tool using the following dotnet 
CLI command:
 
 ```console
-dotnet tool install lucene-cli -g --version 4.8.0-beta00016
+dotnet tool install lucene-cli -g --version EnvVar:LuceneNetVersion
 ```
 
 > [!NOTE]
diff --git a/websites/apidocs/docs.ps1 b/websites/apidocs/docs.ps1
index 6f0642d18..f360b42d1 100644
--- a/websites/apidocs/docs.ps1
+++ b/websites/apidocs/docs.ps1
@@ -180,10 +180,6 @@ if ($? -and $DisableMetaData -eq $false) {
 }
 
 if ($? -and $DisableBuild -eq $false) {
-    # HACK: DocFx doesn't seem to work with fenced code blocks, so we update 
the lucene-cli index file manually.
-    # Note it works better this way anyway because we can store a real version 
number in the file in the repo.
-    (Get-Content -Path $CliIndexPath -Raw) -Replace 
'(?<=--version\s)\d+?\.\d+?\.\d+?(?:\.\d+?)?(?:-\w+)?', $LuceneNetVersion | 
Set-Content -Path $CliIndexPath
-
     # Update our TOC to the latest LuceneNetVersion
     (Get-Content -Path $TocPath1 -Raw) -Replace 
'(?<=lucenenet\.apache\.org\/docs\/)\d+?\.\d+?\.\d+?(?:\.\d+?)?(?:-\w+)?', 
$LuceneNetVersion | Set-Content -Path $TocPath1
     (Get-Content -Path $TocPath2 -Raw) -Replace 
'(?<=lucenenet\.apache\.org\/docs\/)\d+?\.\d+?\.\d+?(?:\.\d+?)?(?:-\w+)?', 
$LuceneNetVersion | Set-Content -Path $TocPath2

Reply via email to