Skip to content

Commit

Permalink
fix(--add): for some users the library didn't do a good job
Browse files Browse the repository at this point in the history
  • Loading branch information
sharpvik committed Jan 29, 2024
1 parent 721872e commit d4a93d8
Show file tree
Hide file tree
Showing 3 changed files with 2 additions and 21 deletions.
10 changes: 0 additions & 10 deletions .goreleaser.yaml
Original file line number Diff line number Diff line change
@@ -1,11 +1,6 @@
# This is an example .goreleaser.yml file with some sensible defaults.
# Make sure to check the documentation at https://goreleaser.com
before:
hooks:
# You may remove this if you don't use go modules.
- go mod tidy
# you may remove this if you don't need go generate
- go generate ./...

builds:
- goos:
Expand Down Expand Up @@ -57,8 +52,3 @@ changelog:
exclude:
- '^docs'
- '^test'

# The lines beneath this are called `modelines`. See `:help modeline`
# Feel free to remove those if you don't want/use them.
# yaml-language-server: $schema=https://goreleaser.com/static/schema.json
# vim: set ts=2 sw=2 tw=0 fo=cnqoj
2 changes: 1 addition & 1 deletion PKGBUILD
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
# Maintainer: Viktor A. Rozenko Voitenko <sharp.vik@gmail.com>
pkgname=sema
pkgver=3.0.0
pkgver=3.1.0
pkgrel=19
pkgdesc="Semantic commit tool"
arch=(x86_64)
Expand Down
11 changes: 1 addition & 10 deletions agent/agent.go
Original file line number Diff line number Diff line change
Expand Up @@ -55,16 +55,7 @@ func (a *Agent) Title() error {
}

func (a *Agent) Add() error {
status, err := a.workTree.Status()
if err != nil {
return fmt.Errorf("failed to obtain repository status: %s", err)
}
for file := range status {
if _, err = a.workTree.Add(file); err != nil {
return fmt.Errorf("failed to stage file: %s", err)
}
}
return nil
return try(exec.Command("git", "add", "."))
}

func (a *Agent) Commit() error {
Expand Down

0 comments on commit d4a93d8

Please sign in to comment.