reworking database, init and add commands

This commit is contained in:
2020-07-02 15:00:30 -04:00
parent 6379c73e38
commit 5af55ed62e
15 changed files with 220 additions and 295 deletions

View File

@@ -1,13 +1,18 @@
package clientcmd
import (
"fmt"
clientconfig "github.com/deranjer/gvc/client/clientconfig"
"github.com/deranjer/gvc/common/engine"
)
// Commit commits the tracked files and changes to the repo
func Commit(conf *clientconfig.Gvcconfig, commitMessage string, m *engine.Manager) error {
m.BeginCommit(conf.CurrentBranch, commitMessage)
err := m.BeginCommit(conf.CurrentBranch, commitMessage)
if err != nil {
return fmt.Errorf("begin commit failed with message: %s", err)
}
return nil
}