mirror of
https://github.com/gohugoio/hugo.git
synced 2024-11-29 02:32:11 -05:00
releaser: Adjustments
This commit is contained in:
parent
70d8ddcb60
commit
477684022f
3 changed files with 3 additions and 10 deletions
|
@ -29,7 +29,6 @@ const (
|
||||||
templateChanges = "templateChanges"
|
templateChanges = "templateChanges"
|
||||||
coreChanges = "coreChanges"
|
coreChanges = "coreChanges"
|
||||||
outChanges = "outChanges"
|
outChanges = "outChanges"
|
||||||
docsChanges = "docsChanges"
|
|
||||||
otherChanges = "otherChanges"
|
otherChanges = "otherChanges"
|
||||||
)
|
)
|
||||||
|
|
||||||
|
@ -91,8 +90,6 @@ func gitInfosToChangeLog(infos gitInfos) *changeLog {
|
||||||
category = notesChanges
|
category = notesChanges
|
||||||
} else if regexp.MustCompile("(?i)tpl|tplimpl:|layout").MatchString(los) {
|
} else if regexp.MustCompile("(?i)tpl|tplimpl:|layout").MatchString(los) {
|
||||||
category = templateChanges
|
category = templateChanges
|
||||||
} else if regexp.MustCompile("(?i)docs?:|documentation:").MatchString(los) {
|
|
||||||
category = docsChanges
|
|
||||||
} else if regexp.MustCompile("(?i)hugolib:").MatchString(los) {
|
} else if regexp.MustCompile("(?i)hugolib:").MatchString(los) {
|
||||||
category = coreChanges
|
category = coreChanges
|
||||||
} else if regexp.MustCompile("(?i)out(put)?:|media:|Output|Media").MatchString(los) {
|
} else if regexp.MustCompile("(?i)out(put)?:|media:|Output|Media").MatchString(los) {
|
||||||
|
@ -247,7 +244,7 @@ func getGitInfosBefore(ref, tag string, remote bool) (gitInfos, error) {
|
||||||
}
|
}
|
||||||
|
|
||||||
// Ignore autogenerated commits etc. in change log. This is a regexp.
|
// Ignore autogenerated commits etc. in change log. This is a regexp.
|
||||||
const ignoredCommits = "releaser?:|snapcraft:"
|
const ignoredCommits = "releaser?:|snapcraft:|Merge commit|Squashed|Revert"
|
||||||
|
|
||||||
func gitLogBefore(ref, tag string) (string, error) {
|
func gitLogBefore(ref, tag string) (string, error) {
|
||||||
var prevTag string
|
var prevTag string
|
||||||
|
|
|
@ -75,7 +75,6 @@ Hugo now has:
|
||||||
{{ $tmplChanges := index . "templateChanges" -}}
|
{{ $tmplChanges := index . "templateChanges" -}}
|
||||||
{{- $outChanges := index . "outChanges" -}}
|
{{- $outChanges := index . "outChanges" -}}
|
||||||
{{- $coreChanges := index . "coreChanges" -}}
|
{{- $coreChanges := index . "coreChanges" -}}
|
||||||
{{- $docsChanges := index . "docsChanges" -}}
|
|
||||||
{{- $otherChanges := index . "otherChanges" -}}
|
{{- $otherChanges := index . "otherChanges" -}}
|
||||||
{{- with $tmplChanges -}}
|
{{- with $tmplChanges -}}
|
||||||
### Templates
|
### Templates
|
||||||
|
@ -89,10 +88,6 @@ Hugo now has:
|
||||||
### Core
|
### Core
|
||||||
{{ template "change-section" . }}
|
{{ template "change-section" . }}
|
||||||
{{- end -}}
|
{{- end -}}
|
||||||
{{- with $docsChanges -}}
|
|
||||||
### Docs
|
|
||||||
{{ template "change-section" . }}
|
|
||||||
{{- end -}}
|
|
||||||
{{- with $otherChanges -}}
|
{{- with $otherChanges -}}
|
||||||
### Other
|
### Other
|
||||||
{{ template "change-section" . }}
|
{{ template "change-section" . }}
|
||||||
|
|
|
@ -24,6 +24,7 @@ import (
|
||||||
"os/exec"
|
"os/exec"
|
||||||
"path/filepath"
|
"path/filepath"
|
||||||
"regexp"
|
"regexp"
|
||||||
|
"strings"
|
||||||
|
|
||||||
"github.com/gohugoio/hugo/helpers"
|
"github.com/gohugoio/hugo/helpers"
|
||||||
)
|
)
|
||||||
|
@ -84,7 +85,7 @@ func New(version string, step int, skipPublish, try bool) *ReleaseHandler {
|
||||||
|
|
||||||
if try {
|
if try {
|
||||||
rh.git = func(args ...string) (string, error) {
|
rh.git = func(args ...string) (string, error) {
|
||||||
fmt.Println("git", args)
|
fmt.Println("git", strings.Join(args, " "))
|
||||||
return "", nil
|
return "", nil
|
||||||
}
|
}
|
||||||
} else {
|
} else {
|
||||||
|
|
Loading…
Reference in a new issue