Use safe-copy and acid-state to persist the state.
Proper cabal file.