Skip to content
This repository has been archived by the owner on Jan 30, 2023. It is now read-only.

Commit

Permalink
bootstrap-conda: Also generate pip: lines
Browse files Browse the repository at this point in the history
  • Loading branch information
Matthias Koeppe committed May 16, 2022
1 parent e28f6d9 commit d2b8c4e
Showing 1 changed file with 18 additions and 0 deletions.
18 changes: 18 additions & 0 deletions bootstrap-conda
Original file line number Diff line number Diff line change
Expand Up @@ -95,3 +95,21 @@ echo >&2 $0:$LINENO: generating conda environment files
echo " - $pkg"
done
) > src/environment-optional.yml
(
echo >&4 " - pip:"
echo >&5 " - pip:"
for PKG_BASE in $(sage-package list --has-file requirements.txt --no-file distros/conda.txt); do
PKG_SCRIPTS=build/pkgs/$PKG_BASE
SYSTEM_PACKAGES_FILE=$PKG_SCRIPTS/requirements.txt
PKG_TYPE=$(cat $PKG_SCRIPTS/type)
if [ -n "PKG_SYSTEM_PACKAGES" ]; then
case "$PKG_BASE:$PKG_TYPE" in
$DEVELOP_SPKG_PATTERN:*) FD=4;;
*) FD=5;;
esac
${STRIP_COMMENTS} $SYSTEM_PACKAGES_FILE | while read -r line; do
[ -n "$line" ] && echo >&$FD " - $line"
done
fi
done
) 4>> src/environment-dev.yml 5>> src/environment-optional.yml

0 comments on commit d2b8c4e

Please sign in to comment.