Skip to content

Commit

Permalink
fix output status for packing with only fixed molecules.
Browse files Browse the repository at this point in the history
  • Loading branch information
lmiq committed Aug 14, 2024
1 parent 7ddbd65 commit d6cd4b7
Show file tree
Hide file tree
Showing 3 changed files with 13 additions and 2 deletions.
4 changes: 2 additions & 2 deletions app/packmol.f90
Original file line number Diff line number Diff line change
Expand Up @@ -678,13 +678,13 @@ program packmol
if(n.eq.0) then
call output(n,x, xyzout)
write(*,dash1_line)
write(*,*) ' There are only fixed molecules, therefore there is nothing to do. '
write(*,*) ' Success! There are only fixed molecules, therefore there is nothing to pack. '
write(*,*) ' The output file contains the fixed molecules in the desired positions. '
write(*,dash1_line)
write(*,*) ' Wrote output file: ', trim(adjustl(xyzout))
if ( crd ) write(*,*) ' ... and to CRD file: ', trim(adjustl(crdfile))
write(*,dash1_line)
stop exit_code_input_error
stop
end if

!
Expand Down
10 changes: 10 additions & 0 deletions testing/input_files/only_one_fixed.inp
Original file line number Diff line number Diff line change
@@ -0,0 +1,10 @@
#
# A single fixed water molecule
#
tolerance 2.0
filetype pdb
output output.pdb
structure ./structure_files/water.pdb
number 1
fixed 0. 0. 0. 45. 45. 45.
end structure
1 change: 1 addition & 0 deletions testing/test.sh
Original file line number Diff line number Diff line change
Expand Up @@ -18,6 +18,7 @@ julia runtests.jl ./input_files/water_box.inp \
./input_files/bilayer_pbc.inp \
./input_files/solvprotein_pbc.inp \
./input_files/spherical_pbc.inp \
./input_files/only_one_fixed.inp \

# check if output files are properly generated in a failed run
./test_failed.sh ./input_files/water_box_failed.inp packmol.log "FORCED"

0 comments on commit d6cd4b7

Please sign in to comment.