From 69bcd3c2ec74b1f2e73cbb6364dea5972a928b0f Mon Sep 17 00:00:00 2001 From: Kevin Broch Date: Tue, 9 Apr 2024 14:04:53 -0700 Subject: [PATCH] Change yaml formatting to prettier pre-commit hook This supports more file formats than just yaml (also md) and has a bigger community supporting it --- .github/workflows/build-pdf.yml | 4 ++-- .gitignore | 1 + .pre-commit-config.yaml | 7 +++---- CHANGELOG.md | 1 + CODE_OF_CONDUCT.md | 1 + CONTRIBUTING.md | 31 ++++++++++++++++--------------- GOVERNANCE.md | 1 + MAINTAINERS.md | 1 + dependencies/README.md | 2 +- 9 files changed, 27 insertions(+), 22 deletions(-) diff --git a/.github/workflows/build-pdf.yml b/.github/workflows/build-pdf.yml index a5752ac..ed5d88b 100644 --- a/.github/workflows/build-pdf.yml +++ b/.github/workflows/build-pdf.yml @@ -6,11 +6,11 @@ on: workflow_dispatch: inputs: version: - description: 'Release version, e.g. X.Y.Z:' + description: "Release version, e.g. X.Y.Z:" required: true type: string revision_mark: - description: 'Set revision mark as Draft, Release or Stable:' + description: "Set revision mark as Draft, Release or Stable:" required: true type: choice options: diff --git a/.gitignore b/.gitignore index d9b4f01..dc81cdb 100644 --- a/.gitignore +++ b/.gitignore @@ -1 +1,2 @@ /build/* +node_modules diff --git a/.pre-commit-config.yaml b/.pre-commit-config.yaml index 63fae1b..f68274e 100644 --- a/.pre-commit-config.yaml +++ b/.pre-commit-config.yaml @@ -19,8 +19,7 @@ repos: # Disallow other asciidoc extensions except .adoc files: .*\.(asciidoc|asc)$ - - repo: https://github.com/jumanjihouse/pre-commit-hook-yamlfmt - rev: 0.2.3 + - repo: https://github.com/pre-commit/mirrors-prettier + rev: "v4.0.0-alpha.8" hooks: - - id: yamlfmt - args: [--mapping, '2', --sequence, '4', --offset, '2'] + - id: prettier diff --git a/CHANGELOG.md b/CHANGELOG.md index c604eca..ca468a4 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -10,6 +10,7 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0 ## [Unreleased] ## [4.0.0] - 2004-01-27 + - Workflow improvements - Makefile refactoring - Readme updates diff --git a/CODE_OF_CONDUCT.md b/CODE_OF_CONDUCT.md index f0c2967..e9f5ea0 100644 --- a/CODE_OF_CONDUCT.md +++ b/CODE_OF_CONDUCT.md @@ -1,2 +1,3 @@ # RISC-V Code of Conduct + All RISC-V International projects are governed by the RISC-V Code of Conduct found at https://riscv.org/community/community-code-of-conduct/. diff --git a/CONTRIBUTING.md b/CONTRIBUTING.md index 1d98c72..16c8645 100644 --- a/CONTRIBUTING.md +++ b/CONTRIBUTING.md @@ -11,40 +11,41 @@ This project employs the Creative Commons Attribution 4.0 International license, Licensing defines the rights granted to you as an author by the copyright holder. It is essential for contributors to fully understand and accept these licensing rights. In some cases, the copyright holder may not be the contributor, such as when the contributor is working on behalf of a company. # Developer Certificate of Origin (DCO) + To uphold licensing criteria and demonstrate good faith, this project mandates adherence to the Developer Certificate of Origin (DCO) process. The DCO is an attestation appended to every contribution from each author. In the commit message of the contribution (explained in greater detail later in this document), the author adds a Signed-off-by statement, thereby accepting the DCO. When an author submits a patch, they affirm that they possess the right to submit the patch under the designated license. The DCO agreement is displayed below and at https://developercertificate.org. - Developer's Certificate of Origin 1.1 By making a contribution to this project, I certify that: (a) The contribution was created in whole or in part by me and I - have the right to submit it under the open source license - indicated in the file; or +have the right to submit it under the open source license +indicated in the file; or (b) The contribution is based upon previous work that, to the best - of my knowledge, is covered under an appropriate open source - license and I have the right under that license to submit that - work with modifications, whether created in whole or in part - by me, under the same open source license (unless I am - permitted to submit under a different license), as indicated - in the file; or +of my knowledge, is covered under an appropriate open source +license and I have the right under that license to submit that +work with modifications, whether created in whole or in part +by me, under the same open source license (unless I am +permitted to submit under a different license), as indicated +in the file; or (c) The contribution was provided directly to me by some other - person who certified (a), (b), or (c), and I have not modified - it. +person who certified (a), (b), or (c), and I have not modified +it. (d) I understand and agree that this project and the contribution - are public and that a record of the contribution (including all - personal information I submit with it, including my sign-off) is - maintained indefinitely and may be redistributed consistent with - this project or the open source license(s) involved. +are public and that a record of the contribution (including all +personal information I submit with it, including my sign-off) is +maintained indefinitely and may be redistributed consistent with +this project or the open source license(s) involved. # DCO Sign-Off Methods + The DCO necessitates the inclusion of a sign-off message in the following format for each commit within the pull request: Signed-off-by: Stephano Cetola diff --git a/GOVERNANCE.md b/GOVERNANCE.md index 651404c..df8ca25 100644 --- a/GOVERNANCE.md +++ b/GOVERNANCE.md @@ -1,4 +1,5 @@ # Governance + This project for the template specification is governed by the Documentation SIG. The group can be joined by RISC-V members at: https://lists.riscv.org/g/sig-documentation. diff --git a/MAINTAINERS.md b/MAINTAINERS.md index f218343..29f938d 100644 --- a/MAINTAINERS.md +++ b/MAINTAINERS.md @@ -1,4 +1,5 @@ # Maintainers + This project is maintained by the following people: - Bill Traynor ([wmat](https://github.com/wmat)) diff --git a/dependencies/README.md b/dependencies/README.md index f64a366..36e5f3c 100644 --- a/dependencies/README.md +++ b/dependencies/README.md @@ -1,2 +1,2 @@ -Dependencies for the build environment for various package managers. Used in +Dependencies for the build environment for various package managers. Used in `.github/workflows/`.