PowerShell / PowerShell/PowerShellEditorServices

Provide a way to enable auto-loading of editor command modules

Open
#215 4 comments 5 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

Issue-Discussion Issue-Enhancement
Dominant language
C#
Stars
767
Forks
266
Avg merge
3d 16h
Merged PRs (30d)
1

Description

It would be nice if there was a way for the user to opt in to the auto-loading of any PowerShell Gallery modules they've installed which include editor commands written with the new extensibilty model. The user would add a cmdlet call to their chosen editor's profile which invokes this module auto-loading process. It might look something like this:

Import-EditorCommandModules [-Exclude <String[]> [-Repository <String[]>]`

The -Exclude parameter would take a list of module names which should be excluded from the auto-loading process. The -Repository parameter would restrict auto module loading to only the modules which were installed from the specified repositories.

When invoked, this command would use Get-InstalledModule to find all modules and then filter them down to the specified repositories. It'd then filter them down even further to only those with a conventional tag called EditorCommand. This would allow module authors to indicate that their module contains editor commands which can be auto-loaded.

Contributor guide

Open the contributing guide

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

Start with the proposed Import-EditorCommandModules entry point and the editor profile where users would invoke it. Review how Get-InstalledModule exposes installed modules and repositories, then define filtering for -Exclude, -Repository, and the EditorCommand tag. Done means opted-in loading finds only eligible modules and respects both filters.

Written by the indexing model from the issue text.

Assessment

Tech stack
powershell
Domain
tooling
Issue type
Feature
Difficulty
5/5
Estimated time
Over a week
Activity status
Stale
Clarity
Mostly clear
Newbie friendliness
35/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.