Skip to content

Commit

Permalink
fix: spelling errors detected by codespell (#6)
Browse files Browse the repository at this point in the history
Added CI for `codespell` too.
  • Loading branch information
AlejandroSuero authored May 14, 2024
1 parent 4b78441 commit 00f93e0
Show file tree
Hide file tree
Showing 10 changed files with 32 additions and 11 deletions.
2 changes: 1 addition & 1 deletion .github/ISSUE_TEMPLATE/feature_request.md
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@ when [...]

A clear and concise description of what you want to happen.

## Describe alternatives you've considere
## Describe alternatives you've considered

A clear and concise description of any alternative solutions or features you've considered.

Expand Down
13 changes: 13 additions & 0 deletions .github/workflows/codespell.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,13 @@
name: codespell

on: [pull_request]

jobs:
codespell:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- name: Install codespell
run: pip install codespell
- name: Use codespell
run: make spell
4 changes: 2 additions & 2 deletions CONTRIBUTING.md
Original file line number Diff line number Diff line change
Expand Up @@ -89,14 +89,14 @@ BREAKING CHANGE: refactor to use neovim's API supported only in v0.9 or higher

- **Create a Pull Request (PR)**: Once you pushed your changes, make a pull request
so we can see the changes and discuss over it if necessary. A clear description
of the changes is allways welcomed.
of the changes is always welcomed.

## Good practices

- **Check for open issues**: Duplicated issues are never good.

- **Check for open PRs**: Make sure there isn't another PR open tackling a similar
issue or creating a similar feature. You can allways help in an open PR.
issue or creating a similar feature. You can always help in an open PR.

- **Descriptive and concised commits**: [conventional commit messages](https://www.conventionalcommits.org/en/v1.0.0).

Expand Down
8 changes: 8 additions & 0 deletions Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -33,4 +33,12 @@ format:
@$(call style_calls,"Running stylua format")
@stylua --color always -f ./stylua.toml lua/freeze-code

spell:
@$(call style_calls,"Running codespell check")
@codespell --quiet-level=2 --check-hidden --skip=./.git .

spell-write:
@$(call style_calls,"Running codespell write")
@codespell --quiet-level=2 --check-hidden --skip=./.git --write-changes .

all: test test-nvim lint
2 changes: 1 addition & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -93,7 +93,7 @@ local opts = {
> [bin-directory](https://github.com/AlejandroSuero/freeze-code.nvim/blob/main/bin)
Once you have it installed, you can use `:checkhealt freeze-code` to see if there
are any problems with the installation or you need to install aditional tools.
are any problems with the installation or you need to install additional tools.

<div align="right">
(<a href="#readme-top">Back to top</a>)
Expand Down
2 changes: 1 addition & 1 deletion bin/pngcopy-windows.ps1
Original file line number Diff line number Diff line change
@@ -1 +1 @@
Add-Type -AssemblyName System.Windows.Forms; [Windows.Forms.Clipboard]::SetImage($[Syste.Drawing.Image]::FromFile("$args[0]")))
Add-Type -AssemblyName System.Windows.Forms; [Windows.Forms.Clipboard]::SetImage($[System.Drawing.Image]::FromFile("$args[0]")))
2 changes: 1 addition & 1 deletion doc/freeze-code.nvim.txt
Original file line number Diff line number Diff line change
Expand Up @@ -78,7 +78,7 @@ Using your plugin manager at your disposal, in the example lazy
The commands to copy, as defaults per OS will be in the bin-directory
<https://github.com/AlejandroSuero/freeze-code.nvim/blob/main/bin>
Once you have it installed, you can use `:checkhealt freeze-code` to see if
there are any problems with the installation or you need to install aditional
there are any problems with the installation or you need to install additional
tools.


Expand Down
6 changes: 3 additions & 3 deletions lua/freeze-code/health.lua
Original file line number Diff line number Diff line change
Expand Up @@ -143,7 +143,7 @@ local optional_dependencies = {

---Check if the package is needed by the platorm
---@param pkg FreezeCodeHealthPackage
---@retur boolean
---@return boolean
local check_platform_needed = function(pkg)
if pkg.platform == "windows" then
return is_win
Expand Down Expand Up @@ -232,10 +232,10 @@ M.check = function()
end
else
if version ~= "not needed" then
version = version == "" and "(unkown)" or version
version = version == "" and "(unknown)" or version
local eol = version:find("\n")
if eol == nil then
version = "(unkown)"
version = "(unknown)"
else
version = version:sub(0, eol - 1)
end
Expand Down
2 changes: 1 addition & 1 deletion lua/freeze-code/utils/init.lua
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@

---@class FreezeCodeUtils
---@field logger FreezeCodeLogger
---@fiels os FreezeCodeOS
---@field os FreezeCodeOS
---@type FreezeCodeUtils|{}
local M = {}

Expand Down
2 changes: 1 addition & 1 deletion lua/freeze-code/utils/logger.lua
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
---@meta

---@brief [[
--- Provides `loggin` functions to display messages.
--- Provides `logging` functions to display messages.
---@brief ]]

---@class FreezeCodeLogger
Expand Down

0 comments on commit 00f93e0

Please sign in to comment.