github.com/sagernet/sing-box@v1.2.7/.goreleaser.yaml (about)

     1  project_name: sing-box
     2  builds:
     3    - id: main
     4      main: ./cmd/sing-box
     5      flags:
     6        - -v
     7        - -trimpath
     8      asmflags:
     9        - all=-trimpath={{.Env.GOPATH}}
    10      gcflags:
    11        - all=-trimpath={{.Env.GOPATH}}
    12      ldflags:
    13        - -X github.com/sagernet/sing-box/constant.Version={{ .Version }} -s -w -buildid=
    14      tags:
    15        - with_gvisor
    16        - with_quic
    17        - with_wireguard
    18        - with_utls
    19        - with_reality_server
    20        - with_clash_api
    21      env:
    22        - CGO_ENABLED=0
    23      targets:
    24        - linux_amd64_v1
    25        - linux_amd64_v3
    26        - linux_arm64
    27        - linux_arm_7
    28        - linux_s390x
    29        - windows_amd64_v1
    30        - windows_amd64_v3
    31        - windows_386
    32        - windows_arm64
    33        - darwin_amd64_v1
    34        - darwin_amd64_v3
    35        - darwin_arm64
    36      mod_timestamp: '{{ .CommitTimestamp }}'
    37    - id: android
    38      main: ./cmd/sing-box
    39      flags:
    40        - -v
    41        - -trimpath
    42      asmflags:
    43        - all=-trimpath={{.Env.GOPATH}}
    44      gcflags:
    45        - all=-trimpath={{.Env.GOPATH}}
    46      ldflags:
    47        - -X github.com/sagernet/sing-box/constant.Version={{ .Version }} -s -w -buildid=
    48      tags:
    49        - with_gvisor
    50        - with_quic
    51        - with_wireguard
    52        - with_utls
    53        - with_clash_api
    54      env:
    55        - CGO_ENABLED=1
    56      overrides:
    57        - goos: android
    58          goarch: arm
    59          goarm: 7
    60          env:
    61            - CC=armv7a-linux-androideabi19-clang
    62            - CXX=armv7a-linux-androideabi19-clang++
    63        - goos: android
    64          goarch: arm64
    65          env:
    66            - CC=aarch64-linux-android21-clang
    67            - CXX=aarch64-linux-android21-clang++
    68        - goos: android
    69          goarch: 386
    70          env:
    71            - CC=i686-linux-android19-clang
    72            - CXX=i686-linux-android19-clang++
    73        - goos: android
    74          goarch: amd64
    75          goamd64: v1
    76          env:
    77            - CC=x86_64-linux-android21-clang
    78            - CXX=x86_64-linux-android21-clang++
    79      targets:
    80        - android_arm_7
    81        - android_arm64
    82        - android_386
    83        - android_amd64
    84      mod_timestamp: '{{ .CommitTimestamp }}'
    85  snapshot:
    86    name_template: "{{ .Version }}.{{ .ShortCommit }}"
    87  archives:
    88    - id: archive
    89      format: tar.gz
    90      format_overrides:
    91        - goos: windows
    92          format: zip
    93      wrap_in_directory: true
    94      files:
    95        - LICENSE
    96      name_template: '{{ .ProjectName }}-{{ .Version }}-{{ .Os }}-{{ .Arch }}{{ with .Arm }}v{{ . }}{{ end }}{{ with .Mips }}_{{ . }}{{ end }}{{ if not (eq .Amd64 "v1") }}{{ .Amd64 }}{{ end }}'
    97  nfpms:
    98    - id: package
    99      package_name: sing-box
   100      file_name_template: '{{ .ProjectName }}_{{ .Version }}_{{ .Os }}_{{ .Arch }}{{ with .Arm }}v{{ . }}{{ end }}{{ with .Mips }}_{{ . }}{{ end }}{{ if not (eq .Amd64 "v1") }}{{ .Amd64 }}{{ end }}'
   101      vendor: sagernet
   102      homepage: https://sing-box.sagernet.org/
   103      maintainer: nekohasekai <contact-git@sekai.icu>
   104      description: The universal proxy platform.
   105      license: GPLv3 or later
   106      formats:
   107        - deb
   108        - rpm
   109      priority: extra
   110      contents:
   111        - src: release/config/config.json
   112          dst: /etc/sing-box/config.json
   113          type: config
   114        - src: release/config/sing-box.service
   115          dst: /etc/systemd/system/sing-box.service
   116        - src: release/config/sing-box@.service
   117          dst: /etc/systemd/system/sing-box@.service
   118        - src: LICENSE
   119          dst: /usr/share/licenses/sing-box/LICENSE
   120  source:
   121    enabled: false
   122    name_template: '{{ .ProjectName }}-{{ .Version }}.source'
   123    prefix_template: '{{ .ProjectName }}-{{ .Version }}/'
   124  checksum:
   125    disable: true
   126    name_template: '{{ .ProjectName }}-{{ .Version }}.checksum'
   127  signs:
   128    - artifacts: checksum
   129  release:
   130    github:
   131      owner: SagerNet
   132      name: sing-box
   133    name_template: '{{ if .IsSnapshot }}{{ nightly }}{{ else }}{{ .Version }}{{ end }}'
   134    draft: true
   135    mode: replace