Skip to content

Commit 563db76

Browse files
committed
fix lint
1 parent b66e2cf commit 563db76

File tree

5 files changed

+4
-8
lines changed

5 files changed

+4
-8
lines changed

README.md

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -31,4 +31,3 @@ Or if it is a commandline tool then you might put some example commands here:
3131
```
3232
python -m rtems_proxy --version
3333
```
34-

pyproject.toml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -87,7 +87,7 @@ commands =
8787
"""
8888

8989
[tool.ruff]
90-
ignore = [
90+
lint.ignore = [
9191
"B008", # Do not perform unnecessary work in __all__
9292
"C408", # Unnecessary collection call - e.g. list(...) instead of [...]
9393
"E501", # Line too long, should be fixed by black.

src/rtems_proxy/__main__.py

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,4 @@
11
from pathlib import Path
2-
from typing import Optional
32

43
import typer
54
from jinja2 import Template
@@ -23,7 +22,7 @@ def version_callback(value: bool):
2322

2423
@cli.callback()
2524
def main(
26-
version: Optional[bool] = typer.Option(
25+
version: bool | None = typer.Option(
2726
None,
2827
"--version",
2928
callback=version_callback,

src/rtems_proxy/rsync.sh.jinja

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -28,4 +28,3 @@ done
2828
" > /tmp/rsync-background.sh
2929

3030
nohup bash /tmp/rsync-background.sh &> /tmp/rsync-background.log &
31-

src/rtems_proxy/utils.py

Lines changed: 2 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,12 +1,11 @@
11
import subprocess
2-
from typing import Union
32

43
import typer
54

65

76
def run_command(
87
command: str, interactive=True, error_OK=False, show=False
9-
) -> Union[str, bool]:
8+
) -> str | bool:
109
"""
1110
Run a command and return the output
1211
@@ -30,7 +29,7 @@ def run_command(
3029
error_out = p_result.stderr.decode()
3130

3231
if interactive:
33-
result: Union[str, bool] = p_result.returncode == 0
32+
result: str | bool = p_result.returncode == 0
3433
else:
3534
result = output + error_out
3635

0 commit comments

Comments
 (0)