Skip to content

Commit

Permalink
Add value workflow
Browse files Browse the repository at this point in the history
  • Loading branch information
jamesnetherton committed Jul 26, 2024
1 parent 17c6b1c commit 7331122
Show file tree
Hide file tree
Showing 65 changed files with 3,138 additions and 0 deletions.
33 changes: 33 additions & 0 deletions .github/workflows/docs-lint.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,33 @@
name: Documentation Linting
on:
pull_request:
paths:
- 'docs/**/*.adoc'
- '.github/workflows/vale.yml'

concurrency:
group: "workflow = ${{ github.workflow }}, ref = ${{ github.event.ref }}, pr = ${{ github.event.pull_request.id }}"
cancel-in-progress: ${{ github.event_name == 'pull_request' || github.repository != 'quarkusio/quarkus' }}

jobs:
vale:
name: Linting with Vale
runs-on: ubuntu-latest
permissions:
actions: read
checks: read
contents: read
pull-requests: read
steps:
- name: Checkout
uses: actions/checkout@v4
- name: Vale Linter
continue-on-error: true
uses: errata-ai/vale-action@reviewdog
with:
fail_on_error: false
vale_flags: "--no-exit --config=docs/.vale.ini"
filter_mode: diff_context
files: docs/modules/ROOT
env:
GITHUB_TOKEN: ${{secrets.GITHUB_TOKEN}}
32 changes: 32 additions & 0 deletions docs/.vale.ini
Original file line number Diff line number Diff line change
@@ -0,0 +1,32 @@
# Vale configuration file.
# For more information, see: https://docs.errata.ai/vale/config.

# The relative path to the folder containing linting rules (styles).
StylesPath = ./.vale/styles

# Minimum alert level
# -------------------
# The minimum alert level in the output (suggestion, warning, or error).
# If integrated into CI, builds fail by default on error-level alerts, unless you run Vale with the --no-exit flag

MinAlertLevel = suggestion

# IgnoredScopes specifies inline-level HTML tags to ignore.
# These tags may occur in an active scope (unlike SkippedScopes, skipped entirely) but their content still will not raise any alerts.
# Default: ignore `code` and `tt`.
IgnoredScopes = code, tt, img, url, a, body.id

# SkippedScopes specifies block-level HTML tags to ignore. Ignore any content in these scopes.
# Default: ignore `script`, `style`, `pre`, and `figure`.
# For AsciiDoc: by default, listingblock, and literalblock.
SkippedScopes = script, style, pre, figure, code, tt, blockquote, listingblock, literalblock

# Match AsciiDoc files. See: https://docs.errata.ai/vale/scoping
# Ignore files in a directory starting by `.`
# to avoid raising errors for `.vale/fixtures/*/testinvalid.adoc` files
[[!.]*.adoc]
# Styles to load, located in the `StylesPath` folder:
BasedOnStyles = Quarkus

