Giter Site home page Giter Site logo

vale-styles's Introduction

Rocky Docs - Vale Styles

Project for creating custom dictionaries for vocabulary words after installing the vale linter in NvChad.

Purpose of the project

When checking your document with vale you might receive warnings such as this:

Use correct American English spelling. Did you really mean 'Rocky'?

This term is perfectly fine but not known to vale so these messages can clutter up the display, making it difficult to actually see the warnings that you need. Using this repository and customizing it with your own vocabulary words will help you use vale within NvChad without all of the clutter.

Requirements

Installation

Your installation is in the Neovim shared folder ~/.local/share/nvim/, this is to keep it hidden from the user's folders and to conform it to NvChad.

First, clone the repository in the Neovim shared folder:

cd ~/.local/share/nvim/
git clone https://github.com/ambaradan/vale-styles.git

The repository contains a correctly configured .vale.ini file that will replace the one that you installed before. The initialization that follows provides integration of custom dictionaries for Rocky documentation. These dictionaries can be fully customized to include your own words.

StylesPath = ~/.local/share/nvim/vale-styles

Vocab = rockydocs, terminology

MinAlertLevel = suggestion

Packages = RedHat, alex

[*]
BasedOnStyles = Vale, RedHat, alex

copy the file to your home directory:

cp ~/.local/share/nvim/vale-styles/.vale.ini ~/.

and initialize the styles and dictionaries:

cd ~/
~/.local/share/nvim/mason/packages/vale/vale sync
 SUCCESS  Downloaded package 'RedHat'                                                                 
 SUCCESS  Downloaded package 'alex'                                                                    
Downloading packages [2/2] █████████████████████████████████████████████ 100% | 2s

The dictionaries will download to ~/.local/share/nvim/vale-styles/ and a .gitignore has is already there to prevent them from sharing with Git.

cat ~/.local/share/nvim/vale-styles/.gitignore
alex
RedHat

Dictionaries

Dictionaries are basically a folder containing two files, an accept.txt and a reject.txt. In accept.txt you enter the custom terms one per line. The terms are case-sensitive by default.

Vale allows some dedicated settings for terms:

(?i)linux
[Rr]ocky

The entry, (?i)linux, marks the entire pattern as case-insensitive, and the entry [Rr]ocky, provides two acceptable options.

Conclusion

Using vale in NvChad 2.0 with properly populated dictionaries will help when checking your document with vale. It will eliminate the screen clutter that comes from words that vale does not know to be correct by default.

vale-styles's People

Contributors

ambaradan avatar sspencerwire avatar

Watchers

 avatar

Forkers

sspencerwire

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.