Skip to content
Open
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
30 changes: 15 additions & 15 deletions Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -5,32 +5,32 @@ ifeq ($(OS), Windows_NT)
copy=copy
FixPath=$(subst /,\,$1)
cmdsep=&
IS_POETRY := $(shell pip freeze | find "poetry==")
PLATFORM=Windows
else
copy=cp
FixPath=$1
cmdsep=;
IS_POETRY := $(shell pip freeze | grep "poetry==")
PLATFORM=Linux
endif

.install-poetry:
ifndef IS_POETRY
@echo Installing Poetry...
pip install poetry
endif
POETRY ?= poetry

update:
$(POETRY) update

install:
$(POETRY) install

update: .install-poetry
poetry update
format:
$(POETRY) run isort $(wildcard *.py)
$(POETRY) run black --exclude .venv .
# $(POETRY) run flake8 $(wildcard *.py)

install: .install-poetry
poetry install
run:
$(POETRY) run python main.py

format: .install-poetry
poetry run isort $(wildcard *.py)
poetry run black --exclude .venv .
# poetry run flake8 $(wildcard *.py)
shell:
$(POETRY) shell

docker:
@docker build -t ocppsim .
Loading