Remove dependencies on requirements files and generate when needed

This commit is contained in:
Veronica Berglyd Olsen
2025-10-22 21:11:20 +02:00
parent 0b79bcd4b4
commit 06cb128876
7 changed files with 93 additions and 50 deletions
+2 -1
View File
@@ -1,7 +1,7 @@
#! /bin/bash
if [[ -z "$1" || -z "$2" || -z "$3" ]]; then
echo "Not enouch input arguments"
echo "Not enough input arguments"
exit 1
fi
@@ -108,6 +108,7 @@ conda install -c conda-forge enchant hunspell-en --yes
# Install dependencies
echo "Installing Python dependencies ..."
python3 pkgutils.py gen-req
pip install -r "$SRC_DIR/requirements.txt"
# Leave conda env
+1 -21
View File
@@ -1,24 +1,11 @@
#!/bin/bash
set -e
ENVPATH=/tmp/nwBuild
if [ ! -f pkgutils.py ]; then
echo "Must be called from the root folder of the source"
exit 1
fi
echo ""
echo " Create Python Env"
echo "================================================================================"
echo ""
if [ ! -d $ENVPATH ]; then
python3 -m venv $ENVPATH
fi
source $ENVPATH/bin/activate
pip3 install -U build twine -r requirements.txt -r docs/requirements.txt
echo ""
echo " Building Dependencies"
echo "================================================================================"
@@ -30,7 +17,7 @@ echo ""
echo " Building Packages"
echo "================================================================================"
echo ""
python3 -m build
uv build
mkdir -pv dist_upload
cp -v dist/novelwriter-*.whl dist_upload/
cd dist_upload
@@ -38,13 +25,6 @@ FILE=$(ls -t | head -1)
shasum -a 256 $FILE | tee $FILE.sha256
cd ..
echo ""
echo " Checking Packages"
echo "================================================================================"
echo ""
twine check dist/*
deactivate
echo ""
echo " Done!"
echo "================================================================================"