* Added date to release body
* Added AVI to the scan task
* Fixed index out of bounds when generating sprites
This commit is contained in:
Stash Dev
2019-03-26 09:45:08 -07:00
parent 3b83371f84
commit e05d187a77
3 changed files with 6 additions and 1 deletions

View File

@@ -23,6 +23,7 @@ before_deploy:
- sh ./scripts/cross-compile.sh - sh ./scripts/cross-compile.sh
- git tag -f v0.0.0-alpha - git tag -f v0.0.0-alpha
- git push -f --tags - git push -f --tags
- export RELEASE_DATE=$(date +'%Y-%m-%d %H:%M:%S %Z')
deploy: deploy:
provider: releases provider: releases
api_key: api_key:
@@ -33,6 +34,7 @@ deploy:
- dist/stash-linux - dist/stash-linux
skip_cleanup: true skip_cleanup: true
overwrite: true overwrite: true
body: ${RELEASE_DATE}
on: on:
repo: stashapp/stash repo: stashapp/stash
branch: master branch: master

View File

@@ -90,6 +90,9 @@ func (g *SpriteGenerator) generateSpriteImage(encoder *ffmpeg.Encoder) error {
images = append(images, img) images = append(images, img)
} }
if len(images) == 0 {
return fmt.Errorf("images slice is empty, failed to generate sprite images for %s", g.Info.VideoFile.Path)
}
width := images[0].Bounds().Size().X width := images[0].Bounds().Size().X
height := images[0].Bounds().Size().Y height := images[0].Bounds().Size().Y
canvasWidth := width * g.Columns canvasWidth := width * g.Columns

View File

@@ -21,7 +21,7 @@ func (s *singleton) Scan() {
var results []string var results []string
for _, path := range config.GetStashPaths() { for _, path := range config.GetStashPaths() {
globPath := filepath.Join(path, "**/*.{zip,m4v,mp4,mov,wmv}") globPath := filepath.Join(path, "**/*.{zip,m4v,mp4,mov,wmv,avi}")
globResults, _ := doublestar.Glob(globPath) globResults, _ := doublestar.Glob(globPath)
results = append(results, globResults...) results = append(results, globResults...)
} }