New: kill process function
This commit is contained in:
parent
8e1e14217a
commit
893250d35f
@ -11,6 +11,7 @@ anisotropy-help()
|
||||
echo " clean Clean project directory via git (.gitignore)."
|
||||
echo " init Activate environment and install dependencies."
|
||||
echo " run Start calculations and etc."
|
||||
echo " kill Kill current process by pid"
|
||||
echo " help Show help for commands."
|
||||
echo ""
|
||||
echo "Options:"
|
||||
@ -35,10 +36,19 @@ case $1 in
|
||||
run)
|
||||
source ${OPENFOAM}
|
||||
source env/bin/activate
|
||||
|
||||
mkdir ${DIR}/build && echo $$ >${DIR}/build/anisotropy.pid
|
||||
|
||||
python ${DIR}/anisotropy/anisotropy.py ${@:2}
|
||||
deactivate
|
||||
;;
|
||||
|
||||
kill)
|
||||
pid="${DIR}/build/anisotropy.pid"
|
||||
kill -9 $(cat $pid)
|
||||
rm $pid
|
||||
;;
|
||||
|
||||
help)
|
||||
anisotropy-help
|
||||
exit 1
|
||||
|
@ -12,7 +12,7 @@ format = "%(levelname)s: %(message)s"
|
||||
|
||||
[base]
|
||||
simple = true
|
||||
bodyCentered = false
|
||||
bodyCentered = true
|
||||
faceCentered = true
|
||||
|
||||
###
|
||||
@ -30,7 +30,7 @@ directions = [
|
||||
fillet = true
|
||||
|
||||
[simple.mesh]
|
||||
fineness = 3
|
||||
fineness = 1
|
||||
minSize = 0.01
|
||||
maxSize = 0.1
|
||||
growthRate = 0.5
|
||||
@ -65,7 +65,7 @@ directions = [
|
||||
fillet = true
|
||||
|
||||
[bodyCentered.mesh]
|
||||
fineness = 2
|
||||
fineness = 1
|
||||
minSize = 0.005
|
||||
maxSize = 0.05
|
||||
growthRate = 0.5
|
||||
@ -100,7 +100,7 @@ directions = [
|
||||
fillet = true
|
||||
|
||||
[faceCentered.mesh]
|
||||
fineness = 2
|
||||
fineness = 1
|
||||
minSize = 0.005
|
||||
maxSize = 0.05
|
||||
growthRate = 0.5
|
||||
|
Loading…
Reference in New Issue
Block a user