Skip to content

Commit

Permalink
changes
Browse files Browse the repository at this point in the history
  • Loading branch information
tusharbana-ansys committed Jan 15, 2025
1 parent c0621c6 commit 4e1aa27
Show file tree
Hide file tree
Showing 2 changed files with 9 additions and 18 deletions.
20 changes: 7 additions & 13 deletions Makefile
Original file line number Diff line number Diff line change
@@ -1,40 +1,34 @@
# Simple makefile to simplify repetitive build env management tasks under posix
.PHONY: install tests doc build clean fresh-build
.PHONY: setup install tests doc build clean fresh-build

install:
setup:
@echo "Installing uv..."
pip install -U pip uv

install: setup
@echo "Installing..."
uv pip install -e .[freeze]
@echo "Installation complete."

tests:
@echo "Installing uv..."
pip install -U pip uv
tests: setup
@echo "Installing test dependencies..."
uv pip install -e .[tests]
@echo "Running tests..."
uv run pytest
@echo "Tests complete."

doc:
@echo "Installing uv..."
pip install -U pip uv
doc: setup
@echo "Installing documentation dependencies..."
uv pip install -e .[doc]
@echo "Building documentation..."
cd doc && make clean && make html && cd ..
@echo "Documentation complete."

build:
@echo "Installing uv..."
pip install -U pip uv
build: setup
@echo "Freezing using pyinstaller"
uv run pyinstaller frozen.spec

clean:
@echo "Installing uv..."
pip install -U pip uv
@echo "Cleaning up build files..."
rm -rf build dist

Expand Down
7 changes: 2 additions & 5 deletions make.bat
Original file line number Diff line number Diff line change
Expand Up @@ -11,24 +11,23 @@ if "%1" == "build" goto build
if "%1" == "clean" goto clean
if "%1" == "fresh-build" goto fresh-build

pip install -U pip uv

:install
Echo ^>^>^> Installing...
pip install -U pip uv
uv pip install -e .[freeze]
Echo ^>^>^> Installation complete.
goto end

:tests
Echo ^>^>^> Installing test dependencies...
pip install -U pip uv
uv pip install -e .[tests]
Echo ^>^>^> Running tests...
uv run pytest
goto end

:doc
Echo ^>^>^> Installing documentation dependencies...
pip install -U pip uv
uv pip install -e .[doc]
Echo ^>^>^> Building documentation...
chdir /d doc
Expand All @@ -40,7 +39,6 @@ goto end

:build
Echo ^>^>^> Freezing using pyinstaller
pip install -U pip uv
uv run pyinstaller frozen.spec
goto end

Expand All @@ -55,7 +53,6 @@ Echo ^>^>^> Cleaning up build files...
rmdir /s /q build > /NUL 2>&1
rmdir /s /q dist > /NUL 2>&1
Echo ^>^>^> Freezing using pyinstaller
pip install -U pip uv
uv run pyinstaller frozen.spec
goto end

Expand Down

0 comments on commit 4e1aa27

Please sign in to comment.