-
Notifications
You must be signed in to change notification settings - Fork 1
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Cobra Lint will check itself to ensure that its code is correctly linted in its own standard. Signed-off-by: dev <[email protected]>
- Loading branch information
1 parent
7165c94
commit 7e62c65
Showing
1 changed file
with
81 additions
and
0 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,81 @@ | ||
name: Cobra Lint Checks | ||
|
||
on: [pull_request, push] | ||
|
||
jobs: | ||
setup: | ||
runs-on: ubuntu-latest | ||
steps: | ||
- name: Checkout Code | ||
uses: actions/checkout@v3 | ||
|
||
- name: Set up Python | ||
id: python-path | ||
uses: actions/setup-python@v4 | ||
with: | ||
python-version: '3.10.12' | ||
|
||
- name: Install Dependencies | ||
run: | | ||
pip install --upgrade pip | ||
pip install git+https://github.com/secomind/colint.git | ||
sort_libraries: | ||
runs-on: ubuntu-latest | ||
needs: setup | ||
|
||
steps: | ||
- name: Checkout Code | ||
uses: actions/checkout@v3 | ||
|
||
- name: Run Sort Libraries Check | ||
run: | | ||
colint sort-libraries ./ --check | ||
code_format: | ||
runs-on: ubuntu-latest | ||
needs: setup | ||
|
||
steps: | ||
- name: Checkout Code | ||
uses: actions/checkout@v3 | ||
|
||
- name: Run Code Format Check | ||
run: | | ||
colint code-format ./ --check | ||
grammar_check: | ||
runs-on: ubuntu-latest | ||
needs: setup | ||
|
||
steps: | ||
- name: Checkout Code | ||
uses: actions/checkout@v3 | ||
|
||
- name: Run Grammar Check | ||
run: | | ||
colint grammar-check ./ --check | ||
newline_fix: | ||
runs-on: ubuntu-latest | ||
needs: setup | ||
|
||
steps: | ||
- name: Checkout Code | ||
uses: actions/checkout@v3 | ||
|
||
- name: Run Newline Fix Check | ||
run: | | ||
colint newline-fix ./ --check | ||
clean_jupyter: | ||
runs-on: ubuntu-latest | ||
needs: setup | ||
|
||
steps: | ||
- name: Checkout Code | ||
uses: actions/checkout@v3 | ||
|
||
- name: Check Jupyter Notebooks Cleanliness | ||
run: | | ||
colint clean-jupyter ./ --check |