Thanks to visit codestin.com
Credit goes to github.com

Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
18 changes: 2 additions & 16 deletions .github/PULL_REQUEST_TEMPLATE.md
Original file line number Diff line number Diff line change
Expand Up @@ -14,8 +14,7 @@
- Use the present tense and imperative mood when describing your changes
- [ ] [Summarized changes](https://github.com/PowerShell/PowerShell/blob/master/.github/CONTRIBUTING.md#pull-request---submission)
- [ ] [Make sure all `.h`, `.cpp`, `.cs`, `.ps1` and `.psm1` files have the correct copyright header](https://github.com/PowerShell/PowerShell/blob/master/.github/CONTRIBUTING.md#pull-request---submission)
- [ ] This PR is ready to merge and is not [Work in Progress](https://github.com/PowerShell/PowerShell/blob/master/.github/CONTRIBUTING.md#pull-request---work-in-progress).
- If the PR is work in progress, please add the prefix `WIP:` or `[ WIP ]` to the beginning of the title (the `WIP` bot will keep its status check at `Pending` while the prefix is present) and remove the prefix when the PR is ready.
- [ ] This PR is ready to merge. If this PR is a work in progress, please open this as a [Draft Pull Request and mark it as Ready to Review when it is ready to merge](https://docs.github.com/pull-requests/collaborating-with-pull-requests/proposing-changes-to-your-work-with-pull-requests/about-pull-requests#draft-pull-requests).
- **[Breaking changes](https://github.com/PowerShell/PowerShell/blob/master/.github/CONTRIBUTING.md#making-breaking-changes)**
- [ ] None
- **OR**
Expand All @@ -25,21 +24,8 @@
- [ ] Not Applicable
- **OR**
- [ ] [Documentation needed](https://github.com/PowerShell/PowerShell/blob/master/.github/CONTRIBUTING.md#pull-request---submission)
- [ ] Issue filed: <!-- Number/link of that issue here -->
- [ ] Issue filed: <!-- Number/link of that issue here -->
- **Testing - New and feature**
- [ ] N/A or can only be tested interactively
- **OR**
- [ ] [Make sure you've added a new test if existing tests do not effectively test the code changed](https://github.com/PowerShell/PowerShell/blob/master/.github/CONTRIBUTING.md#before-submitting)
- **Tooling**
- [ ] I have considered the user experience from a tooling perspective and don't believe tooling will be impacted.
- **OR**
- [ ] I have considered the user experience from a tooling perspective and opened an issue in the relevant tool repository. This may include:
- [ ] Impact on [PowerShell Editor Services](https://github.com/PowerShell/PowerShellEditorServices) which is used in the [PowerShell extension](https://github.com/PowerShell/vscode-powershell) for VSCode
(which runs in a different PS Host).
- [ ] Issue filed: <!-- Number/link of that issue here -->
- [ ] Impact on Completions (both in the console and in editors) - one of PowerShell's most powerful features.
- [ ] Issue filed: <!-- Number/link of that issue here -->
- [ ] Impact on [PSScriptAnalyzer](https://github.com/PowerShell/PSScriptAnalyzer) (which provides linting & formatting in the editor extensions).
- [ ] Issue filed: <!-- Number/link of that issue here -->
- [ ] Impact on [EditorSyntax](https://github.com/PowerShell/EditorSyntax) (which provides syntax highlighting with in VSCode, GitHub, and many other editors).
- [ ] Issue filed: <!-- Number/link of that issue here -->
17 changes: 13 additions & 4 deletions .github/workflows/markdownLink.yml
Original file line number Diff line number Diff line change
Expand Up @@ -30,11 +30,20 @@ jobs:
# Full git history is needed to get a proper
# list of changed files within `super-linter`
fetch-depth: 0
- name: Load super-linter configuration
# Use grep inverse matching to exclude eventual comments in the .env file
# because the GitHub Actions command to set environment variables doesn't
# support comments.
# Ref: https://docs.github.com/en/actions/writing-workflows/choosing-what-your-workflow-does/workflow-commands-for-github-actions#setting-an-environment-variable
run: grep -v '^#' tools/super-linter/config/super-linter.env >> "$GITHUB_ENV"
- name: Lint Markdown
uses: super-linter/super-linter@a8150b40c89574adb5f68bf9502b890a236a06b3 # v5.7.2
env:
VALIDATE_ALL_CODEBASE: false
DEFAULT_BRANCH: master
FILTER_REGEX_INCLUDE: .*\.md
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
VALIDATE_EDITORCONFIG: false
- name: Super-Linter correction instructions
if: failure()
uses: actions/[email protected]
with:
script: |
const message = "Super-Linter found issues in the changed files. Please check the logs for details. You can run the linter locally using the command: `./tools/super-lister/super-lister.ps1`.";
core.setFailed(message);
4 changes: 4 additions & 0 deletions .prettierrc
Original file line number Diff line number Diff line change
@@ -0,0 +1,4 @@
{
"tabWidth": 2,
"useTabs": false
}
8 changes: 8 additions & 0 deletions tools/super-linter/config/super-linter.env
Original file line number Diff line number Diff line change
@@ -0,0 +1,8 @@
VALIDATE_ALL_CODEBASE=false
DEFAULT_BRANCH=master
FILTER_REGEX_INCLUDE=.*\.md
VALIDATE_EDITORCONFIG=false
VALIDATE_JSCPD=false
VALIDATE_CHECKOV=false
FIX_MARKDOWN_PRETTIER=true
FIX_MARKDOWN=true
15 changes: 15 additions & 0 deletions tools/super-linter/super-linter.ps1
Original file line number Diff line number Diff line change
@@ -0,0 +1,15 @@
# Copyright (c) Microsoft Corporation.
# Licensed under the MIT License.

param(
[string]$RepoRoot = (Join-Path -Path $PSScriptRoot -ChildPath '../..'),
[string]$Platform
)

$resolvedPath = (Resolve-Path $RepoRoot).ProviderPath
$platformParam = @()
if ($Platform) {
$platformParam = @("--platform", $Platform)
}

docker run $platformParam -e RUN_LOCAL=true --env-file "$PSScriptRoot/config/super-linter.env" -v "${resolvedPath}:/tmp/lint" ghcr.io/super-linter/super-linter:latest
Loading