# Ignore attributes definition, id statements
TokenIgnores = (:[^\n]+: [^\n]+), (\[id=[^\n]+)
5 changes: 5 additions & 0 deletions docs/.vale/fixtures/Quarkus/CaseSensitiveTerms/.vale.ini
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
; Vale configuration file to test the `CaseSensitiveTerms` rule
StylesPath = ../../../styles
MinAlertLevel = suggestion
[*.adoc]
Quarkus.CaseSensitiveTerms = YES
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
; Vale configuration file to test the `SentenceLength` rule
StylesPath = ../../../styles
MinAlertLevel = suggestion
[*.adoc]
Quarkus.RepeatedWords = YES
Original file line number Diff line number Diff line change
@@ -0,0 +1,2 @@
This is is a sentence with a repeated word.
This is a test test.
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
This is a sentence without a repeated word.
This is a sentence with two instances of a word.
Allow searches to be performed on type, contributor, contributor type, and others.
This is a Text. Text is nice.
This is a text. Text is nice.
Select the THE checkbox.
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
; Vale configuration file to test the `Spacing` rule
StylesPath = ../../../styles
MinAlertLevel = suggestion
[*.adoc]
Quarkus.Spacing = YES
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
this. That
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
this. That
270 changes: 270 additions & 0 deletions docs/.vale/fixtures/Quarkus/CaseSensitiveTerms/testinvalid.adoc
Original file line number Diff line number Diff line change
@@ -0,0 +1,270 @@
assertj
Assertj
Asciidoc
asciidoc
AsciiDoctor
asciidoctor
Bios
btrfs
burner
c group
capex
capEx
Capex
CD 1
Cds
CDS
CGroup
classic mode
configmap
configuration map
control key
csv
ctrl
cygmon
CygMon
CYGMON
Denial of Service
Denial-of-Service
Dev Mode
Dev mode
Dev Ops
Dev-Ops
devops
Devops
disk druid
Disk druid
diskdruid
dns
DVD burner
Exec Shield
exif
EXIF
F.A.Q
faq
Faq
fedora project
fortran
fqdn
Fqdn
gb
Gb
gbps
GBPS
GDBTK
gid
Gid
gimp
Gimp
git
GIT
gnome
Gnome
gnu
Gnu
gpl
Gpl
Graalvm
graalVM
GRPC
Grub
gtk
Gtk
HP Proliant
hyper-threading
hyperthreading
Hyperviser
HyperVisor
ia64
IA64
IBM z Systems
ignition config
Infiniband
Intel Tolapai
Iops
IOPs
Ip
IPSec
iSeries
iso
iso image
Istio Service Mesh
Itanium2
JBoss.org
jetbrains
Jetbrains
Junit
junit
jvm
Jvm
kernel-based virtual machine
knowledgebase
kickstart
kvm
lan
Lan
linux
LINUX
Microprofile
micro-profile
MicroSoft
mongoDB
Mongo DB
Mongodb
Mongo-db
MS
ms-dos
Ms-Dos
MS-dos
msdos
MSDOS
MSFT
mutual tls
Mutual tls
Mutual TLS
mySQL
MYSQL
node.js
node.JS
Node.JS
nodejs
Nodejs
Objective-C
openid connect
Openid Connect
Open InfiniBand
Operating Environment
Operating System
Operator hub
Operator Hub
operatorhub
Operatorhub
opEx
Opex
Opex
OPEX
OS
P-PC
podman
Pop-up
popup
posix
Posix
Postscript
Powershell
powershell
PPC
PPC64
ppp
Ppp
prom
Prom
proof key for code exchange
pSeries
q & a
Q & A
q&a
Q&A
qcow2
Qcow2
Qeth
QETH
ram
Ram
RAM-disk
ramdisk
RAMdisk
RAW
Red Boot
Red Hat Proxy
Red Hat satellite
Red Hat Satellite server
Red Hat Satellite Capsule server
Red Hat Network Satellite server
Redboot
resteasy
Resteasy
RESTEASY
rom
Rom
rpm
S-E Linux
s-record
s-Record
S-Record
S90
samba
SAMBA
SE Linux
SE-Linux
selinux
Shadow Man
Shadow passwords
Shadow utilities
ShadowMan
socks
software collection
Software collection
Spring boot
SR IOV
SREC
ssh
Ssh
SSL
Star Office
Staroffice
StartX
SU
Sys V
system d
system D
system D
System V
SystemD
Tolapai
ttl
uid
UltraSparc
ULTRASPARC
unix
unix Socket
UNIX-like
url
var
VI
vim
VIM
Virtual Console
Virtual Desktop Server Management
Virtual Network Interface Card
virtual-console
VisualStudio Code
VisualStudioCode
vlan
vLAN
vnic
VNIC
vnuma
VNUMA
vpn
VS Code
VSCode
VT
VT-i
wan
wca
Webauthn
webAuthn
WebAuthN
Websocket
websocket
web-UI
webUI
Window-Maker
WindowMaker
XDS
Xemacs
Xterm
yaml
Yaml is not a markup language.
Compared to yaml, JSON has way more curly braces.
Loading

0 comments on commit 7331122

Please sign in to comment.