Skip to content
This repository has been archived by the owner on Jan 14, 2022. It is now read-only.

failed to generate install for cjbassi/gotop #70

Closed
caarlos0 opened this issue Apr 27, 2018 · 5 comments
Closed

failed to generate install for cjbassi/gotop #70

caarlos0 opened this issue Apr 27, 2018 · 5 comments

Comments

@caarlos0
Copy link
Member

   • reading https://raw.githubusercontent.com/cjbassi/gotop/master/.goreleaser.yml
   • loading environment variables
   • snapshoting              
   • releasing to GitHub      
   • project name             
   • creating archives        
   • building binaries        
   • creating Linux packages with fpm
   • creating Linux packages with nfpm
   • creating Linux packages with snapcraft
   • calculating checksums    
   • signing artifacts        
   • creating Docker images   
   • releasing to Artifactory 
   • creating homebrew formula
   • creating Scoop Manifest  
   ⨯ treewalker failed         error=unable generate archive name: name_template "{{ .Binary }}_{{ .Version }}_{{ .Os }}_{{ .Arch }}{{ if .Arm }}{{ .Arm }}{{ end }}" contains unknown conditional or ARM format.  Please file bug at https://github.com/goreleaser/godownloader
make: *** [build] Error 1
@client9
Copy link
Collaborator

client9 commented May 2, 2018

hmm

unable generate archive name: name_template
 "{{ .Binary }}_{{ .Version }}_{{ .Os }}_{{ .Arch }}{{ if .Arm }}{{ .Arm }}{{ end }}"
 contains unknown conditional or ARM format. 

I suspect .Arm but surprised

@caarlos0
Copy link
Member Author

caarlos0 commented May 2, 2018

yeah, I havent looked into it yet

@client9
Copy link
Collaborator

client9 commented May 2, 2018

Ah I see. Since it's bash, it can't process the name template, so we try and guess

        // armv6 is the default in the shell script
        // so do not need special template condition for ARM
        armversion := "{{ .Arch }}{{ if .Arm }}v{{ .Arm }}{{ end }}"
        target = strings.Replace(target, armversion, "{{ .Arch }}", -1)

        // otherwise if it contains a conditional, we can't (easily)
        // translate that to bash.  Ask for bug report.
        if strings.Contains(target, "{{ if") || strings.Contains(target, "{{if") || strings.
Contains(target, "{{ .Arm") || strings.Contains(target, "{{.Arm") {
                return "", fmt.Errorf("name_template %q contains unknown conditional or ARM 
format.  Please file bug at https://github.com/goreleaser/godownloader", target)
        }

Easy enough to add this case with out the v.

client9 pushed a commit that referenced this issue May 2, 2018
@github-actions
Copy link

github-actions bot commented Oct 5, 2019

Stale issue message

@github-actions
Copy link

github-actions bot commented Dec 5, 2019

This issue seems be stale, will auto-close soon.

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Projects
None yet
Development

No branches or pull requests

2 participants