remove .pmbootstrap dir from shell nix

This commit is contained in:
MeexReay 2025-05-19 02:02:31 +03:00
parent 1c98fae513
commit 76aeecd439
2 changed files with 26 additions and 26 deletions

1
.gitignore vendored
View File

@ -1 +0,0 @@
.pmbootstrap/

View File

@ -11,38 +11,39 @@ pkgs.mkShell {
];
shellHook = ''
export PMWORK=$PWD/.pmbootstrap
export PMAPORTS=$PMWORK/cache_git/pmaports
mkdir -p $PMWORK
if [ ! -d $PMAPORTS ]; then
mkdir -p $PMWORK/cache_git
git clone https://gitlab.postmarketos.org/postmarketOS/pmaports.git $PMAPORTS
fi
# export PMWORK=$PWD/.pmbootstrap
# export PMAPORTS=$PMWORK/cache_git/pmaports
# mkdir -p $PMWORK
# if [ ! -d $PMAPORTS ]; then
# mkdir -p $PMWORK/cache_git
# git clone https://gitlab.postmarketos.org/postmarketOS/pmaports.git $PMAPORTS
# fi
source extract-paths.sh
if [ ! -L $PMAPORTS/device/testing/linux-xiaomi-angelican ]; then
ln -s $PWD/linux-xiaomi-angelican $PMAPORTS/device/testing
fi
if [ ! -L $PMAPORTS/device/testing/device-xiaomi-angelican ]; then
ln -s $PWD/device-xiaomi-angelican $PMAPORTS/device/testing
fi
if [ ! -f $PMWORK/pmbootstrap.conf ]; then
cat > $PMWORK/pmbootstrap.conf <<EOF
[pmbootstrap]
device = xiaomi-angelican
hostname = xiaomi-angelican
systemd = never
# if [ ! -f $PMWORK/pmbootstrap.conf ]; then
# cat > $PMWORK/pmbootstrap.conf <<EOF
# [pmbootstrap]
# device = xiaomi-angelican
# hostname = xiaomi-angelican
# systemd = never
[providers]
# [providers]
[mirrors]
EOF
fi
if [ ! -f $PMWORK/version ]; then
echo "8" > $PMWORK/version
fi
alias pmbootstrap="\
\pmbootstrap \
--aports $PMAPORTS \
--work $PMWORK \
"
# [mirrors]
# EOF
# fi
# if [ ! -f $PMWORK/version ]; then
# echo "8" > $PMWORK/version
# fi
# alias pmbootstrap="\
# \pmbootstrap \
# --aports $PMAPORTS \
# --work $PMWORK \
# "
'';
}