forked from toolshed/abra
		
	fix: bail out on unstage changes for plain --force
This commit is contained in:
		@ -169,6 +169,15 @@ func EnsureVersion(recipeName, version string) error {
 | 
			
		||||
func EnsureLatest(recipeName string) error {
 | 
			
		||||
	recipeDir := path.Join(config.ABRA_DIR, "apps", recipeName)
 | 
			
		||||
 | 
			
		||||
	isClean, err := gitPkg.IsClean(recipeName)
 | 
			
		||||
	if err != nil {
 | 
			
		||||
		return err
 | 
			
		||||
	}
 | 
			
		||||
 | 
			
		||||
	if !isClean {
 | 
			
		||||
		return fmt.Errorf("'%s' has locally unstaged changes", recipeName)
 | 
			
		||||
	}
 | 
			
		||||
 | 
			
		||||
	logrus.Debugf("attempting to open git repository in '%s'", recipeDir)
 | 
			
		||||
 | 
			
		||||
	repo, err := git.PlainOpen(recipeDir)
 | 
			
		||||
 | 
			
		||||
		Reference in New Issue
	
	Block a user