[PR #25] [MERGED] Dynamically generate list of parsers #24053

Open
opened 2026-01-31 09:01:08 +00:00 by claunia · 0 comments
Owner

📋 Pull Request Information

Original PR: https://github.com/microsoft/terminal/pull/25
Author: @twsouthwick
Created: 8/28/2017
Status: ✅ Merged
Merged: 4/25/2018
Merged by: @miniksa

Base: master ← Head: dynamic-parser-list


📝 Commits (1)

  • 9bd6053 Dynamically generate list of parsers

📊 Changes

6 files changed (+30 additions, -12 deletions)

View changed files

📝 tools/ColorTool/ColorTool/ISchemeParser.cs (+2 -0)
📝 tools/ColorTool/ColorTool/IniSchemeParser.cs (+6 -3)
📝 tools/ColorTool/ColorTool/Program.cs (+14 -6)
📝 tools/ColorTool/ColorTool/Resources.Designer.cs (+2 -2)
📝 tools/ColorTool/ColorTool/Resources.resx (+4 -1)
📝 tools/ColorTool/ColorTool/XmlSchemeParser.cs (+2 -0)

📄 Description

This will automatically generate a lit of parsers that are available. I'm not sure what the best names are, but it currently searches for anything that implements ISchemeParser and outputs a name such as:

Usage:
    colortool.exe [options] <schemename>
ColorTool is a utility for helping to set the color palette of the Windows Console.
By default, applies the colors in the specified .itermcolors or .ini file to the current console window.
This does NOT save the properties automatically. For that, you'll need to open the properties sheet and hit "Ok".
Included should be a `schemes/` directory with a selection of schemes of both formats for examples.
Feel free to add your own preferred scheme to that directory.
Arguments:
    <schemename>: The name of a color scheme. ct will try to first load it as an .itermcolors color scheme.
                  If that fails, it will look for it as an .ini file color scheme.
Options:
    -?, --help     : Display this help message
    -c, --current  : Print the color table for the currently applied scheme
    -q, --quiet    : Don't print the color table after applying
    -d, --defaults : Apply the scheme to only the defaults in the registry
    -b, --both     : Apply the scheme to both the current console and the defaults.
    -v, --version  : Display the version number

Available importers:
  INI File Parser
  iTerm Parser

Fixes #24


🔄 This issue represents a GitHub Pull Request. It cannot be merged through Gitea due to API limitations.

## 📋 Pull Request Information **Original PR:** https://github.com/microsoft/terminal/pull/25 **Author:** [@twsouthwick](https://github.com/twsouthwick) **Created:** 8/28/2017 **Status:** ✅ Merged **Merged:** 4/25/2018 **Merged by:** [@miniksa](https://github.com/miniksa) **Base:** `master` ← **Head:** `dynamic-parser-list` --- ### 📝 Commits (1) - [`9bd6053`](https://github.com/microsoft/terminal/commit/9bd6053664fda6a96cc7047b82274315f7601287) Dynamically generate list of parsers ### 📊 Changes **6 files changed** (+30 additions, -12 deletions) <details> <summary>View changed files</summary> 📝 `tools/ColorTool/ColorTool/ISchemeParser.cs` (+2 -0) 📝 `tools/ColorTool/ColorTool/IniSchemeParser.cs` (+6 -3) 📝 `tools/ColorTool/ColorTool/Program.cs` (+14 -6) 📝 `tools/ColorTool/ColorTool/Resources.Designer.cs` (+2 -2) 📝 `tools/ColorTool/ColorTool/Resources.resx` (+4 -1) 📝 `tools/ColorTool/ColorTool/XmlSchemeParser.cs` (+2 -0) </details> ### 📄 Description This will automatically generate a lit of parsers that are available. I'm not sure what the best names are, but it currently searches for anything that implements `ISchemeParser` and outputs a name such as: ``` Usage: colortool.exe [options] <schemename> ColorTool is a utility for helping to set the color palette of the Windows Console. By default, applies the colors in the specified .itermcolors or .ini file to the current console window. This does NOT save the properties automatically. For that, you'll need to open the properties sheet and hit "Ok". Included should be a `schemes/` directory with a selection of schemes of both formats for examples. Feel free to add your own preferred scheme to that directory. Arguments: <schemename>: The name of a color scheme. ct will try to first load it as an .itermcolors color scheme. If that fails, it will look for it as an .ini file color scheme. Options: -?, --help : Display this help message -c, --current : Print the color table for the currently applied scheme -q, --quiet : Don't print the color table after applying -d, --defaults : Apply the scheme to only the defaults in the registry -b, --both : Apply the scheme to both the current console and the defaults. -v, --version : Display the version number Available importers: INI File Parser iTerm Parser ``` Fixes #24 --- <sub>🔄 This issue represents a GitHub Pull Request. It cannot be merged through Gitea due to API limitations.</sub>
claunia added the pull-request label 2026-01-31 09:01:08 +00:00
Sign in to join this conversation.
No Label pull-request
1 Participants
Notifications
Due Date
No due date set.
Dependencies

No dependencies set.

Reference: starred/terminal#24053