1
0

更新打包脚本

This commit is contained in:
Sense T
2025-03-01 10:35:26 +08:00
parent 1cc5ff724f
commit de60d7081a
2 changed files with 9 additions and 8 deletions

3
.gitignore vendored
View File

@@ -1,2 +1,3 @@
.direnv
test
test
result

View File

@@ -73,21 +73,21 @@ stdenv.mkDerivation rec {
#
mkdir -p $out${install_dir}
for i in $(ls -a $src); do
for i in $(ls $src); do
if [ $i == "$src/clientfiles" ]; then
continue
fi
cp -r $i $out${install_dir}
cp -rv $i $out${install_dir}
done
cp -rv $src/.iNode $out${install_dir}
for i in $(ls $out${install_dir}/*.ps); do
sed -i 's|#!/bin/sh|#!/usr/bin/env sh|' $i
chmod +x $i
done
sed -i 's|#!/bin/sh|#!/usr/bin/env sh|' $out${install_dir}/renew.ps
chmod +x $out${install_dir}/renew.ps
# enablecards.ps
head -n1 $out${install_dir}/enablecards.ps | tee $out${install_dir}/enablecards.ps
sed 's|#!/bin/sh|#!/usr/bin/env sh|' $out${install_dir}/enablecards.ps | head -n 1 | tee $out${install_dir}/enablecards.ps
chmod +x $out${install_dir}/enablecards.ps
#
rm -rf $out${install_dir}/clientfiles