sandstorm-io/vagrant-spk

The 'vagrant-spk init' command should warn the user before clobbering changes made to an existing package

Opened this issue · 1 comments

If a user follows the workflow from the readme

git clone git://github.com/sandstorm-io/vagrant-spk
git clone git://github.com/sandstorm-io/php-app-to-package-for-sandstorm
export PATH=$(pwd)/vagrant-spk:$PATH
cd php-app-to-package-for-sandstorm
vagrant-spk setupvm lemp
vagrant-spk vm up
vagrant-spk init
# edit .sandstorm/sandstorm-pkgdef.capnp in your editor of choice
vagrant-spk dev
# visit http://local.sandstorm.io:6090 in a web browser
# log in as Alice, the admin account
# launch an instance of the example app, play around with it
# then, press Ctrl-C to stop the tracing vagrant-spk dev

and runs vagrant-spk init again at any point, it will clobber the changes they have made (to the sandstorm-pkgdef.capnp file, in particular). It would be courteous to warn the user about this before executing the command; ideally with a check to see if such a warning is appropriate.

This is very related to #258 but I agree this should be covered as well.