Skip to content

Commit

Permalink
Merge pull request #6 from oh2fih/lint-separate
Browse files Browse the repository at this point in the history
Separate workflows for shell & python scripts
  • Loading branch information
oh2fih authored Dec 26, 2023
2 parents 8ae39ff + 33a0f2b commit 63d7021
Show file tree
Hide file tree
Showing 3 changed files with 25 additions and 9 deletions.
18 changes: 18 additions & 0 deletions .github/workflows/python.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,18 @@
name: Black (Python)
on:
push:
pull_request:
branches:
- main

jobs:
black:
name: Black
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v3
- name: Check Black formatting for Python scripts
uses: psf/black@stable
with:
options: --check --verbose
src: .
13 changes: 4 additions & 9 deletions .github/workflows/lint.yml → .github/workflows/shell.yml
Original file line number Diff line number Diff line change
@@ -1,25 +1,20 @@
name: Lint
name: ShellCheck
on:
push:
pull_request:
branches:
- main

jobs:
lint:
name: Lint
shellcheck:
name: ShellCheck
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v3
- name: Run ShellCheck
- name: Run ShellCheck for shell scripts
uses: ludeeus/action-shellcheck@master
with:
severity: style
scandir: .
format: gcc
version: stable
- name: Black formatting (Python)
uses: psf/black@stable
with:
options: --check --verbose
src: .
3 changes: 3 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,9 @@

Miscellaneous scripts for different purposes. Mostly unrelated to each other.

![ShellCheck](https://github.com/oh2fih/Misc-Scripts/workflows/ShellCheck/badge.svg)
![Black (Python)](https://github.com/oh2fih/Misc-Scripts/workflows/Black%20(Python)/badge.svg)

| Category | Script & Language | Purpose & Usage |
|:---|:---|:---|
| Email | [`mail-prepender.sh`](bin/mail-prepender.sh) <br> Shell (bash) | Prepends (to stdin/stdout) email header strings given in as flags `i`, `I`, `a`, or `A`; after possible mbox `From` & `Return-Path` header lines. Intended as a limited `formail` replacement that ignores the nyanses of the flags and simply prepends the valid (RFC 5322, 2.2) non-empty headers keeping the other headers as is. Flags `x` & `X` are implemented. Any other flags are ignored. |
Expand Down

0 comments on commit 63d7021

Please sign in to comment.