diff --git a/.github/styles/config/vocabularies/riscv-vocab/accept.txt b/.github/styles/config/vocabularies/riscv-vocab/accept.txt new file mode 100644 index 0000000..f45b70f --- /dev/null +++ b/.github/styles/config/vocabularies/riscv-vocab/accept.txt @@ -0,0 +1 @@ +pseudoinstruction \ No newline at end of file diff --git a/.github/styles/config/vocabularies/riscv-vocab/reject.txt b/.github/styles/config/vocabularies/riscv-vocab/reject.txt new file mode 100644 index 0000000..724181e --- /dev/null +++ b/.github/styles/config/vocabularies/riscv-vocab/reject.txt @@ -0,0 +1 @@ +pseudo-instruction \ No newline at end of file diff --git a/.github/styles/riscv/CapitalizeCSR.yml b/.github/styles/riscv/CapitalizeCSR.yml new file mode 100644 index 0000000..6e570b1 --- /dev/null +++ b/.github/styles/riscv/CapitalizeCSR.yml @@ -0,0 +1,7 @@ +--- +extends: existence +scope: raw +level: error +message: "The acronym CSR must always be capitalized." +raw: + - '\b(?!(CSR)\b)[cC][sS][rR]\b' \ No newline at end of file diff --git a/.github/styles/riscv/SpellingRV.yml b/.github/styles/riscv/SpellingRV.yml new file mode 100644 index 0000000..f5852d4 --- /dev/null +++ b/.github/styles/riscv/SpellingRV.yml @@ -0,0 +1,29 @@ +#file: noinspection IncorrectFormatting +--- +extends: spelling +level: warning +link: https://redhat-documentation.github.io/vale-at-red-hat/docs/main/reference-guide/spelling/ +message: "Verify the word '%s'. It is not in the American English spelling dictionary used by Vale." +# A "filter" is a case-sensitive regular expression specifying words to ignore during spell checking. +# Spelling rule applies to individual words +# There is no need to add plural forms (s?) to the regex +filters: + - "[mM]icroarchitecture" + - "[mM]icroarchitectural" + - "IEEE" + - "RISC" + - "RISC-V" + - "IEC" + - "[vV]irtualize" + - "virtualization" + - "SOAR" + - "SPUR" + - "[mM]icrocontroller" + - "FPGA" + - "[pP]seudocode" + - "[hH]alfword" + - "[dD]oubleword" + - "[bB]itwise" + - "[bB]oolean" + - "[sS]box" + - "[eE]ndian" diff --git a/.github/workflows/vale-using-reusable.yml b/.github/workflows/vale-using-reusable.yml index c2249bd..4abc26a 100644 --- a/.github/workflows/vale-using-reusable.yml +++ b/.github/workflows/vale-using-reusable.yml @@ -1,6 +1,9 @@ name: Linting with Vale using Reusable Config #on: [pull_request] -on: [push,pull_request] +on: + pull_request: + types: [opened,edited] + push: jobs: call-reusable-vale-workflow-in-riscv-vale-repo: diff --git a/.vale.ini b/.vale.ini index 5560813..4b580bd 100644 --- a/.vale.ini +++ b/.vale.ini @@ -1,27 +1,26 @@ -StylesPath = styles +StylesPath = .github/styles #MinAlertLevel = suggestion #IgnoredScopes = code, tt, img, url, a, body.id #SkippedScopes = script, style, pre, figure, code, tt, blockquote, listingblock, literalblock -#Packages = RedHat -Packages = https://github.com/riscv-admin/riscv-vale/releases/latest/download/riscv.zip -Packages = https://github.com/riscv-admin/riscv-vale/releases/latest/download/config.zip -#Vocab = riscv-vocab +Packages = AsciiDoc, https://github.com/riscv-admin/riscv-vale/releases/latest/download/riscv.zip, https://github.com/riscv-admin/riscv-vale/releases/latest/download/config.zip + +Vocab = riscv-vocab #[*.adoc] -#BasedOnStyles = Vale, RISCV-Vale, AsciiDoc +#BasedOnStyles = AsciiDoc, riscv #[*.md] #BasedOnStyles = Vale, RISCV-Vale, AsciiDoc -# Ignore code surrounded by backticks or plus sign, parameters defaults, URLs. +#Ignore code surrounded by backticks or plus sign, parameters defaults, URLs. #TokenIgnores = (\x60[^\n\x60]+\x60), ([^\n]+=[^\n]*), (\+[^\n]+\+), (http[^\n]+\[) # Match INI files. See: https://docs.errata.ai/vale/scoping #[*.ini] -#BasedOnStyles = Vale, RISCV-Vale +#BasedOnStyles = Vale # Disabling rules (NO) #RedHat.CaseSensitiveTerms = NO diff --git a/src/a_few_basics.adoc b/src/a_few_basics.adoc index 2742a71..689eedf 100644 --- a/src/a_few_basics.adoc +++ b/src/a_few_basics.adoc @@ -3,6 +3,10 @@ pseudoinstruction pseudo-instruction +CsR +cSR +CSR +csr AsciiDoc is fully documented, and its documentation is actively maintained. This document contains some information on AsciiDoc markup to get you started.