Commit Graph
102 Commits
Author SHA1 Message Date
Frode Flaten 9ccaf107a0 Fix enum-ranges for ValidateRange in proxy commands (#17572) 2022-07-20 08:50:18 +05:00
Travis Plunk 4e6909e7b8 Make Assembly Load Native test work on a FX Dependent Linux Install (#17380)
* Make Assembly Load Native test work on a FX Dependent Linux Install

* Update Assembly.LoadNative.Tests.ps1
2022-06-06 13:06:38 -07:00
Paul Higinbotham a8d55851e0 Add the -ConfigurationFile command line parameter to pwsh to support local session configuration (#17447) 2022-06-06 12:12:53 -07:00
James Truher [MSFT] 65d8f11aeb Update telemetry collecting with a few changes (#17304) 2022-05-16 17:10:51 -07:00
Joey Robichaud b7ce3c568c Fix parsing SemanticVersion build label from version string (#16608) 2021-12-17 09:39:26 -08:00
Keith Hill b94dd91e74 Specify exe path as TargetObect for non-zero exit code ErrorRecord (#16108) 2021-10-14 14:47:54 -07:00
Aditya Patwardhan 3bb6b2736a Update Ubuntu images to use Ubuntu 20.04 (#15906) 2021-08-30 13:56:52 -07:00
Dongbo Wang 403767d7f7 Fix a casting error when using $PSNativeCommandUsesErrorActionPreference (#15993) 2021-08-25 17:05:54 -07:00
Robert Holt a4d14576b3 Make the native command error handling optionally honor ErrorActionPreference (#15897) 2021-08-24 15:27:22 -07:00
xtqqczze 055b7f3003 Fix CA1052 for public API to make classes static when they only have static methods (#15775) 2021-07-28 12:28:24 -07:00
James Truher [MSFT] f8b9e8e9db Create warnings when UTF7 is specified as an encoding (#13430) 2020-08-17 22:19:22 -07:00
xtqqczze 1f252f8bba Wrap tests in pester blocks (#12700)
# PR Summary

Wrap tests in pester blocks to prepare for pesterv5

## PR Context

<!-- Provide a little reasoning as to why this Pull Request helps and why you have opened it. -->

## PR Checklist

- [x] [PR has a meaningful title](https://github.com/PowerShell/PowerShell/blob/master/.github/CONTRIBUTING.md#pull-request---submission)
    - Use the present tense and imperative mood when describing your changes
- [x] [Summarized changes](https://github.com/PowerShell/PowerShell/blob/master/.github/CONTRIBUTING.md#pull-request---submission)
- [x] [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)
- [x] 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.
- **[Breaking changes](https://github.com/PowerShell/PowerShell/blob/master/.github/CONTRIBUTING.md#making-breaking-changes)**
    - [x] None
    - **OR**
    - [ ] [Experimental feature(s) needed](https://github.com/MicrosoftDocs/PowerShell-Docs/blob/staging/reference/6/Microsoft.PowerShell.Core/About/about_Experimental_Features.md)
        - [ ] Experimental feature name(s): <!-- Experimental feature name(s) here -->
- **User-facing changes**
    - [x] 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 -->
- **Testing - New and feature**
    - [x] 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**
    - [x] 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 enumerated concerns in the summary. 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).
        - Impact on Completions (both in the console and in editors) - one of PowerShell's most powerful features.
        - Impact on [PSScriptAnalyzer](https://github.com/PowerShell/PSScriptAnalyzer) (which provides linting & formatting in the editor extensions).
        - Impact on [EditorSyntax](https://github.com/PowerShell/EditorSyntax) (which provides syntax highlighting with in VSCode, GitHub, and many other editors).
2020-05-23 13:24:53 +00:00
Thomas Larsen 62bb436e71 Change CimCmdlets to use AliasAttribute (#12617) 2020-05-22 12:56:47 -07:00
xtqqczze f4382202ae Use correct casing for cmdlet name and cmdlet parameter name in *.ps1 files (#12584) 2020-05-07 17:00:30 +05:00
Dongbo Wang e741dc58dd Discover assemblies loaded by 'Assembly.Load(byte[])' and 'Assembly.LoadFile' (#12203)
* Fix regression: pwsh should discover assemblies loaded by 'Assembly.Load(byte[])' and 'Assembly.LoadFile'
2020-03-28 20:25:59 +05:00
Steve Lee b7cb335f03 Update copyright notice to latest guidance (#12190) 2020-03-24 11:08:37 -07:00
James Truher [MSFT] 4a0eda7fa9 Handle cases where CustomEvent was not initially sent (#11807) 2020-02-11 11:40:43 -08:00
mikeTWC1984 69bf7043c0 Update CmsCommands to use Store vs cert provider (#11643) 2020-02-06 15:38:17 -08:00
Brendan BurnsandIlya 127fec5eb9 Refactor and implement Restart-Computer for Un*x and macOS (#11319)
Co-authored-by: Ilya <darpa@yandex.ru>
2020-02-03 14:57:17 -08:00
James Truher [MSFT] bb8dbb953f Ensure that types referenced by PowerShellStandard are present (#10634) 2020-02-03 12:57:06 -08:00
Dongbo Wang a4c32bc337 Revert the PRs that made DBNull.Value and NullString.Value treated as $null (#11648) 2020-01-29 14:13:05 -08:00
xtqqczze 920b671fb4 Unify pester test syntax for the arguments of -BeOfType (#11558) 2020-01-24 11:00:37 -08:00
xtqqczze 6d97b3a4a4 Correct case of $IsCoreCLR special variable 2020-01-13 19:27:48 +00:00
xtqqczze 72d52b7d08 Correct case of $IsMacOS special variable 2020-01-13 19:26:54 +00:00
xtqqczze bb58e2aab6 Correct case of $false special variable 2020-01-13 19:25:35 +00:00
xtqqczze 47a3b4e293 Correct case of $true special variable 2020-01-13 19:25:09 +00:00
xtqqczze 743983390e Update pester syntax to v4 (#11544)
* Capitalize 'Should' command and fix whitespace

```powershell
$_ -ireplace '\s?\|\s?should\b',' | Should'
```

* Capitalise and apply hyphen to 'Not' parameter

```powershell
$_ -ireplace '(\| Should) not\b','$1 -Not'
```

* Capitalise and apply hyphen to 'Be' parameter

```powershell
$_ -ireplace '(\| Should(?: -Not)?) -?be\b','$1 -Be'
```

* Capitalise and apply hyphen to 'BeExactly' parameter

$_ -ireplace '(\| Should(?: -Not)?) -?beexactly\b','$1 -BeExactly'

* Capitalise and apply hyphen to 'BeGreaterThan' parameter

```powershell
$_ -ireplace '(\| Should(?: -Not)?) -?begreaterthan\b','$1 -BeGreaterThan'
```

* Use 'BeTrue' parameter

```powershell
$_ -ireplace '(\| Should(?: -Not)?) -Be\s\$?true\b','$1 -BeTrue'
```

* Use 'BeFalse' parameter

```powershell
$_ -ireplace '(\| Should(?: -Not)?) -Be\s\$?false\b','$1 -BeFalse'
```

* Capitalise and apply hyphen to 'Match' parameter

```powershell
$_ -ireplace '(\| Should(?: -Not)?)\s-?match\b','$1 -Match'
```

* Capitalise and apply hyphen to 'Throw' parameter

```powershell
$_ -ireplace '(\| Should(?: -Not)?)\s-?throw\b','$1 -Throw'
```

* Capitalise and apply hyphen to 'BeNullOrEmpty' parameter

```powershell
$_ -ireplace '(\| Should(?: -Not)?)\s-?benullorempty\b','$1 -BeNullOrEmpty'
```

* Capitalise 'Because' parameter

```powershell
$_ -ireplace '\s-because\b',' -Because'
```

* Fix 'BeNullOrEmpty'
2020-01-11 20:41:59 +05:00
Ilya 99cf9fd859 Re-balance CI tests (#11420) 2020-01-05 13:01:42 +05:00
Ilya b221c2afa2 Correct pwsh run (#11486) 2020-01-05 12:17:41 +05:00
Ilya 95c472a8c2 Add native binary resolver (#11032) 2019-12-09 12:03:53 -08:00
Ilya 42f21ae6a0 Cleanups in command discovery (#10815)
* Enable nullable, make minor cleanups, add a test
* Reduce allocations in GetAliasTable()
* Remove searching by extensions on Unix
2019-12-03 11:23:36 +05:00
Travis Plunk 3cdab0d18d Add Unblock-File for macOS (#11137) 2019-12-02 17:51:36 -08:00
Brendan Burns d38541fdce Add an implementation of Stop-Computer for Linux and macOS (#11151) 2019-12-02 17:29:11 -08:00
Dongbo Wang d46dfc26b7 Do not resolve types from assemblies that are loaded in separate AssemblyLoadContext (#11088) 2019-11-26 12:40:16 -08:00
Andrew b218e6f6cc Support using non-compatible Windows PowerShell modules in PowerShell Core (#10973) 2019-11-18 10:44:55 -08:00
Steve Lee 7ddfb825e4 Add back Get-Counter cmdlet for Windows (#10933) 2019-11-05 16:48:11 -08:00
Steve LeeandIlya b74a26bb91 Added cross-platform Get-Clipboard and Set-Clipboard (#10340)
Co-Authored-By: Ilya <darpa@yandex.ru>



Co-Authored-By: Ilya <darpa@yandex.ru>
2019-11-04 11:28:58 -08:00
Steve Lee 6882ad56fd Add back Out-Printer command (#10906) 2019-11-01 11:27:12 -07:00
Steve Lee ca68d9dbc5 Add GraphicalHost assembly to enable Out-GridView, Show-Command, and Get-Help -ShowWindow (#10899) 2019-11-01 10:05:32 -07:00
Steve Lee 0b12ea057a Add back Update-List command (#10922) 2019-10-30 11:05:30 -07:00
Steve Lee ca1b6fb4c5 Add back Clear-RecycleBin for Windows (#10909) 2019-10-28 08:18:26 +05:00
Steve Lee d8d32d79c2 Implement Get-Error cmdlet as Experimental Feature (#10727) 2019-10-15 14:32:14 -07:00
Steve Lee 1fa73e360f Add back Get-HotFix cmdlet (#10740) 2019-10-11 22:51:43 +05:00
Dongbo Wang ec105da3f1 Some code cleanup work (#10698)
* Move Utils.GetUserConfigurationDirectory to Platform.ConfigDirectory
* Unify the use of Platform.ConfigDirectory and Platform.CacheDirectory
2019-10-07 14:15:01 +05:00
Andrew ed29ad1506 Adding PSCore group policy definitions (#10468) 2019-09-12 13:41:59 -07:00
Kirk Munro cc0fed479a Add APIs for breakpoint management in runspaces and enable attach to process without BreakAll for PSES (#10338) 2019-09-05 11:30:25 -07:00
Steve Lee 00949ab352 .CPL should be added to PATHEXT (#9828) 2019-08-17 22:45:13 +05:00
James Truher [MSFT] fe2cc6aca8 Additional Telemetry - Implementation of RFC0036 (#10336) 2019-08-15 16:13:53 -07:00
Steve Lee 882cbf367f Enable Experimental Features by default on Preview builds (#10228) 2019-08-08 11:37:25 -07:00
Ilya 0ae7d50d5c Remove 'kill' alias for Stop-Process cmdlet on Unix (#10098) 2019-07-15 08:12:26 +05:00