mirror of
https://github.com/go-gitea/gitea.git
synced 2026-10-02 22:01:44 +02:00
#3076 detect invalid tag name git error
This commit is contained in:
1 parent
69dae1ec1c
commit
c912494609
11 files changed
+40
-13
No files matched your search
@@ -3,7 +3,7 @@ Gogs - Go Git Service [
|
||||
|
||||
##### Current tip version: 0.9.48 (see [Releases](https://github.com/gogits/gogs/releases) for binary versions)
|
||||
##### Current tip version: 0.9.49 (see [Releases](https://github.com/gogits/gogs/releases) for binary versions)
|
||||
|
||||
| Web | UI | Preview |
|
||||
|:-------------:|:-------:|:-------:|
|
||||
|
||||
@@ -725,6 +725,7 @@ release.deletion = Release Deletion
|
||||
release.deletion_desc = Deleting this release will delete the corresponding Git tag. Do you want to continue?
|
||||
release.deletion_success = Release has been deleted successfully!
|
||||
release.tag_name_already_exist = Release with this tag name already exists.
|
||||
release.tag_name_invalid = Tag name is not valid.
|
||||
release.downloads = Downloads
|
||||
|
||||
[org]
|
||||
|
||||
@@ -17,7 +17,7 @@ import (
|
||||
"github.com/gogits/gogs/modules/setting"
|
||||
)
|
||||
|
||||
const APP_VER = "0.9.48.0722"
|
||||
const APP_VER = "0.9.49.0723"
|
||||
|
||||
func init() {
|
||||
runtime.GOMAXPROCS(runtime.NumCPU())
|
||||
|
||||
+16
-3
@@ -387,7 +387,7 @@ func IsErrReleaseAlreadyExist(err error) bool {
|
||||
}
|
||||
|
||||
func (err ErrReleaseAlreadyExist) Error() string {
|
||||
return fmt.Sprintf("Release tag already exist [tag_name: %s]", err.TagName)
|
||||
return fmt.Sprintf("release tag already exist [tag_name: %s]", err.TagName)
|
||||
}
|
||||
|
||||
type ErrReleaseNotExist struct {
|
||||
@@ -401,7 +401,20 @@ func IsErrReleaseNotExist(err error) bool {
|
||||
}
|
||||
|
||||
func (err ErrReleaseNotExist) Error() string {
|
||||
return fmt.Sprintf("Release tag does not exist [id: %d, tag_name: %s]", err.ID, err.TagName)
|
||||
return fmt.Sprintf("release tag does not exist [id: %d, tag_name: %s]", err.ID, err.TagName)
|
||||
}
|
||||
|
||||
type ErrInvalidTagName struct {
|
||||
TagName string
|
||||
}
|
||||
|
||||
func IsErrInvalidTagName(err error) bool {
|
||||
_, ok := err.(ErrInvalidTagName)
|
||||
return ok
|
||||
}
|
||||
|
||||
func (err ErrInvalidTagName) Error() string {
|
||||
return fmt.Sprintf("release tag name is not valid [tag_name: %s]", err.TagName)
|
||||
}
|
||||
|
||||
// __________ .__
|
||||
@@ -421,7 +434,7 @@ func IsErrBranchNotExist(err error) bool {
|
||||
}
|
||||
|
||||
func (err ErrBranchNotExist) Error() string {
|
||||
return fmt.Sprintf("Branch does not exist [name: %s]", err.Name)
|
||||
return fmt.Sprintf("branch does not exist [name: %s]", err.Name)
|
||||
}
|
||||
|
||||
// __ __ ___. .__ __
|
||||
|
||||
+4
-1
@@ -67,9 +67,12 @@ func createTag(gitRepo *git.Repository, rel *Release) error {
|
||||
return fmt.Errorf("GetBranchCommit: %v", err)
|
||||
}
|
||||
|
||||
// Trim '--' prefix to prevent command line argument vulnerability
|
||||
// Trim '--' prefix to prevent command line argument vulnerability.
|
||||
rel.TagName = strings.TrimPrefix(rel.TagName, "--")
|
||||
if err = gitRepo.CreateTag(rel.TagName, commit.ID.String()); err != nil {
|
||||
if strings.Contains(err.Error(), "is not a valid tag name") {
|
||||
return ErrInvalidTagName{rel.TagName}
|
||||
}
|
||||
return err
|
||||
}
|
||||
} else {
|
||||
|
||||
@@ -4346,7 +4346,7 @@ func confLocaleLocale_deDeIni() (*asset, error) {
|
||||
return a, nil
|
||||
}
|
||||
|
||||
var _confLocaleLocale_enUsIni = []byte("\x1f\x8b\x08\x00\x00\x09\x6e\x88\x00\xff\xac\xbd\xeb\x72\xdc\x48\xae\x27\xfe\x9d\x4f\xc1\xf6\x84\xc3\x76\x84\x54\x1d\x3d\x7d\xfe\xff\xdd\xe8\x68\xbb\x57\x96\xda\x97\x73\x2c\x4b\x47\x92\xbb\x77\xb6\xc3\xc1\x66\x15\xa9\x2a\x8e\xab\xc8\x1a\x92\x25\x59\x33\x31\x6f\xb0\x0f\xb0\xcf\xb7\x4f\xb2\xc0\x0f\x40\x5e\x48\x96\x64\xf7\x1c\x7f\xb0\x58\x99\xc8\x1b\x12\x89\x04\x90\x48\x64\xbe\xdd\x66\x45\xd9\x2d\xd2\xe7\xe9\x51\xba\xcd\xab\x7a\x5d\x76\x5d\xda\x95\xeb\xeb\xc3\x55\xd3\xf5\x65\x91\xbe\xae\x7a\xfa\xdd\xde\x54\x8b\x32\x49\x56\xcd\xa6\x24\xd0\x37\xf4\x27\x29\xf2\x6e\x35\x6f\xf2\xb6\xa0\x84\x13\xfb\x4e\xca\xcf\xdb\x75\xd3\x32\xd0\xcf\xf2\x95\xac\xca\xf5\x96\xcb\xd0\x9f\xa4\xab\x96\x75\x56\xd5\xf4\xf3\x92\xbe\xd2\xb7\xb5\xa4\x34\xbb\xde\x92\xce\x76\xbd\xa4\xed\xb6\x96\xf4\x61\x9b\xb4\xe5\xb2\xa2\xde\xb4\x94\x74\xa1\x9f\xc9\x6d\x39\xef\xaa\x9e\x5b\xfa\x55\xbe\x92\x9b\xb2\xed\xaa\x86\x6b\xff\x45\xbe\x92\x6d\xbe\x64\x80\x73\xfa\x93\xf4\xe5\x66\xbb\xce\x51\xe0\x4a\x3f\x93\x75\x5e\x2f\x77\x02\xf3\x4e\x3f\x93\x45\x5b\x52\x56\x56\x97\xb7\x94\x7a\x8c\x1f\xb3\xd9\x2c\xd9\x11\x12\xb2\x6d\xdb\x5c\x57\xeb\x32\xcb\xeb\x22\xdb\xc8\x30\x3f\x50\x7a\xaa\xe9\x29\xa5\xa7\x9c\x8e\x21\x94\x05\x0d\x35\xcb\x3b\x1d\x07\xe1\x92\x46\x9e\x77\x09\xaa\xaa\xf3\x8d\x95\xe6\xcf\xa4\xdc\xe4\xd5\x9a\xb1\xc6\x7f\xa9\xdf\x5d\x77\xdb\x00\xb5\xe7\xfa\x49\x38\xc8\xfa\xbb\x6d\x09\x14\x1c\x5e\xd1\x57\xb2\xc8\xb7\xfd\x62\x95\x73\x37\xe5\x2b\x21\xa0\x6d\x43\xb8\x68\xda\x3b\xc0\xd9\x8f\xa4\x69\x97\x79\x5d\xfd\x3d\xef\x05\x3f\x67\xc1\xcf\x64\x53\xb5\x6d\xc3\xa8\x3d\xc5\x47\x42\x23\xcf\xb8\x1e\x4a\x79\x4f\x48\x08\x6a\xe1\x9c\x4d\xb5\x6c\x05\x8b\x9c\x79\x8a\x5f\x5c\x8b\xe4\x69\x4d\x92\xe5\x6a\xbb\x6e\xda\x4f\x9a\xfa\x8a\x3f\x07\x55\x52\xe7\x34\x37\xee\x57\x5e\xd3\x7c\x68\xee\x29\x7e\x44\x00\x5d\x92\x17\x1b\xc2\xf0\x36\xaf\x4b\x46\xdd\x11\xff\x22\x7c\xd1\xaf\x24\x5f\x2c\x9a\x5d\xdd\x67\x5d\xd9\xf7\x55\xbd\xe4\x39\x38\x92\xa4\xf4\x52\x93\x92\x20\xcf\xa5\xdd\x35\x3b\x37\xcb\x94\xfe\x17\xfa\x99\x9e\xcb\x4f\xc9\x0b\x0a\x21\xd3\x95\xa4\x26\xfb\xea\xa6\xea\xab\x52\x1a\xb3\x1f\xc9\x76\xb7\x5e\x13\x3e\xff\xb6\x2b\xbb\x9e\xb3\xce\xe9\x37\x61\x40\x7e\x27\x55\xd7\xed\x50\xe2\x2d\x3e\x12\x9a\xd4\x7a\x81\xe1\x1c\xe3\x23\x49\x7e\xab\xea\xae\xcf\xd7\xeb\x8f\x89\x7e\x30\xb0\x7c\x09\x9e\xfa\xaa\x47\x67\x35\x31\xbd\xec\xcb\x6d\xc7\x88\x4e\x5f\x55\x6d\xd7\x1f\xf6\x15\x91\xda\xc5\xae\x4e\x8a\x66\xf1\x89\x88\x98\x17\x24\x96\xd2\xdb\xeb\x94\xc6\xf4\x84\xc8\xb8\xdd\xd5\x35\x8d\x22\x7d\xdd\xd0\xc8\xa8\x99\xaa\x28\xd3\x13\x40\x1f\xa4\xdb\x75\x99\x77\x04\x52\xe6\x45\xfa\x63\x9e\xf6\x79\xbb\x2c\xfb\xe7\x8f\xb2\x39\x2d\x9e\x4f\x8f\xd2\x55\x5b\x5e\x3f\x7f\xf4\xb8\x7b\xf4\xe2\xf5\x8e\x8a\xad\xab\xba\xec\x7e\xfc\x36\x7f\x91\x2e\x72\xca\xa1\xb1\xde\xa5\xf3\xf2\x9a\xd7\x0a\xb5\x95\x12\x91\xd6\x4b\x5e\x27\x77\xfd\x8a\x1b\xa4\x09\xa3\x8f\x2e\xe5\x85\xfa\x4d\xc2\x58\xa2\x85\x9c\x15\x73\x63\x4a\xe8\x10\x92\x5b\xc2\xd2\xe9\xdd\xe5\x7f\xbe\x3b\x48\xcf\x89\x33\x2d\xdb\x12\xdf\xf4\x1f\x95\xf8\x3e\xa5\xd1\x5e\x55\x27\x2f\x67\x09\x95\x35\x84\x9c\xe4\x7d\x3e\xe7\xbe\xbb\x49\xe2\x4c\x59\x43\x2e\x0f\x2b\x89\x79\x1d\xf8\x5a\xd7\x63\x75\xea\xca\x9c\x5c\x87\x54\x87\x2e\x5e\x57\xc7\x7b\x5e\xc1\x94\xee\x30\x7b\x2e\x38\xa3\xaa\xd2\xb7\xef\xdf\x9f\x9d\xbc\x4c\xcb\x7a\x49\x98\x49\x6f\xab\x7e\x95\xee\xfa\xeb\xff\x9e\x2d\xcb\xba\x6c\xf3\x75\xb6\xa8\x18\x29\x2d\xd1\x55\x4a\x58\x92\x21\xce\x92\xae\x5b\x13\x83\x29\xb8\x95\xcb\xcb\x77\xe9\x29\x7d\x52\x67\xa8\x2c\x77\xa4\x5f\x25\xdd\xdf\xd6\x8c\x28\xd7\xe0\xd5\xaa\x4c\x41\xb3\x00\x6a\xae\x87\x78\x49\x0b\xed\xeb\x2c\xfd\x71\xde\xbe\x08\xfa\x97\xcf\xbb\x66\xbd\xeb\xb5\xe4\xed\xaa\xac\x31\x51\x44\x4a\x6d\x4f\xdc\xca\x78\xff\x2c\x29\xdb\x36\x23\xbe\xd9\xdf\xf1\xf4\x68\x5f\xf6\xb5\x22\x95\x11\x29\xd7\x4d\x4f\xd3\x9f\xa2\x9c\x54\x51\xd5\x37\xf9\xba\x2a\x68\x92\x3c\x22\xe3\xb2\x48\x2c\x1a\x9a\x6f\x2e\x4d\x14\xdd\xdc\x02\x45\xb4\xc0\x88\xad\xa7\x8f\x66\x8f\xc0\x67\x1f\x1d\x3e\x9a\x25\x75\x93\x09\x13\x60\x8e\x5c\x54\x5d\x3e\x27\xee\x2c\xbb\x45\x6b\xcc\xee\x2f\x4c\x77\xd2\x15\x85\x48\x23\x08\x9e\x13\xde\x81\xc0\xf8\x99\x28\x73\x62\xd3\xe0\x25\xca\x45\xc2\xb1\x1b\xcb\x71\x74\x21\x5c\xc7\x25\x8c\xc6\x9c\xd8\x44\x1b\x55\x1e\x6d\xb7\xeb\x6a\x21\x4d\xbf\x96\x3c\x4f\xa0\xbc\x1f\x2b\x52\x42\x38\x10\x98\xe5\x05\x64\x46\xbd\x66\xae\x94\x46\xec\x1d\xe5\x57\x25\xad\xb8\xd5\x6e\x29\x7b\xd2\xba\xd9\x15\xdf\x60\x73\xb0\x99\xf3\x2c\x38\xbd\x68\xa8\xc3\xa0\x2a\x07\xe0\x9b\x38\x22\x86\xc2\x22\x40\x5b\x6e\x9a\x9e\x11\xa7\xc5\x98\xcd\xdd\x56\x94\x49\x23\xed\xf2\x1b\xda\xdc\xfa\x46\x96\x72\x41\x4b\x75\xc1\x15\xcf\x12\x62\x2b\x99\x2e\x27\xe2\x3f\xb2\xa4\x2c\x2d\xa6\x5d\x40\x6d\x76\xb4\x0a\x57\x54\x19\x23\x9e\xe5\x10\xaa\x72\xaa\x9f\x18\x12\xd5\x03\xee\x40\x2b\xbe\xa1\x3d\x93\x27\xfa\x04\x1f\xfa\x3b\xac\x9f\x7a\x95\x5f\x5f\x53\xaf\x3a\x5a\x4d\x6f\xd2\xc5\xba\xa1\xa5\xf8\xe1\xe2\x5d\xc7\x0b\x6d\x95\x6d\x9b\x16\xf2\x07\x65\x9d\xd3\xa7\x4b\x0b\x10\xcd\x10\xf5\x6e\x33\xa7\x5f\xb7\xab\x6a\xb1\x12\xb4\x73\x09\x5e\x1f\x94\x4a\x4d\xec\x3a\x9a\xc2\x83\x94\x96\x16\x8d\x80\x5Line truncated
|
||||
var _confLocaleLocale_enUsIni = []byte("\x1f\x8b\x08\x00\x00\x09\x6e\x88\x00\xff\xac\xbd\xeb\x72\xdc\x48\xae\x27\xfe\x9d\x4f\xc1\xf6\x84\xc3\x76\x84\x54\x1d\x3d\x7d\xfe\xff\xdd\xe8\x68\xbb\x57\x96\xda\x97\x73\x2c\x4b\x47\x92\xbb\x77\xb6\xc3\xc1\x66\x15\xa9\x2a\x8e\xab\xc8\x1a\x92\x25\x59\x33\x31\x6f\xb0\x0f\xb0\xcf\xb7\x4f\xb2\xc0\x0f\x40\x5e\x48\x96\x64\xf7\x1c\x7f\xb0\x58\x99\xc8\x1b\x12\x89\x04\x90\x48\x64\xbe\xdd\x66\x45\xd9\x2d\xd2\xe7\xe9\x51\xba\xcd\xab\x7a\x5d\x76\x5d\xda\x95\xeb\xeb\xc3\x55\xd3\xf5\x65\x91\xbe\xae\x7a\xfa\xdd\xde\x54\x8b\x32\x49\x56\xcd\xa6\x24\xd0\x37\xf4\x27\x29\xf2\x6e\x35\x6f\xf2\xb6\xa0\x84\x13\xfb\x4e\xca\xcf\xdb\x75\xd3\x32\xd0\xcf\xf2\x95\xac\xca\xf5\x96\xcb\xd0\x9f\xa4\xab\x96\x75\x56\xd5\xf4\xf3\x92\xbe\xd2\xb7\xb5\xa4\x34\xbb\xde\x92\xce\x76\xbd\xa4\xed\xb6\x96\xf4\x61\x9b\xb4\xe5\xb2\xa2\xde\xb4\x94\x74\xa1\x9f\xc9\x6d\x39\xef\xaa\x9e\x5b\xfa\x55\xbe\x92\x9b\xb2\xed\xaa\x86\x6b\xff\x45\xbe\x92\x6d\xbe\x64\x80\x73\xfa\x93\xf4\xe5\x66\xbb\xce\x51\xe0\x4a\x3f\x93\x75\x5e\x2f\x77\x02\xf3\x4e\x3f\x93\x45\x5b\x52\x56\x56\x97\xb7\x94\x7a\x8c\x1f\xb3\xd9\x2c\xd9\x11\x12\xb2\x6d\xdb\x5c\x57\xeb\x32\xcb\xeb\x22\xdb\xc8\x30\x3f\x50\x7a\xaa\xe9\x29\xa5\xa7\x9c\x8e\x21\x94\x05\x0d\x35\xcb\x3b\x1d\x07\xe1\x92\x46\x9e\x77\x09\xaa\xaa\xf3\x8d\x95\xe6\xcf\xa4\xdc\xe4\xd5\x9a\xb1\xc6\x7f\xa9\xdf\x5d\x77\xdb\x00\xb5\xe7\xfa\x49\x38\xc8\xfa\xbb\x6d\x09\x14\x1c\x5e\xd1\x57\xb2\xc8\xb7\xfd\x62\x95\x73\x37\xe5\x2b\x21\xa0\x6d\x43\xb8\x68\xda\x3b\xc0\xd9\x8f\xa4\x69\x97\x79\x5d\xfd\x3d\xef\x05\x3f\x67\xc1\xcf\x64\x53\xb5\x6d\xc3\xa8\x3d\xc5\x47\x42\x23\xcf\xb8\x1e\x4a\x79\x4f\x48\x08\x6a\xe1\x9c\x4d\xb5\x6c\x05\x8b\x9c\x79\x8a\x5f\x5c\x8b\xe4\x69\x4d\x92\xe5\x6a\xbb\x6e\xda\x4f\x9a\xfa\x8a\x3f\x07\x55\x52\xe7\x34\x37\xee\x57\x5e\xd3\x7c\x68\xee\x29\x7e\x44\x00\x5d\x92\x17\x1b\xc2\xf0\x36\xaf\x4b\x46\xdd\x11\xff\x22\x7c\xd1\xaf\x24\x5f\x2c\x9a\x5d\xdd\x67\x5d\xd9\xf7\x55\xbd\xe4\x39\x38\x92\xa4\xf4\x52\x93\x92\x20\xcf\xa5\xdd\x35\x3b\x37\xcb\x94\xfe\x17\xfa\x99\x9e\xcb\x4f\xc9\x0b\x0a\x21\xd3\x95\xa4\x26\xfb\xea\xa6\xea\xab\x52\x1a\xb3\x1f\xc9\x76\xb7\x5e\x13\x3e\xff\xb6\x2b\xbb\x9e\xb3\xce\xe9\x37\x61\x40\x7e\x27\x55\xd7\xed\x50\xe2\x2d\x3e\x12\x9a\xd4\x7a\x81\xe1\x1c\xe3\x23\x49\x7e\xab\xea\xae\xcf\xd7\xeb\x8f\x89\x7e\x30\xb0\x7c\x09\x9e\xfa\xaa\x47\x67\x35\x31\xbd\xec\xcb\x6d\xc7\x88\x4e\x5f\x55\x6d\xd7\x1f\xf6\x15\x91\xda\xc5\xae\x4e\x8a\x66\xf1\x89\x88\x98\x17\x24\x96\xd2\xdb\xeb\x94\xc6\xf4\x84\xc8\xb8\xdd\xd5\x35\x8d\x22\x7d\xdd\xd0\xc8\xa8\x99\xaa\x28\xd3\x13\x40\x1f\xa4\xdb\x75\x99\x77\x04\x52\xe6\x45\xfa\x63\x9e\xf6\x79\xbb\x2c\xfb\xe7\x8f\xb2\x39\x2d\x9e\x4f\x8f\xd2\x55\x5b\x5e\x3f\x7f\xf4\xb8\x7b\xf4\xe2\xf5\x8e\x8a\xad\xab\xba\xec\x7e\xfc\x36\x7f\x91\x2e\x72\xca\xa1\xb1\xde\xa5\xf3\xf2\x9a\xd7\x0a\xb5\x95\x12\x91\xd6\x4b\x5e\x27\x77\xfd\x8a\x1b\xa4\x09\xa3\x8f\x2e\xe5\x85\xfa\x4d\xc2\x58\xa2\x85\x9c\x15\x73\x63\x4a\xe8\x10\x92\x5b\xc2\xd2\xe9\xdd\xe5\x7f\xbe\x3b\x48\xcf\x89\x33\x2d\xdb\x12\xdf\xf4\x1f\x95\xf8\x3e\xa5\xd1\x5e\x55\x27\x2f\x67\x09\x95\x35\x84\x9c\xe4\x7d\x3e\xe7\xbe\xbb\x49\xe2\x4c\x59\x43\x2e\x0f\x2b\x89\x79\x1d\xf8\x5a\xd7\x63\x75\xea\xca\x9c\x5c\x87\x54\x87\x2e\x5e\x57\xc7\x7b\x5e\xc1\x94\xee\x30\x7b\x2e\x38\xa3\xaa\xd2\xb7\xef\xdf\x9f\x9d\xbc\x4c\xcb\x7a\x49\x98\x49\x6f\xab\x7e\x95\xee\xfa\xeb\xff\x9e\x2d\xcb\xba\x6c\xf3\x75\xb6\xa8\x18\x29\x2d\xd1\x55\x4a\x58\x92\x21\xce\x92\xae\x5b\x13\x83\x29\xb8\x95\xcb\xcb\x77\xe9\x29\x7d\x52\x67\xa8\x2c\x77\xa4\x5f\x25\xdd\xdf\xd6\x8c\x28\xd7\xe0\xd5\xaa\x4c\x41\xb3\x00\x6a\xae\x87\x78\x49\x0b\xed\xeb\x2c\xfd\x71\xde\xbe\x08\xfa\x97\xcf\xbb\x66\xbd\xeb\xb5\xe4\xed\xaa\xac\x31\x51\x44\x4a\x6d\x4f\xdc\xca\x78\xff\x2c\x29\xdb\x36\x23\xbe\xd9\xdf\xf1\xf4\x68\x5f\xf6\xb5\x22\x95\x11\x29\xd7\x4d\x4f\xd3\x9f\xa2\x9c\x54\x51\xd5\x37\xf9\xba\x2a\x68\x92\x3c\x22\xe3\xb2\x48\x2c\x1a\x9a\x6f\x2e\x4d\x14\xdd\xdc\x02\x45\xb4\xc0\x88\xad\xa7\x8f\x66\x8f\xc0\x67\x1f\x1d\x3e\x9a\x25\x75\x93\x09\x13\x60\x8e\x5c\x54\x5d\x3e\x27\xee\x2c\xbb\x45\x6b\xcc\xee\x2f\x4c\x77\xd2\x15\x85\x48\x23\x08\x9e\x13\xde\x81\xc0\xf8\x99\x28\x73\x62\xd3\xe0\x25\xca\x45\xc2\xb1\x1b\xcb\x71\x74\x21\x5c\xc7\x25\x8c\xc6\x9c\xd8\x44\x1b\x55\x1e\x6d\xb7\xeb\x6a\x21\x4d\xbf\x96\x3c\x4f\xa0\xbc\x1f\x2b\x52\x42\x38\x10\x98\xe5\x05\x64\x46\xbd\x66\xae\x94\x46\xec\x1d\xe5\x57\x25\xad\xb8\xd5\x6e\x29\x7b\xd2\xba\xd9\x15\xdf\x60\x73\xb0\x99\xf3\x2c\x38\xbd\x68\xa8\xc3\xa0\x2a\x07\xe0\x9b\x38\x22\x86\xc2\x22\x40\x5b\x6e\x9a\x9e\x11\xa7\xc5\x98\xcd\xdd\x56\x94\x49\x23\xed\xf2\x1b\xda\xdc\xfa\x46\x96\x72\x41\x4b\x75\xc1\x15\xcf\x12\x62\x2b\x99\x2e\x27\xe2\x3f\xb2\xa4\x2c\x2d\xa6\x5d\x40\x6d\x76\xb4\x0a\x57\x54\x19\x23\x9e\xe5\x10\xaa\x72\xaa\x9f\x18\x12\xd5\x03\xee\x40\x2b\xbe\xa1\x3d\x93\x27\xfa\x04\x1f\xfa\x3b\xac\x9f\x7a\x95\x5f\x5f\x53\xaf\x3a\x5a\x4d\x6f\xd2\xc5\xba\xa1\xa5\xf8\xe1\xe2\x5d\xc7\x0b\x6d\x95\x6d\x9b\x16\xf2\x07\x65\x9d\xd3\xa7\x4b\x0b\x10\xcd\x10\xf5\x6e\x33\xa7\x5f\xb7\xab\x6a\xb1\x12\xb4\x73\x09\x5e\x1f\x94\x4a\x4d\xec\x3a\x9a\xc2\x83\x94\x96\x16\x8d\x80\x5Line truncated
|
||||
|
||||
func confLocaleLocale_enUsIniBytes() ([]byte, error) {
|
||||
return bindataRead(
|
||||
@@ -4361,7 +4361,7 @@ func confLocaleLocale_enUsIni() (*asset, error) {
|
||||
return nil, err
|
||||
}
|
||||
|
||||
info := bindataFileInfo{name: "conf/locale/locale_en-US.ini", size: 51479, mode: os.FileMode(420), modTime: time.Unix(1468718350, 0)}
|
||||
info := bindataFileInfo{name: "conf/locale/locale_en-US.ini", size: 51529, mode: os.FileMode(420), modTime: time.Unix(1469259799, 0)}
|
||||
a := &asset{bytes: bytes, info: info}
|
||||
return a, nil
|
||||
}
|
||||
|
||||
@@ -1968,6 +1968,9 @@ footer .ui.language .menu {
|
||||
.repository.new.release .target {
|
||||
min-width: 500px;
|
||||
}
|
||||
.repository.new.release .target #tag-name {
|
||||
margin-top: -4px;
|
||||
}
|
||||
.repository.new.release .target .at {
|
||||
margin-left: -5px;
|
||||
margin-right: 5px;
|
||||
|
||||
@@ -954,6 +954,10 @@
|
||||
.target {
|
||||
min-width: 500px;
|
||||
|
||||
#tag-name {
|
||||
margin-top: -4px;
|
||||
}
|
||||
|
||||
.at {
|
||||
margin-left: -5px;
|
||||
margin-right: 5px;
|
||||
|
||||
@@ -188,10 +188,13 @@ func NewReleasePost(ctx *context.Context, form auth.NewReleaseForm) {
|
||||
}
|
||||
|
||||
if err = models.CreateRelease(ctx.Repo.GitRepo, rel); err != nil {
|
||||
if models.IsErrReleaseAlreadyExist(err) {
|
||||
ctx.Data["Err_TagName"] = true
|
||||
ctx.Data["Err_TagName"] = true
|
||||
switch {
|
||||
case models.IsErrReleaseAlreadyExist(err):
|
||||
ctx.RenderWithErr(ctx.Tr("repo.release.tag_name_already_exist"), RELEASE_NEW, &form)
|
||||
} else {
|
||||
case models.IsErrInvalidTagName(err):
|
||||
ctx.RenderWithErr(ctx.Tr("repo.release.tag_name_invalid"), RELEASE_NEW, &form)
|
||||
default:
|
||||
ctx.Handle(500, "CreateRelease", err)
|
||||
}
|
||||
return
|
||||
|
||||
+1
-1
@@ -1 +1 @@
|
||||
0.9.48.0722
|
||||
0.9.49.0723
|
||||
@@ -19,7 +19,7 @@
|
||||
{{if .PageIsEditRelease}}
|
||||
<b>{{.tag_name}}</b><span class="at">@</span><strong>{{.tag_target}}</strong>
|
||||
{{else}}
|
||||
<input name="tag_name" value="{{.tag_name}}" placeholder="{{.i18n.Tr "repo.release.tag_name"}}" autofocus required>
|
||||
<input id="tag-name" name="tag_name" value="{{.tag_name}}" placeholder="{{.i18n.Tr "repo.release.tag_name"}}" autofocus required>
|
||||
<span class="at">@</span>
|
||||
<div class="ui selection dropdown">
|
||||
<input type="hidden" name="tag_target" value="{{.tag_target}}"/>
|
||||
|
||||
Reference in new issue
Block a user