From 3e5a6f67b4fa4d04881af98f9f185a4f83f4b4d3 Mon Sep 17 00:00:00 2001 From: Davide Polonio Date: Tue, 27 Apr 2021 22:27:41 +0200 Subject: [PATCH] Add basic CI integration --- .drone.yml | 14 ++++++++++++++ .markdownlint-cli2.yaml | 39 +++++++++++++++++++++++++++++++++++++++ package.json | 19 +++++++++++++++++++ 3 files changed, 72 insertions(+) create mode 100644 .drone.yml create mode 100644 .markdownlint-cli2.yaml create mode 100644 package.json diff --git a/.drone.yml b/.drone.yml new file mode 100644 index 0000000..e5b528c --- /dev/null +++ b/.drone.yml @@ -0,0 +1,14 @@ +kind: pipeline +type: docker +name: default + +steps: + - name: Lint checks + image: node:14.16-alpine + commands: + - npm install + - npm run lint + - name: Hugo build + image: klakegg/hugo:0.82.1-ext-alpine-ci + commands: + - hugo diff --git a/.markdownlint-cli2.yaml b/.markdownlint-cli2.yaml new file mode 100644 index 0000000..8d46f62 --- /dev/null +++ b/.markdownlint-cli2.yaml @@ -0,0 +1,39 @@ +# Disable some built-in rules +config: + no-inline-html: false + MD013: + code_block_line_length: 120 + MD024: + allow_different_nesting: true +# no-trailing-spaces: false +# no-multiple-blanks: false + +# Include a custom rule package +#customRules: +# - markdownlint-rule-titlecase + +# Fix any fixable errors +fix: false + +# Define a custom front matter pattern +#frontMatter: "[^]*<\/head>" + +# Define glob expressions to ignore +ignores: + - "*.autogen.md" + +# Use a plugin to recognize math +#markdownItPlugins: +# - +# - "@iktakahiro/markdown-it-katex" + +# Disable inline config comments +noInlineConfig: true + +# Disable progress on stdout +noProgress: true + +# Use a specific formatter +outputFormatters: + - + - markdownlint-cli2-formatter-default diff --git a/package.json b/package.json new file mode 100644 index 0000000..d265bd5 --- /dev/null +++ b/package.json @@ -0,0 +1,19 @@ +{ + "name": "bitdispenser.dev", + "version": "0.0.1", + "description": "Personal Hugo website", + "main": "none.js", + "scripts": { + "lint": "markdownlint-cli2 content/posts/" + }, + "repository": { + "type": "git", + "url": "git+https://git.poldebra.me/polpetta/bitdispenser.dev.git" + }, + "author": "Polonio Davide ", + "license": "CC-BY-SA 4.0", + "dependencies": {}, + "devDependencies": { + "markdownlint-cli2": "0.0.10", + } +}