Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
20 changes: 20 additions & 0 deletions .editorconfig
Original file line number Diff line number Diff line change
@@ -0,0 +1,20 @@
# EditorConfig helps developers define and maintain consistent
# coding styles between different editors and IDEs
# editorconfig.org

root = true

[*]

# Change these settings to your own preference
indent_style = space
indent_size = 2

# We recommend you to keep these unchanged
end_of_line = lf
charset = utf-8
trim_trailing_whitespace = true
insert_final_newline = true

[Makefile]
indent_style = tab
1 change: 1 addition & 0 deletions .github/ISSUE_TEMPLATE/---bug-report.md
Original file line number Diff line number Diff line change
Expand Up @@ -20,6 +20,7 @@ assignees: ''
**Anything else we need to know?**:

**Environment**:

- External-DNS version (use `external-dns --version`):
- DNS provider:
- Others:
2 changes: 1 addition & 1 deletion .github/workflows/json-yaml-validate.yml
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
name: json-yaml-validate
name: json-yaml-validate
on:
push:
branches: [ master ]
Expand Down
22 changes: 10 additions & 12 deletions .github/workflows/lint.yaml
Original file line number Diff line number Diff line change
@@ -1,29 +1,27 @@
name: Lint

on:
push:
branches: [ master ]
pull_request:
branches: [ master ]

permissions:
contents: read # to fetch code (actions/checkout)
checks: write

jobs:

build:
lint:
name: Markdown, Go and OAS
runs-on: ubuntu-latest
permissions:
contents: read # to fetch code (actions/checkout)
checks: write # to create a new check based on the results (shogo82148/actions-goveralls)

name: Build
runs-on: ubuntu-latest
checks: write
steps:

- name: Check out code into the Go module directory
uses: actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683 # v4.2.2

- name: Lint markdown
uses: nosborn/[email protected]
with:
files: '.'
config_file: ".markdownlint.json"

- name: Set up Go 1.x
uses: actions/setup-go@v5
with:
Expand Down
13 changes: 13 additions & 0 deletions .markdownlint.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,13 @@
{
"default": true,
"MD010": { "code_blocks": false },
"MD013": { "line_length": "300" },
"MD033": false,
"MD036": false,
"MD024": false,
"MD041": false,
"MD029": false,
"MD034": false,
"MD038": false,
"MD046": false
}
27 changes: 27 additions & 0 deletions .pre-commit-config.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,27 @@
---
default_language_version:
node: system

repos:
- repo: https://github.com/pre-commit/pre-commit-hooks
rev: v4.5.0
hooks:
- id: check-added-large-files
- id: check-case-conflict
- id: check-executables-have-shebangs
- id: check-merge-conflict
- id: check-shebang-scripts-are-executable
- id: check-symlinks
- id: destroyed-symlinks
- id: end-of-file-fixer
- id: fix-byte-order-marker
- id: forbid-new-submodules
- id: mixed-line-ending
- id: trailing-whitespace

- repo: https://github.com/igorshubovych/markdownlint-cli
rev: v0.44.0
hooks:
- id: markdownlint

minimum_pre_commit_version: !!str 3.2
2 changes: 1 addition & 1 deletion CONTRIBUTING.md
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@

Welcome to Kubernetes. We are excited about the prospect of you joining our [community](https://git.k8s.io/community)! The Kubernetes community abides by the CNCF [code of conduct](code-of-conduct.md). Here is an excerpt:

_As contributors and maintainers of this project, and in the interest of fostering an open and welcoming community, we pledge to respect all people who contribute through reporting issues, posting feature requests, updating documentation, submitting pull requests or patches, and other activities._
_In the interest of fostering an open and welcoming community, we pledge to respect all people who contribute through reporting issues, posting feature requests, updating documentation, submitting pull requests or other activities._

## Getting Started

Expand Down
12 changes: 11 additions & 1 deletion Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -162,6 +162,16 @@ ko:
scripts/install-ko.sh

# generate-flags-documentation: Generate documentation (docs/flags.md)
.PHONE: generate-flags-documentation
.PHONY: generate-flags-documentation
generate-flags-documentation:
go run internal/gen/docs/flags/main.go

pre-commit-install: ## Install pre-commit hooks
@pre-commit install
@pre-commit gc

pre-commit-uninstall: ## Uninstall hooks
@pre-commit uninstall

pre-commit-validate: ## Validate files with pre-commit hooks
@pre-commit run --all-files
Loading
Loading