mirror of
https://github.com/shadow1ng/fscan.git
synced 2025-05-07 03:11:30 +00:00
Merge pull request #121 from Dawnnnnnn/feature/add-upx-compress
feat(*): add `upx --best` for most elf
This commit is contained in:
commit
f71b4ab68f
37
.github/conf/.goreleaser.yml
vendored
37
.github/conf/.goreleaser.yml
vendored
@ -1,13 +1,10 @@
|
||||
# This is an example .goreleaser.yml file with some sane defaults.
|
||||
# Make sure to check the documentation at http://goreleaser.com
|
||||
before:
|
||||
hooks:
|
||||
# You may remove this if you don't use go modules.
|
||||
- go mod tidy
|
||||
# you may remove this if you don't need go generate
|
||||
- go generate ./...
|
||||
builds:
|
||||
- env:
|
||||
- id: "with-upx"
|
||||
env:
|
||||
- CGO_ENABLED=0
|
||||
goos:
|
||||
- linux
|
||||
@ -18,7 +15,6 @@ builds:
|
||||
- arm64
|
||||
- arm
|
||||
- "386"
|
||||
- mips64
|
||||
goarm:
|
||||
- "6"
|
||||
- "7"
|
||||
@ -29,6 +25,35 @@ builds:
|
||||
ignore:
|
||||
- goos: windows
|
||||
goarch: arm64
|
||||
- goos: windows
|
||||
goarch: arm
|
||||
- goos: linux
|
||||
goarch: mips64
|
||||
hooks:
|
||||
post: upx --best -f -q "{{ .Path }}"
|
||||
|
||||
# UnknownExecutableFormatException
|
||||
# CantPackException: can't pack new-exe
|
||||
- id: "without-upx"
|
||||
env:
|
||||
- CGO_ENABLED=0
|
||||
goos:
|
||||
- linux
|
||||
- windows
|
||||
goarch:
|
||||
- mips64
|
||||
- arm
|
||||
goarm:
|
||||
- "6"
|
||||
- "7"
|
||||
flags:
|
||||
- -trimpath
|
||||
ldflags:
|
||||
- -s -w -X main.version={{.Version}} -X main.commit={{.Commit}} -X main.date={{ .CommitDate }} -X main.builtBy=goreleaser
|
||||
ignore:
|
||||
- goos: linux
|
||||
goarch: arm
|
||||
|
||||
archives:
|
||||
- replacements:
|
||||
darwin: Darwin
|
||||
|
3
.github/workflows/release.yml
vendored
3
.github/workflows/release.yml
vendored
@ -11,6 +11,7 @@ permissions:
|
||||
jobs:
|
||||
goreleaser:
|
||||
runs-on: ubuntu-latest
|
||||
timeout-minutes: 60
|
||||
steps:
|
||||
-
|
||||
name: Checkout
|
||||
@ -28,7 +29,7 @@ jobs:
|
||||
with:
|
||||
distribution: goreleaser
|
||||
version: latest
|
||||
args: --rm-dist -f .github/conf/.goreleaser.yml
|
||||
args: -f .github/conf/.goreleaser.yml
|
||||
workdir: .
|
||||
env:
|
||||
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
|
||||
|
Loading…
x
Reference in New Issue
Block a user