{"id":27741533,"url":"https://github.com/microsoft/psrule-vscode","last_synced_at":"2025-04-29T19:53:29.365Z","repository":{"id":36989745,"uuid":"173281561","full_name":"microsoft/PSRule-vscode","owner":"microsoft","description":"A Visual Studio Code extension for PSRule.","archived":false,"fork":false,"pushed_at":"2025-04-29T12:26:35.000Z","size":4064,"stargazers_count":51,"open_issues_count":5,"forks_count":20,"subscribers_count":5,"default_branch":"release/v2.9.x","last_synced_at":"2025-04-29T19:53:25.150Z","etag":null,"topics":["hacktoberfest","powershell","ps-rule","psrule","rule","visual-studio-code","vscode","vscode-extension"],"latest_commit_sha":null,"homepage":"https://marketplace.visualstudio.com/items?itemName=bewhite.psrule-vscode","language":"TypeScript","has_issues":false,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"mit","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/microsoft.png","metadata":{"files":{"readme":"README.md","changelog":"CHANGELOG.md","contributing":"CONTRIBUTING.md","funding":null,"license":"LICENSE","code_of_conduct":"CODE_OF_CONDUCT.md","threat_model":null,"audit":null,"citation":null,"codeowners":".github/CODEOWNERS","security":"SECURITY.md","support":"SUPPORT.md","governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null,"zenodo":null}},"created_at":"2019-03-01T10:18:30.000Z","updated_at":"2025-04-29T11:59:19.000Z","dependencies_parsed_at":"2023-01-17T11:45:25.927Z","dependency_job_id":"bad3f590-7080-49aa-a708-6ed02b7f90a6","html_url":"https://github.com/microsoft/PSRule-vscode","commit_stats":null,"previous_names":[],"tags_count":36,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/microsoft%2FPSRule-vscode","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/microsoft%2FPSRule-vscode/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/microsoft%2FPSRule-vscode/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/microsoft%2FPSRule-vscode/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/microsoft","download_url":"https://codeload.github.com/microsoft/PSRule-vscode/tar.gz/refs/heads/release/v2.9.x","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":251574668,"owners_count":21611386,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["hacktoberfest","powershell","ps-rule","psrule","rule","visual-studio-code","vscode","vscode-extension"],"created_at":"2025-04-28T16:20:31.868Z","updated_at":"2025-04-29T19:53:29.342Z","avatar_url":"https://github.com/microsoft.png","language":"TypeScript","funding_links":[],"categories":[],"sub_categories":[],"readme":"# PSRule\n\nValidate infrastructure as code (IaC) and DevOps repositories using the PSRule PowerShell module.\nPSRule is powerful, feature rich, and highly customizable to meet your needs.\n\n\u003e [!NOTE]\n\u003e This extension has being migrated into \u003chttps://github.com/microsoft/PSRule\u003e\n\u003e and this repository will be archived in the future.\n\u003e Currently this repository reflects the last stable release of v2.9.x.\n\u003e An improve PSRule extension for V3 will be release from the new repository.\n\u003e Please log an new issues at \u003chttps://github.com/microsoft/PSRule/issues\u003e\n---\n\nThis extension is available in two release channels:\n\nChannel | Description | Version/ downloads\n------- | ----------- | ---\n[Preview][ext-preview] | More frequent releases but more likely to contain bugs. | [![Preview][ext-preview-version-badge]][ext-preview] ![ext-preview-installs-badge]\n[Stable][ext-stable] | Less frequent releases, with more user testing, experimental features are disabled. | [![Stable][ext-stable-version-badge]][ext-stable] ![ext-stable-installs-badge]\n\n## Features\n\n### CodeLens\n\n\u003cp align=\"center\"\u003e\n  \u003cimg src=\"./docs/images/codelens-doc-link.png\" alt=\"CodeLens showing link to create documentation\" width=\"640px\" /\u003e\n\u003c/p\u003e\n\n- CodeLens shows links to create or edit markdown documentation from rules in YAML, JSON, or PowerShell.\n  - **Open documentation** \u0026mdash; Opens rule markdown documentation in the editor.\n    - The location for storing documentation is configurable in the extension settings.\n    - By default, a locale specific folder is created in the same directory as the rule file.\n  - **Create documentation** \u0026mdash; Creates a new markdown file for the rule based on a snippet.\n    - New markdown documentation is created with the built-in _Rule Doc_ snippet.\n    - An alternative snippet can be specified by configuring extension settings.\n\n### IntelliSense\n\n\u003cp align=\"center\"\u003e\n  \u003cimg src=\"./docs/images/options-schema-flyout.png\" alt=\"Options suggestion context menu\" width=\"640px\" /\u003e\n\u003c/p\u003e\n\n- Adds IntelliSense and validation support for configuring options and resources.\n  - **Workspace options** \u0026mdash; use IntelliSense to configure options for the workspace.\n    - Type or trigger IntelliSense with `Ctrl+Space` from `ps-rule.yaml`.\n  - **Create resources** \u0026mdash; define _baselines_ and _selectors_ by using pre-built snippets and IntelliSense.\n\n\u003cp align=\"center\"\u003e\n  \u003cimg src=\"./docs/images/snippet-rule-type.png\" alt=\"Rule definition snippet\" width=\"520px\" /\u003e\n\u003c/p\u003e\n\n- Adds snippets for defining new rules.\n  - **Define rules** with snippets and IntelliSense support.\n    - Trigger IntelliSense by typing `rule` in a `.Rule.ps1`, `.Rule.yaml`, or `.Rule.jsonc` file.\n    IntelliSense can also be triggered by using the shortcut `Ctrl+Space`.\n\n\u003cp align=\"center\"\u003e\n  \u003cimg src=\"./docs/images/snippet-markdown.png\" alt=\"Rule markdown documentation snippet\" width=\"640px\" /\u003e\n\u003c/p\u003e\n\n- Adds snippets for creating markdown documentation.\n  - **Quick documentation** \u0026mdash; create rule documentation to provide rule recommendations and examples.\n    - Trigger IntelliSense by typing `rule` in a `.md` file.\n    IntelliSense can also be triggered by using the shortcut `Ctrl+Space`.\n\n### Quick tasks\n\n\u003cp align=\"center\"\u003e\n  \u003cimg src=\"./docs/images/tasks-provider.png\" alt=\"Built-in tasks shown in task list\" width=\"640px\" /\u003e\n\u003c/p\u003e\n\n- Adds quick tasks for analysis directly from Visual Studio Code.\n  - **Run analysis** \u0026mdash; runs rules against files in the current workspace.\n    - _Input path_, _Baseline_, _Modules_, and _Outcome_ options can be configured per task.\n    - _Output as_, and showing a _Not processed warning_ options can be configured by workspace or user.\n    - Rule stored in `.ps-rule/` are automatically used by default.\n    - Use the built-in analysis task by running or configuring the task from the _Terminal_ menu.\n\n## Configuration\n\nIn addition to configuring the [ps-rule.yaml] options file, the following settings are available.\n\nName                                            | Description\n----                                            | -----------\n`PSRule.codeLens.ruleDocumentationLinks`        | Enables Code Lens that displays links to rule documentation. This is an experimental feature that requires experimental features to be enabled.\n`PSRule.documentation.path`                     | The path to look for rule documentation. When not set, the path containing rules will be used.\n`PSRule.documentation.localePath`               | The locale path to use for locating rule documentation. The VS Code locale will be used by default.\n`PSRule.documentation.customSnippetPath`        | The path to a file containing a rule documentation snippet. When not set, built-in PSRule snippets will be used.\n`PSRule.documentation.snippet`                  | The name of a snippet to use when creating new rule documentation. By default, the built-in `Rule Doc` snippet will be used.\n`PSRule.execution.notProcessedWarning`          | Warn when objects are not processed by any rule. This option is deprecated and replaced by `PSRule.execution.unprocessedObject`.\n`PSRule.execution.ruleExcluded`                 | Determines how to handle excluded rules. When set to `None`, PSRule will use the default (`Ignore`), unless set by PSRule options.\n`PSRule.execution.ruleSuppressed`               | Determines how to handle suppressed rules. When set to `None`, PSRule will use the default (`Warn`), unless set by PSRule options.\n`PSRule.execution.unprocessedObject`            | Determines how to report objects that are not processed by any rule. When set to `None`, PSRule will use the default (`Warn`), unless set by PSRule options.\n`PSRule.experimental.enabled`                   | Enables experimental features in the PSRule extension.\n`PSRule.notifications.showChannelUpgrade`       | Determines if a notification to switch to the stable channel is shown on start up.\n`PSRule.notifications.showPowerShellExtension`  | Determines if a notification to install the PowerShell extension is shown on start up.\n`PSRule.output.as`                              | Configures the output of analysis tasks, either summary or detailed.\n`PSRule.rule.baseline`                          | The name of the default baseline to use for executing rules. This setting can be overridden on individual PSRule tasks.\n\n## Support\n\nThis project uses GitHub Issues to track bugs and feature requests.\nPlease search the existing issues before filing new issues to avoid duplicates.\n\n- For new issues, file your bug or feature request as a new [issue].\n- For help, discussion, and support questions about using this project, join or start a [discussion].\n\nSupport for this project/ product is limited to the resources listed above.\n\n## Installing PSRule module\n\nPSRule is available from the PowerShell Gallery and is required for this extension to work.\n\nTo install the module use the following command from a PowerShell prompt.\n\n```powershell\nInstall-Module -Name PSRule -Scope CurrentUser;\n```\n\n## Installing the extension\n\nYou can install the latest release of the extension by following the steps in the [Visual Studio Code documentation][vscode-ext-gallery].\nIn the Extensions pane, search for _PSRule_ extension and install it there.\nYou will get notified automatically about any future extension updates.\n\n```text\ncode --install-extension bewhite.psrule-vscode-preview\n```\n\n\u003e NOTE: If you are using VS Code Insiders, the command will be `code-insiders`.\n\n## Contributing\n\nThis project welcomes contributions and suggestions.\nIf you are ready to contribute, please visit the [contribution guide].\n\n## Code of Conduct\n\nThis project has adopted the [Microsoft Open Source Code of Conduct](https://opensource.microsoft.com/codeofconduct/).\nFor more information see the [Code of Conduct FAQ](https://opensource.microsoft.com/codeofconduct/faq/)\nor contact [opencode@microsoft.com](mailto:opencode@microsoft.com) with any additional questions or comments.\n\n## Maintainers\n\n- [Bernie White](https://github.com/BernieWhite)\n\n## License\n\nThis project is [licensed under the MIT License][license].\n\n[issue]: https://github.com/Microsoft/PSRule-vscode/issues\n[discussion]: https://github.com/microsoft/PSRule-vscode/discussions\n[vscode-ext-gallery]: https://code.visualstudio.com/docs/editor/extension-gallery\n[ext-preview]: https://marketplace.visualstudio.com/items?itemName=bewhite.psrule-vscode-preview\n[ext-preview-version-badge]: https://vsmarketplacebadges.dev/version/bewhite.psrule-vscode-preview.png\n[ext-preview-installs-badge]: https://vsmarketplacebadges.dev/installs-short/bewhite.psrule-vscode-preview.png\n[ext-stable]: https://marketplace.visualstudio.com/items?itemName=bewhite.psrule-vscode\n[ext-stable-version-badge]: https://vsmarketplacebadges.dev/version/bewhite.psrule-vscode.png\n[ext-stable-installs-badge]: https://vsmarketplacebadges.dev/installs-short/bewhite.psrule-vscode.png\n[contribution guide]: https://github.com/Microsoft/PSRule-vscode/blob/main/CONTRIBUTING.md\n[license]: https://github.com/Microsoft/PSRule-vscode/blob/main/LICENSE\n[ps-rule.yaml]: https://aka.ms/ps-rule/options\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fmicrosoft%2Fpsrule-vscode","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fmicrosoft%2Fpsrule-vscode","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fmicrosoft%2Fpsrule-vscode/lists"}