Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Restore support for taskfile #237

Merged
merged 1 commit into from
Sep 3, 2024
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
1 change: 1 addition & 0 deletions .github/workflows/tox.yml
Original file line number Diff line number Diff line change
Expand Up @@ -93,6 +93,7 @@ jobs:
uses: actions/upload-artifact@v4
with:
name: logs-${{ matrix.name }}.zip
include-hidden-files: true
path: |
.tox/**/log/
.tox/**/.coverage*
Expand Down
3 changes: 3 additions & 0 deletions samples/integration/ansible-lint.txt
Original file line number Diff line number Diff line change
@@ -1,5 +1,7 @@
alerts
build
docs
drafts
eco
generate_docs
get-version
Expand All @@ -11,6 +13,7 @@ lint2
lower
pkg
pre
prs
py
py-devel
schemas
Expand Down
4 changes: 3 additions & 1 deletion samples/integration/cookiecutter.txt
Original file line number Diff line number Diff line change
@@ -1,3 +1,4 @@
alerts
build
clean-build
clean-coverage
Expand All @@ -8,14 +9,15 @@ clean-tox
coverage
docs
docs2
drafts
install
lint
lint2
lint23
prs
py310
py311
py312
py37
py38
py39
release
Expand Down
3 changes: 3 additions & 0 deletions samples/integration/flask-babel.txt
Original file line number Diff line number Diff line change
@@ -1,3 +1,6 @@
alerts
build
drafts
install
prs
uninstall
3 changes: 3 additions & 0 deletions samples/integration/nox.txt
Original file line number Diff line number Diff line change
@@ -1,10 +1,13 @@
alerts
build
conda_tests
cover
docs
drafts
install
lint
lint2
prs
test
tests(python='3.10', tox_version='<4')
tests(python='3.10', tox_version='latest')
Expand Down
3 changes: 3 additions & 0 deletions samples/integration/podman.txt
Original file line number Diff line number Diff line change
@@ -1,14 +1,17 @@
alerts
binaries
binaries2
binaries23
clean
clean-binaries
docs
drafts
help
install
lint
local-cross
podman-mac-helper
prs
rpm
rpm-install
test
3 changes: 3 additions & 0 deletions samples/integration/typeshed.txt
Original file line number Diff line number Diff line change
@@ -1,4 +1,7 @@
alerts
create_baseline_stubs
drafts
generate_proto_stubs
lint
prs
sync_tensorflow_protobuf_stubs
2 changes: 1 addition & 1 deletion src/mk/pre.py
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@
from rich.panel import Panel
from typer_config.decorators import use_yaml_config

CFG_FILE = "~/.config/mk/mk.yml"
CFG_FILE = os.environ.get("MK_CONFIG_FILE", "~/.config/mk/mk.yml")


class TyperApp(typer.Typer):
Expand Down
14 changes: 7 additions & 7 deletions src/mk/tools/taskfile.py
Original file line number Diff line number Diff line change
Expand Up @@ -21,13 +21,13 @@ def __init__(self, path=".") -> None:

def is_present(self, path: Path) -> bool:
valid_taskfiles = [
"Taskfile.yml"
"taskfile.yml"
"Taskfile.yaml"
"taskfile.yaml"
"Taskfile.dist.yml"
"taskfile.dist.yml"
"Taskfile.dist.yaml"
"Taskfile.yml",
"taskfile.yml",
"Taskfile.yaml",
"taskfile.yaml",
"Taskfile.dist.yml",
"taskfile.dist.yml",
"Taskfile.dist.yaml",
"taskfile.dist.yaml",
]

Expand Down
7 changes: 5 additions & 2 deletions tox.ini
Original file line number Diff line number Diff line change
Expand Up @@ -56,6 +56,8 @@ setenv =
COVERAGE_FILE = {env:COVERAGE_FILE:{envdir}/.coverage.{envname}}
COVERAGE_PROCESS_START={toxinidir}/pyproject.toml
FORCE_COLOR = 1
# To ensure test execution is not affected by user config.
MK_CONFIG_FILE = /dev/null
PIP_CONSTRAINT = {toxinidir}/.config/constraints.txt
PIP_DISABLE_PIP_VERSION_CHECK = 1
PRE_COMMIT_COLOR = always
Expand Down Expand Up @@ -125,8 +127,9 @@ commands =
[testenv:integration]
description = Run integrations tests
setenv =
ANSIBLE_NOCOWS=1
ANSIBLE_FORCE_COLOR=1
ANSIBLE_FORCE_COLOR = 1
ANSIBLE_NOCOWS = 1
MK_CONFIG_FILE = /dev/null
extras =
test
deps =
Expand Down
Loading