mirror of
https://github.com/microsoft/PowerToys.git
synced 2026-04-05 18:57:19 +02:00
Updates for check-spelling v0.0.25 (#40386)
## Summary of the Pull Request - #39572 updated check-spelling but ignored: > 🐣 Breaking Changes [Code Scanning action requires a Code Scanning Ruleset](https://github.com/check-spelling/check-spelling/wiki/Breaking-Change:-Code-Scanning-action-requires-a-Code-Scanning-Ruleset) If you use SARIF reporting, then instead of the workflow yielding an ❌ when it fails, it will rely on [github-advanced-security 🤖](https://github.com/apps/github-advanced-security) to report the failure. You will need to adjust your checks for PRs. This means that check-spelling hasn't been properly doing its job 😦. I'm sorry, I should have pushed a thing to this repo earlier,... Anyway, as with most refreshes, this comes with a number of fixes, some are fixes for typos that snuck in before the 0.0.25 upgrade, some are for things that snuck in after, some are based on new rules in spell-check-this, and some are hand written patterns based on running through this repository a few times. About the 🐣 **breaking change**: someone needs to create a ruleset for this repository (see [Code Scanning action requires a Code Scanning Ruleset: Sample ruleset ](https://github.com/check-spelling/check-spelling/wiki/Breaking-Change:-Code-Scanning-action-requires-a-Code-Scanning-Ruleset#sample-ruleset)). The alternative to adding a ruleset is to change the condition to not use sarif for this repository. In general, I think the github integration from sarif is prettier/more helpful, so I think that it's the better choice. You can see an example of it working in: - https://github.com/check-spelling-sandbox/PowerToys/pull/23 --------- Signed-off-by: Josh Soref <2119212+jsoref@users.noreply.github.com> Co-authored-by: Mike Griese <migrie@microsoft.com> Co-authored-by: Dustin L. Howett <dustin@howett.net>
This commit is contained in:
@@ -30,7 +30,7 @@ internal sealed partial class EndTaskCommand : InvokableCommand
|
||||
/// Method to initiate killing the process of a window
|
||||
/// </summary>
|
||||
/// <param name="window">Window data</param>
|
||||
/// <returns>True if the PT Run window should close, otherwise false.</returns>
|
||||
/// <returns>True if the PT Run window should close; otherwise, false.</returns>
|
||||
private static bool KillProcess(Window window)
|
||||
{
|
||||
// Validate process
|
||||
|
||||
@@ -35,7 +35,7 @@ internal static class FuzzyMatching
|
||||
text = text.ToLower(CultureInfo.CurrentCulture);
|
||||
|
||||
// Create a grid to march matches like
|
||||
// eg.
|
||||
// e.g.
|
||||
// a b c a d e c f g
|
||||
// a x x
|
||||
// c x x
|
||||
|
||||
@@ -8,7 +8,7 @@ namespace Microsoft.CmdPal.Ext.WindowWalker.Components;
|
||||
/// <summary>
|
||||
/// A class to represent a search string
|
||||
/// </summary>
|
||||
/// <remarks>Class was added inorder to be able to attach various context data to
|
||||
/// <remarks>Class was added in order to be able to attach various context data to
|
||||
/// a search string</remarks>
|
||||
internal sealed class SearchString
|
||||
{
|
||||
|
||||
@@ -163,7 +163,7 @@ internal sealed class Window
|
||||
{
|
||||
if (!NativeMethods.ShowWindow(Hwnd, ShowWindowCommand.Restore))
|
||||
{
|
||||
// ShowWindow doesn't work if the process is running elevated: fallback to SendMessage
|
||||
// ShowWindow doesn't work if the process is running elevated: fall back to SendMessage
|
||||
_ = NativeMethods.SendMessage(Hwnd, Win32Constants.WM_SYSCOMMAND, Win32Constants.SC_RESTORE);
|
||||
}
|
||||
}
|
||||
|
||||
@@ -993,7 +993,7 @@ public enum ExtendedWindowStyles : uint
|
||||
|
||||
/// <summary>
|
||||
/// The window has generic "right-aligned" properties. This depends on the window class. This style has
|
||||
/// an effect only if the shell language supports reading-order alignment, otherwise is ignored.
|
||||
/// an effect only if the shell language supports reading-order alignment; otherwise, is ignored.
|
||||
/// </summary>
|
||||
WS_EX_RIGHT = 0x1000,
|
||||
|
||||
|
||||
@@ -103,7 +103,7 @@ public class VirtualDesktopHelper
|
||||
var allDeskValue = (byte[]?)virtualDesktopKey.GetValue("VirtualDesktopIDs", null) ?? Array.Empty<byte>();
|
||||
if (allDeskValue != null)
|
||||
{
|
||||
// We clear only, if we can read from registry. Otherwise we keep the existing values.
|
||||
// We clear only, if we can read from registry. Otherwise, we keep the existing values.
|
||||
_availableDesktops.Clear();
|
||||
|
||||
// Each guid has a length of 16 elements
|
||||
@@ -134,7 +134,7 @@ public class VirtualDesktopHelper
|
||||
else
|
||||
{
|
||||
// The registry value is missing when the user hasn't switched the desktop at least one time before reading the registry. In this case we can set it to desktop one.
|
||||
// We can only set it to desktop one, if we have at least one desktop in the desktops list. Otherwise we keep the existing value.
|
||||
// We can only set it to desktop one, if we have at least one desktop in the desktops list. Otherwise, we keep the existing value.
|
||||
ExtensionHost.LogMessage(new LogMessage() { Message = "VirtualDesktopHelper.UpdateDesktopList() failed to read the id for the current desktop form registry." });
|
||||
_currentDesktop = _availableDesktops.Count >= 1 ? _availableDesktops[0] : _currentDesktop;
|
||||
}
|
||||
@@ -236,7 +236,7 @@ public class VirtualDesktopHelper
|
||||
/// Returns the number (position) of a desktop.
|
||||
/// </summary>
|
||||
/// <param name="desktop">The guid of the desktop.</param>
|
||||
/// <returns>Number of the desktop, if found. Otherwise a value of zero.</returns>
|
||||
/// <returns>Number of the desktop, if found. Otherwise, a value of zero.</returns>
|
||||
public int GetDesktopNumber(Guid desktop)
|
||||
{
|
||||
if (_desktopListAutoUpdate)
|
||||
|
||||
Reference in New Issue
Block a user