mirror of
https://github.com/crazy-max/ghaction-upx.git
synced 2026-04-14 10:32:59 -06:00
Compare commits
62 Commits
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
e74668b8fe | ||
|
|
89f782418b | ||
|
|
91dad0f873 | ||
|
|
d021f9b324 | ||
|
|
d3616beaf8 | ||
|
|
1d4b28a26b | ||
|
|
45272fece1 | ||
|
|
5ab3223647 | ||
|
|
349653b2d1 | ||
|
|
2409e442cb | ||
|
|
d91472faac | ||
|
|
fd0d6460ff | ||
|
|
d19e416e3c | ||
|
|
85eb57b388 | ||
|
|
71ca9e0465 | ||
|
|
db3a3050f2 | ||
|
|
e85fa95304 | ||
|
|
36e0037c79 | ||
|
|
82c927c412 | ||
|
|
da2853e8b5 | ||
|
|
1d17dec12c | ||
|
|
c619ac25e7 | ||
|
|
b8d61b28e9 | ||
|
|
217a1bd1f9 | ||
|
|
f7e908e5b9 | ||
|
|
84033c6664 | ||
|
|
15e7963e05 | ||
|
|
754ef232a0 | ||
|
|
dbf74e34eb | ||
|
|
918a9dd3cd | ||
|
|
48ab6ba97a | ||
|
|
24851354e2 | ||
|
|
97d457995a | ||
|
|
aa4e82eb0f | ||
|
|
34f1525686 | ||
|
|
ceda108afe | ||
|
|
7fdadc3d8b | ||
|
|
bc2a7f0205 | ||
|
|
76aba877ac | ||
|
|
d43ef3b8fc | ||
|
|
663f81ff55 | ||
|
|
0ecb9bbbf3 | ||
|
|
d9dbb9c3ca | ||
|
|
2034dbc765 | ||
|
|
2b3459b026 | ||
|
|
76c12355bd | ||
|
|
c544706a19 | ||
|
|
c26e09cbb4 | ||
|
|
4c84b78119 | ||
|
|
66ae810f53 | ||
|
|
6f73f46fce | ||
|
|
99ca5b010b | ||
|
|
04c1b0be04 | ||
|
|
ce00daae27 | ||
|
|
7648f29744 | ||
|
|
7d4b8f5604 | ||
|
|
a584dfa158 | ||
|
|
001bed2881 | ||
|
|
4cd391c02d | ||
|
|
39152071b7 | ||
|
|
cd7336ce6f | ||
|
|
9a5a78f329 |
101
.github/ISSUE_TEMPLATE/bug.yml
vendored
Normal file
101
.github/ISSUE_TEMPLATE/bug.yml
vendored
Normal file
@@ -0,0 +1,101 @@
|
||||
# https://docs.github.com/en/communities/using-templates-to-encourage-useful-issues-and-pull-requests/syntax-for-githubs-form-schema
|
||||
name: Bug Report
|
||||
description: Report a bug
|
||||
labels:
|
||||
- kind/bug
|
||||
- status/triage
|
||||
|
||||
body:
|
||||
- type: checkboxes
|
||||
attributes:
|
||||
label: Support guidelines
|
||||
description: Please read the support guidelines before proceeding.
|
||||
options:
|
||||
- label: I've read the [support guidelines](https://github.com/crazy-max/ghaction-upx/blob/master/.github/SUPPORT.md)
|
||||
required: true
|
||||
|
||||
- type: checkboxes
|
||||
attributes:
|
||||
label: I've found a bug and checked that ...
|
||||
description: |
|
||||
Make sure that your request fulfills all of the following requirements. If one requirement cannot be satisfied, explain in detail why.
|
||||
options:
|
||||
- label: ... the documentation does not mention anything about my problem
|
||||
- label: ... there are no open or closed issues that are related to my problem
|
||||
|
||||
- type: textarea
|
||||
attributes:
|
||||
label: Description
|
||||
description: |
|
||||
Please provide a brief description of the bug in 1-2 sentences.
|
||||
validations:
|
||||
required: true
|
||||
|
||||
- type: textarea
|
||||
attributes:
|
||||
label: Expected behaviour
|
||||
description: |
|
||||
Please describe precisely what you'd expect to happen.
|
||||
validations:
|
||||
required: true
|
||||
|
||||
- type: textarea
|
||||
attributes:
|
||||
label: Actual behaviour
|
||||
description: |
|
||||
Please describe precisely what is actually happening.
|
||||
validations:
|
||||
required: true
|
||||
|
||||
- type: textarea
|
||||
attributes:
|
||||
label: Steps to reproduce
|
||||
description: |
|
||||
Please describe the steps to reproduce the bug.
|
||||
placeholder: |
|
||||
1. ...
|
||||
2. ...
|
||||
3. ...
|
||||
validations:
|
||||
required: true
|
||||
|
||||
- type: input
|
||||
attributes:
|
||||
label: Repository URL
|
||||
description: >
|
||||
Enter the URL of the repository where you are experiencing the
|
||||
issue. If your repository is private, provide a link to a minimal
|
||||
repository that reproduces the issue.
|
||||
validations:
|
||||
required: true
|
||||
|
||||
- type: input
|
||||
attributes:
|
||||
label: Workflow run URL
|
||||
description: >
|
||||
Enter the URL of the GitHub Action workflow run that fails (e.g.
|
||||
`https://github.com/<user>/<repo>/actions/runs/<id>`)
|
||||
|
||||
- type: textarea
|
||||
attributes:
|
||||
label: YAML workflow
|
||||
description: |
|
||||
Provide the YAML of the workflow that's causing the issue.
|
||||
Make sure to remove any sensitive information.
|
||||
render: yaml
|
||||
validations:
|
||||
required: true
|
||||
|
||||
- type: textarea
|
||||
attributes:
|
||||
label: Workflow logs
|
||||
description: >
|
||||
[Attach](https://docs.github.com/en/get-started/writing-on-github/working-with-advanced-formatting/attaching-files)
|
||||
the [log file of your workflow run](https://docs.github.com/en/actions/managing-workflow-runs/using-workflow-run-logs#downloading-logs)
|
||||
and make sure to remove any sensitive information.
|
||||
|
||||
- type: textarea
|
||||
attributes:
|
||||
label: Additional info
|
||||
description: |
|
||||
Please provide any additional information that seem useful.
|
||||
34
.github/ISSUE_TEMPLATE/bug_report.md
vendored
34
.github/ISSUE_TEMPLATE/bug_report.md
vendored
@@ -1,34 +0,0 @@
|
||||
---
|
||||
name: Bug report
|
||||
about: Create a report to help us improve
|
||||
---
|
||||
|
||||
### Behaviour
|
||||
|
||||
#### Steps to reproduce this issue
|
||||
|
||||
1.
|
||||
2.
|
||||
3.
|
||||
|
||||
#### Expected behaviour
|
||||
|
||||
> Tell me what should happen
|
||||
|
||||
#### Actual behaviour
|
||||
|
||||
> Tell me what happens instead
|
||||
|
||||
### Configuration
|
||||
|
||||
* Repository URL (if public):
|
||||
* Build URL (if public):
|
||||
|
||||
```yml
|
||||
# paste your YAML workflow file here and remove sensitive data
|
||||
```
|
||||
|
||||
### Logs
|
||||
|
||||
> Download the [log file of your build](https://docs.github.com/en/actions/managing-workflow-runs/using-workflow-run-logs#downloading-logs)
|
||||
> and [attach it](https://docs.github.com/en/github/managing-your-work-on-github/file-attachments-on-issues-and-pull-requests) to this issue.
|
||||
6
.github/ISSUE_TEMPLATE/config.yml
vendored
Normal file
6
.github/ISSUE_TEMPLATE/config.yml
vendored
Normal file
@@ -0,0 +1,6 @@
|
||||
# https://docs.github.com/en/communities/using-templates-to-encourage-useful-issues-and-pull-requests/configuring-issue-templates-for-your-repository#configuring-the-template-chooser
|
||||
blank_issues_enabled: true
|
||||
contact_links:
|
||||
- name: Questions and Discussions
|
||||
url: https://github.com/crazy-max/ghaction-upx/discussions/new
|
||||
about: Use Github Discussions to ask questions and/or open discussion topics.
|
||||
15
.github/ISSUE_TEMPLATE/feature.yml
vendored
Normal file
15
.github/ISSUE_TEMPLATE/feature.yml
vendored
Normal file
@@ -0,0 +1,15 @@
|
||||
# https://docs.github.com/en/communities/using-templates-to-encourage-useful-issues-and-pull-requests/syntax-for-githubs-form-schema
|
||||
name: Feature request
|
||||
description: Missing functionality? Come tell us about it!
|
||||
labels:
|
||||
- kind/enhancement
|
||||
- status/triage
|
||||
|
||||
body:
|
||||
- type: textarea
|
||||
id: description
|
||||
attributes:
|
||||
label: Description
|
||||
description: What is the feature you want to see?
|
||||
validations:
|
||||
required: true
|
||||
13
.github/dependabot.yml
vendored
13
.github/dependabot.yml
vendored
@@ -4,19 +4,16 @@ updates:
|
||||
directory: "/"
|
||||
schedule:
|
||||
interval: "daily"
|
||||
time: "06:00"
|
||||
timezone: "Europe/Paris"
|
||||
labels:
|
||||
- ":game_die: dependencies"
|
||||
- ":robot: bot"
|
||||
- "kind/dependencies"
|
||||
- "bot"
|
||||
- package-ecosystem: "npm"
|
||||
directory: "/"
|
||||
schedule:
|
||||
interval: "daily"
|
||||
time: "06:00"
|
||||
timezone: "Europe/Paris"
|
||||
versioning-strategy: "increase"
|
||||
allow:
|
||||
- dependency-type: "production"
|
||||
labels:
|
||||
- ":game_die: dependencies"
|
||||
- ":robot: bot"
|
||||
- "kind/dependencies"
|
||||
- "bot"
|
||||
|
||||
128
.github/labels.yml
vendored
128
.github/labels.yml
vendored
@@ -1,85 +1,69 @@
|
||||
## more info https://github.com/crazy-max/ghaction-github-labeler
|
||||
- # automerge
|
||||
name: ":bell: automerge"
|
||||
color: "8f4fbc"
|
||||
description: ""
|
||||
- # bot
|
||||
name: ":robot: bot"
|
||||
-
|
||||
name: "bot"
|
||||
color: "69cde9"
|
||||
description: ""
|
||||
- # bug
|
||||
name: ":bug: bug"
|
||||
color: "b60205"
|
||||
description: ""
|
||||
- # dependencies
|
||||
name: ":game_die: dependencies"
|
||||
color: "0366d6"
|
||||
description: ""
|
||||
- # documentation
|
||||
name: ":memo: documentation"
|
||||
color: "c5def5"
|
||||
description: ""
|
||||
- # duplicate
|
||||
name: ":busts_in_silhouette: duplicate"
|
||||
color: "cccccc"
|
||||
description: ""
|
||||
- # enhancement
|
||||
name: ":sparkles: enhancement"
|
||||
color: "0054ca"
|
||||
description: ""
|
||||
- # feature request
|
||||
name: ":bulb: feature request"
|
||||
color: "0e8a16"
|
||||
description: ""
|
||||
- # feedback
|
||||
name: ":mega: feedback"
|
||||
color: "03a9f4"
|
||||
description: ""
|
||||
- # future maybe
|
||||
name: ":rocket: future maybe"
|
||||
color: "fef2c0"
|
||||
description: ""
|
||||
- # good first issue
|
||||
name: ":hatching_chick: good first issue"
|
||||
-
|
||||
name: "good first issue"
|
||||
color: "7057ff"
|
||||
description: ""
|
||||
- # help wanted
|
||||
name: ":pray: help wanted"
|
||||
-
|
||||
name: "help wanted"
|
||||
color: "4caf50"
|
||||
description: ""
|
||||
- # invalid
|
||||
name: ":no_entry_sign: invalid"
|
||||
-
|
||||
name: "area/ci"
|
||||
color: "ed9ca9"
|
||||
description: ""
|
||||
-
|
||||
name: "kind/bug"
|
||||
color: "b60205"
|
||||
description: ""
|
||||
-
|
||||
name: "kind/dependencies"
|
||||
color: "0366d6"
|
||||
description: ""
|
||||
-
|
||||
name: "kind/docs"
|
||||
color: "c5def5"
|
||||
description: ""
|
||||
-
|
||||
name: "kind/duplicate"
|
||||
color: "cccccc"
|
||||
description: ""
|
||||
-
|
||||
name: "kind/enhancement"
|
||||
color: "0054ca"
|
||||
description: ""
|
||||
-
|
||||
name: "kind/invalid"
|
||||
color: "e6e6e6"
|
||||
description: ""
|
||||
- # investigate
|
||||
name: ":mag: investigate"
|
||||
color: "e6625b"
|
||||
description: ""
|
||||
- # needs more info
|
||||
name: ":thinking: needs more info"
|
||||
color: "795548"
|
||||
description: ""
|
||||
- # pinned
|
||||
name: ":pushpin: pinned"
|
||||
color: "28008e"
|
||||
description: ""
|
||||
- # question
|
||||
name: ":question: question"
|
||||
color: "3f51b5"
|
||||
description: ""
|
||||
- # sponsor
|
||||
name: ":sparkling_heart: sponsor"
|
||||
color: "fedbf0"
|
||||
description: ""
|
||||
- # stale
|
||||
name: ":skull: stale"
|
||||
color: "237da0"
|
||||
description: ""
|
||||
- # upstream
|
||||
name: ":eyes: upstream"
|
||||
-
|
||||
name: "kind/upstream"
|
||||
color: "fbca04"
|
||||
description: ""
|
||||
- # wontfix
|
||||
name: ":coffin: wontfix"
|
||||
-
|
||||
name: "kind/wontfix"
|
||||
color: "ffffff"
|
||||
description: ""
|
||||
-
|
||||
name: "status/automerge"
|
||||
color: "8f4fbc"
|
||||
description: ""
|
||||
-
|
||||
name: "status/needs-investigation"
|
||||
color: "e6625b"
|
||||
description: ""
|
||||
-
|
||||
name: "status/needs-more-info"
|
||||
color: "795548"
|
||||
description: ""
|
||||
-
|
||||
name: "status/stale"
|
||||
color: "237da0"
|
||||
description: ""
|
||||
-
|
||||
name: "status/triage"
|
||||
color: "dde4b7"
|
||||
description: ""
|
||||
|
||||
224
.github/upx-releases.json
vendored
Normal file
224
.github/upx-releases.json
vendored
Normal file
@@ -0,0 +1,224 @@
|
||||
{
|
||||
"latest": {
|
||||
"id": 115584145,
|
||||
"tag_name": "v4.1.0",
|
||||
"html_url": "https://github.com/upx/upx/releases/tag/v4.1.0",
|
||||
"assets": [
|
||||
"https://github.com/upx/upx/releases/download/v4.1.0/upx-4.1.0-amd64_linux.tar.xz",
|
||||
"https://github.com/upx/upx/releases/download/v4.1.0/upx-4.1.0-arm64_linux.tar.xz",
|
||||
"https://github.com/upx/upx/releases/download/v4.1.0/upx-4.1.0-arm_linux.tar.xz",
|
||||
"https://github.com/upx/upx/releases/download/v4.1.0/upx-4.1.0-armeb_linux.tar.xz",
|
||||
"https://github.com/upx/upx/releases/download/v4.1.0/upx-4.1.0-dos.zip",
|
||||
"https://github.com/upx/upx/releases/download/v4.1.0/upx-4.1.0-i386_linux.tar.xz",
|
||||
"https://github.com/upx/upx/releases/download/v4.1.0/upx-4.1.0-mips_linux.tar.xz",
|
||||
"https://github.com/upx/upx/releases/download/v4.1.0/upx-4.1.0-mipsel_linux.tar.xz",
|
||||
"https://github.com/upx/upx/releases/download/v4.1.0/upx-4.1.0-powerpc64le_linux.tar.xz",
|
||||
"https://github.com/upx/upx/releases/download/v4.1.0/upx-4.1.0-powerpc_linux.tar.xz",
|
||||
"https://github.com/upx/upx/releases/download/v4.1.0/upx-4.1.0-src.tar.xz",
|
||||
"https://github.com/upx/upx/releases/download/v4.1.0/upx-4.1.0-win32.zip",
|
||||
"https://github.com/upx/upx/releases/download/v4.1.0/upx-4.1.0-win64.zip"
|
||||
]
|
||||
},
|
||||
"v4.1.0": {
|
||||
"id": 115584145,
|
||||
"tag_name": "v4.1.0",
|
||||
"html_url": "https://github.com/upx/upx/releases/tag/v4.1.0",
|
||||
"assets": [
|
||||
"https://github.com/upx/upx/releases/download/v4.1.0/upx-4.1.0-amd64_linux.tar.xz",
|
||||
"https://github.com/upx/upx/releases/download/v4.1.0/upx-4.1.0-arm64_linux.tar.xz",
|
||||
"https://github.com/upx/upx/releases/download/v4.1.0/upx-4.1.0-arm_linux.tar.xz",
|
||||
"https://github.com/upx/upx/releases/download/v4.1.0/upx-4.1.0-armeb_linux.tar.xz",
|
||||
"https://github.com/upx/upx/releases/download/v4.1.0/upx-4.1.0-dos.zip",
|
||||
"https://github.com/upx/upx/releases/download/v4.1.0/upx-4.1.0-i386_linux.tar.xz",
|
||||
"https://github.com/upx/upx/releases/download/v4.1.0/upx-4.1.0-mips_linux.tar.xz",
|
||||
"https://github.com/upx/upx/releases/download/v4.1.0/upx-4.1.0-mipsel_linux.tar.xz",
|
||||
"https://github.com/upx/upx/releases/download/v4.1.0/upx-4.1.0-powerpc64le_linux.tar.xz",
|
||||
"https://github.com/upx/upx/releases/download/v4.1.0/upx-4.1.0-powerpc_linux.tar.xz",
|
||||
"https://github.com/upx/upx/releases/download/v4.1.0/upx-4.1.0-src.tar.xz",
|
||||
"https://github.com/upx/upx/releases/download/v4.1.0/upx-4.1.0-win32.zip",
|
||||
"https://github.com/upx/upx/releases/download/v4.1.0/upx-4.1.0-win64.zip"
|
||||
]
|
||||
},
|
||||
"v4.0.2": {
|
||||
"id": 90665948,
|
||||
"tag_name": "v4.0.2",
|
||||
"html_url": "https://github.com/upx/upx/releases/tag/v4.0.2",
|
||||
"assets": [
|
||||
"https://github.com/upx/upx/releases/download/v4.0.2/upx-4.0.2-amd64_linux.tar.xz",
|
||||
"https://github.com/upx/upx/releases/download/v4.0.2/upx-4.0.2-arm64_linux.tar.xz",
|
||||
"https://github.com/upx/upx/releases/download/v4.0.2/upx-4.0.2-arm_linux.tar.xz",
|
||||
"https://github.com/upx/upx/releases/download/v4.0.2/upx-4.0.2-armeb_linux.tar.xz",
|
||||
"https://github.com/upx/upx/releases/download/v4.0.2/upx-4.0.2-dos.zip",
|
||||
"https://github.com/upx/upx/releases/download/v4.0.2/upx-4.0.2-i386_linux.tar.xz",
|
||||
"https://github.com/upx/upx/releases/download/v4.0.2/upx-4.0.2-mips_linux.tar.xz",
|
||||
"https://github.com/upx/upx/releases/download/v4.0.2/upx-4.0.2-mipsel_linux.tar.xz",
|
||||
"https://github.com/upx/upx/releases/download/v4.0.2/upx-4.0.2-powerpc64le_linux.tar.xz",
|
||||
"https://github.com/upx/upx/releases/download/v4.0.2/upx-4.0.2-powerpc_linux.tar.xz",
|
||||
"https://github.com/upx/upx/releases/download/v4.0.2/upx-4.0.2-src.tar.xz",
|
||||
"https://github.com/upx/upx/releases/download/v4.0.2/upx-4.0.2-win32.zip",
|
||||
"https://github.com/upx/upx/releases/download/v4.0.2/upx-4.0.2-win64.zip"
|
||||
]
|
||||
},
|
||||
"v4.0.1": {
|
||||
"id": 83324543,
|
||||
"tag_name": "v4.0.1",
|
||||
"html_url": "https://github.com/upx/upx/releases/tag/v4.0.1",
|
||||
"assets": [
|
||||
"https://github.com/upx/upx/releases/download/v4.0.1/upx-4.0.1-amd64_linux.tar.xz",
|
||||
"https://github.com/upx/upx/releases/download/v4.0.1/upx-4.0.1-arm64_linux.tar.xz",
|
||||
"https://github.com/upx/upx/releases/download/v4.0.1/upx-4.0.1-arm_linux.tar.xz",
|
||||
"https://github.com/upx/upx/releases/download/v4.0.1/upx-4.0.1-armeb_linux.tar.xz",
|
||||
"https://github.com/upx/upx/releases/download/v4.0.1/upx-4.0.1-dos.zip",
|
||||
"https://github.com/upx/upx/releases/download/v4.0.1/upx-4.0.1-i386_linux.tar.xz",
|
||||
"https://github.com/upx/upx/releases/download/v4.0.1/upx-4.0.1-mips_linux.tar.xz",
|
||||
"https://github.com/upx/upx/releases/download/v4.0.1/upx-4.0.1-mipsel_linux.tar.xz",
|
||||
"https://github.com/upx/upx/releases/download/v4.0.1/upx-4.0.1-powerpc64le_linux.tar.xz",
|
||||
"https://github.com/upx/upx/releases/download/v4.0.1/upx-4.0.1-powerpc_linux.tar.xz",
|
||||
"https://github.com/upx/upx/releases/download/v4.0.1/upx-4.0.1-src.tar.xz",
|
||||
"https://github.com/upx/upx/releases/download/v4.0.1/upx-4.0.1-win32.zip",
|
||||
"https://github.com/upx/upx/releases/download/v4.0.1/upx-4.0.1-win64.zip"
|
||||
]
|
||||
},
|
||||
"v4.0.0": {
|
||||
"id": 81373677,
|
||||
"tag_name": "v4.0.0",
|
||||
"html_url": "https://github.com/upx/upx/releases/tag/v4.0.0",
|
||||
"assets": [
|
||||
"https://github.com/upx/upx/releases/download/v4.0.0/upx-4.0.0-amd64_linux.tar.xz",
|
||||
"https://github.com/upx/upx/releases/download/v4.0.0/upx-4.0.0-arm64_linux.tar.xz",
|
||||
"https://github.com/upx/upx/releases/download/v4.0.0/upx-4.0.0-arm_linux.tar.xz",
|
||||
"https://github.com/upx/upx/releases/download/v4.0.0/upx-4.0.0-armeb_linux.tar.xz",
|
||||
"https://github.com/upx/upx/releases/download/v4.0.0/upx-4.0.0-dos.zip",
|
||||
"https://github.com/upx/upx/releases/download/v4.0.0/upx-4.0.0-i386_linux.tar.xz",
|
||||
"https://github.com/upx/upx/releases/download/v4.0.0/upx-4.0.0-mips_linux.tar.xz",
|
||||
"https://github.com/upx/upx/releases/download/v4.0.0/upx-4.0.0-mipsel_linux.tar.xz",
|
||||
"https://github.com/upx/upx/releases/download/v4.0.0/upx-4.0.0-powerpc64le_linux.tar.xz",
|
||||
"https://github.com/upx/upx/releases/download/v4.0.0/upx-4.0.0-powerpc_linux.tar.xz",
|
||||
"https://github.com/upx/upx/releases/download/v4.0.0/upx-4.0.0-src.tar.xz",
|
||||
"https://github.com/upx/upx/releases/download/v4.0.0/upx-4.0.0-win32.zip",
|
||||
"https://github.com/upx/upx/releases/download/v4.0.0/upx-4.0.0-win64.zip"
|
||||
]
|
||||
},
|
||||
"v3.99": {
|
||||
"id": 81217748,
|
||||
"tag_name": "v3.99",
|
||||
"html_url": "https://github.com/upx/upx/releases/tag/v3.99",
|
||||
"assets": [
|
||||
"https://github.com/upx/upx/releases/download/v3.99/upx-3.99-src.tar.xz"
|
||||
]
|
||||
},
|
||||
"v3.96": {
|
||||
"id": 23054413,
|
||||
"tag_name": "v3.96",
|
||||
"html_url": "https://github.com/upx/upx/releases/tag/v3.96",
|
||||
"assets": [
|
||||
"https://github.com/upx/upx/releases/download/v3.96/upx-3.96-amd64_linux.tar.xz",
|
||||
"https://github.com/upx/upx/releases/download/v3.96/upx-3.96-arm64_linux.tar.xz",
|
||||
"https://github.com/upx/upx/releases/download/v3.96/upx-3.96-arm_linux.tar.xz",
|
||||
"https://github.com/upx/upx/releases/download/v3.96/upx-3.96-armeb_linux.tar.xz",
|
||||
"https://github.com/upx/upx/releases/download/v3.96/upx-3.96-dos.zip",
|
||||
"https://github.com/upx/upx/releases/download/v3.96/upx-3.96-i386_linux.tar.xz",
|
||||
"https://github.com/upx/upx/releases/download/v3.96/upx-3.96-mips_linux.tar.xz",
|
||||
"https://github.com/upx/upx/releases/download/v3.96/upx-3.96-mipsel_linux.tar.xz",
|
||||
"https://github.com/upx/upx/releases/download/v3.96/upx-3.96-powerpc64le_linux.tar.xz",
|
||||
"https://github.com/upx/upx/releases/download/v3.96/upx-3.96-powerpc_linux.tar.xz",
|
||||
"https://github.com/upx/upx/releases/download/v3.96/upx-3.96-src.tar.xz",
|
||||
"https://github.com/upx/upx/releases/download/v3.96/upx-3.96-win32.zip",
|
||||
"https://github.com/upx/upx/releases/download/v3.96/upx-3.96-win64.zip"
|
||||
]
|
||||
},
|
||||
"v3.95": {
|
||||
"id": 12577195,
|
||||
"tag_name": "v3.95",
|
||||
"html_url": "https://github.com/upx/upx/releases/tag/v3.95",
|
||||
"assets": [
|
||||
"https://github.com/upx/upx/releases/download/v3.95/upx-3.95-amd64_linux.tar.xz",
|
||||
"https://github.com/upx/upx/releases/download/v3.95/upx-3.95-arm64_linux.tar.xz",
|
||||
"https://github.com/upx/upx/releases/download/v3.95/upx-3.95-arm_linux.tar.xz",
|
||||
"https://github.com/upx/upx/releases/download/v3.95/upx-3.95-armeb_linux.tar.xz",
|
||||
"https://github.com/upx/upx/releases/download/v3.95/upx-3.95-dos.zip",
|
||||
"https://github.com/upx/upx/releases/download/v3.95/upx-3.95-i386_linux.tar.xz",
|
||||
"https://github.com/upx/upx/releases/download/v3.95/upx-3.95-mips_linux.tar.xz",
|
||||
"https://github.com/upx/upx/releases/download/v3.95/upx-3.95-mipsel_linux.tar.xz",
|
||||
"https://github.com/upx/upx/releases/download/v3.95/upx-3.95-powerpc64le_linux.tar.xz",
|
||||
"https://github.com/upx/upx/releases/download/v3.95/upx-3.95-powerpc_linux.tar.xz",
|
||||
"https://github.com/upx/upx/releases/download/v3.95/upx-3.95-src.tar.xz",
|
||||
"https://github.com/upx/upx/releases/download/v3.95/upx-3.95-win32.zip",
|
||||
"https://github.com/upx/upx/releases/download/v3.95/upx-3.95-win64.zip"
|
||||
]
|
||||
},
|
||||
"v3.94": {
|
||||
"id": 6366171,
|
||||
"tag_name": "v3.94",
|
||||
"html_url": "https://github.com/upx/upx/releases/tag/v3.94",
|
||||
"assets": [
|
||||
"https://github.com/upx/upx/releases/download/v3.94/upx-3.94-amd64_linux.tar.xz",
|
||||
"https://github.com/upx/upx/releases/download/v3.94/upx-3.94-armeb_linux.tar.xz",
|
||||
"https://github.com/upx/upx/releases/download/v3.94/upx-3.94-i386_linux.tar.xz",
|
||||
"https://github.com/upx/upx/releases/download/v3.94/upx-3.94-mipsel_linux.tar.xz",
|
||||
"https://github.com/upx/upx/releases/download/v3.94/upx-3.94-powerpc_linux.tar.xz",
|
||||
"https://github.com/upx/upx/releases/download/v3.94/upx-3.94-src.tar.xz",
|
||||
"https://github.com/upx/upx/releases/download/v3.94/upx394a.zip",
|
||||
"https://github.com/upx/upx/releases/download/v3.94/upx394d.zip",
|
||||
"https://github.com/upx/upx/releases/download/v3.94/upx394w.zip",
|
||||
"https://github.com/upx/upx/releases/download/v3.94/upx394wce.zip"
|
||||
]
|
||||
},
|
||||
"v3.93": {
|
||||
"id": 5296538,
|
||||
"tag_name": "v3.93",
|
||||
"html_url": "https://github.com/upx/upx/releases/tag/v3.93",
|
||||
"assets": [
|
||||
"https://github.com/upx/upx/releases/download/v3.93/upx-3.93-amd64_linux.tar.xz",
|
||||
"https://github.com/upx/upx/releases/download/v3.93/upx-3.93-armeb_linux.tar.xz",
|
||||
"https://github.com/upx/upx/releases/download/v3.93/upx-3.93-i386_linux.tar.xz",
|
||||
"https://github.com/upx/upx/releases/download/v3.93/upx-3.93-mipsel_linux.tar.xz",
|
||||
"https://github.com/upx/upx/releases/download/v3.93/upx-3.93-powerpc_linux.tar.xz",
|
||||
"https://github.com/upx/upx/releases/download/v3.93/upx-3.93-src.tar.xz",
|
||||
"https://github.com/upx/upx/releases/download/v3.93/upx393a.zip",
|
||||
"https://github.com/upx/upx/releases/download/v3.93/upx393d.zip",
|
||||
"https://github.com/upx/upx/releases/download/v3.93/upx393w.zip",
|
||||
"https://github.com/upx/upx/releases/download/v3.93/upx393wce.zip"
|
||||
]
|
||||
},
|
||||
"v3.92": {
|
||||
"id": 4888235,
|
||||
"tag_name": "v3.92",
|
||||
"html_url": "https://github.com/upx/upx/releases/tag/v3.92",
|
||||
"assets": [
|
||||
"https://github.com/upx/upx/releases/download/v3.92/upx-3.92-amd64_linux.tar.xz",
|
||||
"https://github.com/upx/upx/releases/download/v3.92/upx-3.92-armeb_linux.tar.xz",
|
||||
"https://github.com/upx/upx/releases/download/v3.92/upx-3.92-i386_linux.tar.xz",
|
||||
"https://github.com/upx/upx/releases/download/v3.92/upx-3.92-mipsel_linux.tar.xz",
|
||||
"https://github.com/upx/upx/releases/download/v3.92/upx-3.92-powerpc_linux.tar.xz",
|
||||
"https://github.com/upx/upx/releases/download/v3.92/upx-3.92-src.tar.xz",
|
||||
"https://github.com/upx/upx/releases/download/v3.92/upx392a.zip",
|
||||
"https://github.com/upx/upx/releases/download/v3.92/upx392d.zip",
|
||||
"https://github.com/upx/upx/releases/download/v3.92/upx392w.zip",
|
||||
"https://github.com/upx/upx/releases/download/v3.92/upx392wce.zip"
|
||||
]
|
||||
},
|
||||
"v3.91": {
|
||||
"id": 4087014,
|
||||
"tag_name": "v3.91",
|
||||
"html_url": "https://github.com/upx/upx/releases/tag/v3.91",
|
||||
"assets": [
|
||||
"https://github.com/upx/upx/releases/download/v3.91/upx-3.91-amd64_linux.tar.bz2",
|
||||
"https://github.com/upx/upx/releases/download/v3.91/upx-3.91-armeb_linux.tar.bz2",
|
||||
"https://github.com/upx/upx/releases/download/v3.91/upx-3.91-i386_linux.tar.bz2",
|
||||
"https://github.com/upx/upx/releases/download/v3.91/upx-3.91-mipsel_linux.tar.bz2",
|
||||
"https://github.com/upx/upx/releases/download/v3.91/upx-3.91-powerpc_linux.tar.bz2",
|
||||
"https://github.com/upx/upx/releases/download/v3.91/upx-3.91-src.tar.bz2",
|
||||
"https://github.com/upx/upx/releases/download/v3.91/upx391a.zip",
|
||||
"https://github.com/upx/upx/releases/download/v3.91/upx391d.zip",
|
||||
"https://github.com/upx/upx/releases/download/v3.91/upx391w.zip",
|
||||
"https://github.com/upx/upx/releases/download/v3.91/upx391wce.zip"
|
||||
]
|
||||
},
|
||||
"v3.00": {
|
||||
"id": 4258222,
|
||||
"tag_name": "v3.00",
|
||||
"html_url": "https://github.com/upx/upx/releases/tag/v3.00",
|
||||
"assets": []
|
||||
}
|
||||
}
|
||||
38
.github/workflows/ci.yml
vendored
38
.github/workflows/ci.yml
vendored
@@ -1,8 +1,12 @@
|
||||
name: ci
|
||||
|
||||
concurrency:
|
||||
group: ${{ github.workflow }}-${{ github.ref }}
|
||||
cancel-in-progress: true
|
||||
|
||||
on:
|
||||
schedule:
|
||||
- cron: '0 10 * * *' # everyday at 10am
|
||||
- cron: '0 10 * * *'
|
||||
push:
|
||||
branches:
|
||||
- 'master'
|
||||
@@ -10,9 +14,8 @@ on:
|
||||
tags:
|
||||
- 'v*'
|
||||
pull_request:
|
||||
branches:
|
||||
- 'master'
|
||||
- 'releases/v*'
|
||||
paths-ignore:
|
||||
- '.github/upx-releases.json'
|
||||
|
||||
jobs:
|
||||
ci:
|
||||
@@ -51,3 +54,30 @@ jobs:
|
||||
files: |
|
||||
./bin/firefox-history-merger*
|
||||
args: -fq
|
||||
|
||||
install-only:
|
||||
runs-on: ${{ matrix.os }}
|
||||
strategy:
|
||||
fail-fast: false
|
||||
matrix:
|
||||
os:
|
||||
- ubuntu-latest
|
||||
- windows-latest
|
||||
version:
|
||||
- latest
|
||||
- v4.0.2
|
||||
steps:
|
||||
-
|
||||
name: Checkout
|
||||
uses: actions/checkout@v3
|
||||
-
|
||||
name: UPX
|
||||
uses: ./
|
||||
with:
|
||||
version: ${{ matrix.version }}
|
||||
install-only: true
|
||||
-
|
||||
name: Verify
|
||||
run: |
|
||||
which upx
|
||||
upx --version
|
||||
|
||||
10
.github/workflows/labels.yml
vendored
10
.github/workflows/labels.yml
vendored
@@ -1,5 +1,9 @@
|
||||
name: labels
|
||||
|
||||
concurrency:
|
||||
group: ${{ github.workflow }}-${{ github.ref }}
|
||||
cancel-in-progress: true
|
||||
|
||||
on:
|
||||
push:
|
||||
branches:
|
||||
@@ -7,6 +11,10 @@ on:
|
||||
paths:
|
||||
- '.github/labels.yml'
|
||||
- '.github/workflows/labels.yml'
|
||||
pull_request:
|
||||
paths:
|
||||
- '.github/labels.yml'
|
||||
- '.github/workflows/labels.yml'
|
||||
|
||||
jobs:
|
||||
labeler:
|
||||
@@ -18,3 +26,5 @@ jobs:
|
||||
-
|
||||
name: Run Labeler
|
||||
uses: crazy-max/ghaction-github-labeler@v4
|
||||
with:
|
||||
dry-run: ${{ github.event_name == 'pull_request' }}
|
||||
|
||||
13
.github/workflows/test.yml
vendored
13
.github/workflows/test.yml
vendored
@@ -1,14 +1,17 @@
|
||||
name: test
|
||||
|
||||
concurrency:
|
||||
group: ${{ github.workflow }}-${{ github.ref }}
|
||||
cancel-in-progress: true
|
||||
|
||||
on:
|
||||
push:
|
||||
branches:
|
||||
- 'master'
|
||||
- 'releases/v*'
|
||||
pull_request:
|
||||
branches:
|
||||
- 'master'
|
||||
- 'releases/v*'
|
||||
paths-ignore:
|
||||
- '.github/upx-releases.json'
|
||||
|
||||
jobs:
|
||||
test:
|
||||
@@ -19,12 +22,12 @@ jobs:
|
||||
uses: actions/checkout@v3
|
||||
-
|
||||
name: Validate
|
||||
uses: docker/bake-action@v2
|
||||
uses: docker/bake-action@v3
|
||||
with:
|
||||
targets: validate
|
||||
-
|
||||
name: Test
|
||||
uses: docker/bake-action@v2
|
||||
uses: docker/bake-action@v3
|
||||
with:
|
||||
targets: test
|
||||
-
|
||||
|
||||
58
.github/workflows/upx-releases-json.yml
vendored
Normal file
58
.github/workflows/upx-releases-json.yml
vendored
Normal file
@@ -0,0 +1,58 @@
|
||||
name: upx-releases-json
|
||||
|
||||
concurrency:
|
||||
group: ${{ github.workflow }}-${{ github.ref }}
|
||||
cancel-in-progress: true
|
||||
|
||||
on:
|
||||
workflow_dispatch:
|
||||
schedule:
|
||||
- cron: '0 */12 * * *'
|
||||
push:
|
||||
branches:
|
||||
- 'master'
|
||||
pull_request:
|
||||
paths-ignore:
|
||||
- '.github/upx-releases.json'
|
||||
|
||||
jobs:
|
||||
generate:
|
||||
uses: crazy-max/.github/.github/workflows/releases-json.yml@6dc31870ca6c4f8489bf5a408ab38fae60f47eec
|
||||
with:
|
||||
repository: upx/upx
|
||||
artifact_name: upx-releases-json
|
||||
filename: upx-releases.json
|
||||
secrets: inherit
|
||||
|
||||
open-pr:
|
||||
runs-on: ubuntu-22.04
|
||||
if: github.event_name != 'pull_request'
|
||||
needs:
|
||||
- generate
|
||||
steps:
|
||||
-
|
||||
name: Checkout
|
||||
uses: actions/checkout@v3
|
||||
-
|
||||
name: Download
|
||||
uses: actions/download-artifact@v3
|
||||
with:
|
||||
name: upx-releases-json
|
||||
path: .github
|
||||
-
|
||||
name: Commit changes
|
||||
run: |
|
||||
git add -A .
|
||||
-
|
||||
name: Create PR
|
||||
uses: peter-evans/create-pull-request@153407881ec5c347639a548ade7d8ad1d6740e38
|
||||
with:
|
||||
base: master
|
||||
branch: bot/upx-releases-json
|
||||
commit-message: "update .github/upx-releases.json"
|
||||
signoff: true
|
||||
delete-branch: true
|
||||
title: "Update `.github/upx-releases.json`"
|
||||
body: |
|
||||
Update `.github/upx-releases.json` to keep in sync with [https://github.com/upx/upx](https://github.com/upx/upx).
|
||||
draft: false
|
||||
60
CHANGELOG.md
60
CHANGELOG.md
@@ -1,60 +0,0 @@
|
||||
# Changelog
|
||||
|
||||
## 2.0.0 (2022/05/26)
|
||||
|
||||
* Node 16 as default runtime (#169)
|
||||
* This requires a minimum [Actions Runner](https://github.com/actions/runner/releases/tag/v2.285.0) version of v2.285.0, which is by default available in GHES 3.4 or later.
|
||||
|
||||
## 1.5.0 (2022/05/26)
|
||||
|
||||
* Update dev dependencies and workflow (#168)
|
||||
* Bump @actions/core from 1.2.6 to 1.6.0 (#142 #158 #161)
|
||||
* Bump @actions/exec from 1.0.4 to 1.1.1 (#152 #164)
|
||||
* Bump @actions/tool-cache from 1.6.1 to 1.7.2 (#151 #165)
|
||||
* Bump minimist from 1.2.5 to 1.2.6 (#166)
|
||||
* Bump ansi-regex from 5.0.0 to 5.0.1 (#160)
|
||||
* Bump tmpl from 1.0.4 to 1.0.5 (#159)
|
||||
* Bump path-parse from 1.0.6 to 1.0.7 (#157)
|
||||
* Bump hosted-git-info from 2.8.8 to 2.8.9 (#154)
|
||||
* Bump ws from 7.3.0 to 7.5.0 (#155)
|
||||
* Bump lodash from 4.17.20 to 4.17.21 (#153)
|
||||
* Bump y18n from 4.0.0 to 4.0.3 (#143)
|
||||
|
||||
## 1.4.0 (2021/03/27)
|
||||
|
||||
* Allow multiple files (#140)
|
||||
* Container dev workflow (#139)
|
||||
* Bump node-notifier from 8.0.0 to 8.0.1 (#135)
|
||||
* Bump @actions/tool-cache from 1.6.0 to 1.6.1 (#134)
|
||||
* Bump @actions/http-client from 1.0.8 to 1.0.11 (#131 #138)
|
||||
|
||||
## 1.3.3 (2020/10/01)
|
||||
|
||||
* Fix CVE-2020-15228
|
||||
|
||||
## 1.3.2 (2020/05/11)
|
||||
|
||||
* Update README
|
||||
|
||||
## 1.3.1 (2020/05/07)
|
||||
|
||||
* Code cleanup
|
||||
|
||||
## 1.3.0 (2020/05/06)
|
||||
|
||||
* Use native tools
|
||||
* Add Codecov
|
||||
* Update deps
|
||||
|
||||
## 1.2.0 (2020/04/09)
|
||||
|
||||
* Use ncc and clean workflows
|
||||
* Update deps
|
||||
|
||||
## 1.1.0 (2020/01/17)
|
||||
|
||||
* Update deps
|
||||
|
||||
## 1.0.0 (2020/01/17)
|
||||
|
||||
* Initial version
|
||||
2
LICENSE
2
LICENSE
@@ -1,6 +1,6 @@
|
||||
MIT License
|
||||
|
||||
Copyright (c) 2020-2022 CrazyMax
|
||||
Copyright (c) 2020-2023 CrazyMax
|
||||
|
||||
Permission is hereby granted, free of charge, to any person obtaining a copy
|
||||
of this software and associated documentation files (the "Software"), to deal
|
||||
|
||||
40
README.md
40
README.md
@@ -1,6 +1,6 @@
|
||||
[](https://github.com/crazy-max/ghaction-upx/releases/latest)
|
||||
[](https://github.com/marketplace/actions/upx-github-action)
|
||||
[](https://github.com/crazy-max/ghaction-upx/actions?workflow=test)
|
||||
[](https://github.com/crazy-max/ghaction-upx/actions?workflow=test)
|
||||
[](https://codecov.io/gh/crazy-max/ghaction-upx)
|
||||
[](https://github.com/sponsors/crazy-max)
|
||||
[](https://www.paypal.me/crazyws)
|
||||
@@ -9,8 +9,6 @@
|
||||
|
||||
GitHub Action for [UPX](https://github.com/upx/upx), the Ultimate Packer for eXecutables.
|
||||
|
||||
If you are interested, [check out](https://github.com/crazy-max?tab=repositories&q=ghaction&type=source&language=&sort=) my other :octocat: GitHub Actions!
|
||||
|
||||

|
||||
|
||||
___
|
||||
@@ -47,17 +45,43 @@ jobs:
|
||||
args: -fq
|
||||
```
|
||||
|
||||
If you just want to install UPX:
|
||||
|
||||
```yaml
|
||||
name: upx
|
||||
|
||||
on:
|
||||
push:
|
||||
|
||||
jobs:
|
||||
upx:
|
||||
runs-on: ubuntu-latest
|
||||
steps:
|
||||
-
|
||||
name: Checkout
|
||||
uses: actions/checkout@v3
|
||||
-
|
||||
name: Install UPX
|
||||
uses: crazy-max/ghaction-upx@v2
|
||||
with:
|
||||
install-only: true
|
||||
-
|
||||
name: UPX version
|
||||
run: upx --version
|
||||
```
|
||||
|
||||
## Customizing
|
||||
|
||||
### inputs
|
||||
|
||||
Following inputs can be used as `step.with` keys
|
||||
|
||||
| Name | Type | Default | Description |
|
||||
|---------------|---------|-----------|---------------------------------|
|
||||
| `version` | String | `latest` | UPX version. Example: `v3.95` |
|
||||
| `files` | String | | Newline-delimited list of path globs for files to compress (**required**) |
|
||||
| `args` | String | | Arguments to pass to UPX |
|
||||
| Name | Type | Default | Description |
|
||||
|----------------|--------|----------|------------------------------------------------------------|
|
||||
| `version` | String | `latest` | UPX version. Example: `v3.95` |
|
||||
| `files` | String | | Newline-delimited list of path globs for files to compress |
|
||||
| `args` | String | | Arguments to pass to UPX |
|
||||
| `install-only` | String | `false` | Just install UPX |
|
||||
|
||||
## Limitation
|
||||
|
||||
|
||||
@@ -1,16 +0,0 @@
|
||||
import {describe, expect, it} from '@jest/globals';
|
||||
import * as github from '../src/github';
|
||||
|
||||
describe('github', () => {
|
||||
it('returns latest UPX GitHub release', async () => {
|
||||
const release = await github.getRelease('latest');
|
||||
expect(release).not.toBeNull();
|
||||
expect(release?.tag_name).not.toEqual('');
|
||||
});
|
||||
|
||||
it('returns v3.96 GoReleaser GitHub release', async () => {
|
||||
const release = await github.getRelease('v3.96');
|
||||
expect(release).not.toBeNull();
|
||||
expect(release?.tag_name).toEqual('v3.96');
|
||||
});
|
||||
});
|
||||
@@ -2,6 +2,30 @@ import {describe, expect, it} from '@jest/globals';
|
||||
import * as fs from 'fs';
|
||||
import * as installer from '../src/installer';
|
||||
|
||||
describe('getRelease', () => {
|
||||
it('returns latest UPX GitHub release', async () => {
|
||||
const release = await installer.getRelease('latest');
|
||||
expect(release).not.toBeNull();
|
||||
expect(release?.tag_name).not.toEqual('');
|
||||
});
|
||||
|
||||
it('returns v3.95 UPX GitHub release', async () => {
|
||||
const release = await installer.getRelease('v3.95');
|
||||
expect(release).not.toBeNull();
|
||||
expect(release?.id).toEqual(12577195);
|
||||
expect(release?.tag_name).toEqual('v3.95');
|
||||
expect(release?.html_url).toEqual('https://github.com/upx/upx/releases/tag/v3.95');
|
||||
});
|
||||
|
||||
it('unknown release', async () => {
|
||||
await expect(installer.getRelease('foo')).rejects.toThrowError(
|
||||
new Error(
|
||||
'Cannot find UPX release foo in https://raw.githubusercontent.com/crazy-max/ghaction-upx/master/.github/upx-releases.json'
|
||||
)
|
||||
);
|
||||
});
|
||||
});
|
||||
|
||||
describe('installer', () => {
|
||||
it('acquires v3.95 version of UPX', async () => {
|
||||
const upx = await installer.getUPX('v3.95');
|
||||
|
||||
@@ -21,6 +21,11 @@ inputs:
|
||||
deprecationMessage: 'file is deprecated. Please use files input instead.'
|
||||
description: 'File to compress'
|
||||
required: false
|
||||
install-only:
|
||||
description: 'Just install upx'
|
||||
default: 'false'
|
||||
required: false
|
||||
|
||||
|
||||
runs:
|
||||
using: 'node16'
|
||||
|
||||
2
dist/index.js
generated
vendored
2
dist/index.js
generated
vendored
File diff suppressed because one or more lines are too long
2
dist/index.js.map
generated
vendored
2
dist/index.js.map
generated
vendored
File diff suppressed because one or more lines are too long
@@ -22,7 +22,7 @@
|
||||
"dependencies": {
|
||||
"@actions/core": "^1.10.0",
|
||||
"@actions/exec": "^1.1.1",
|
||||
"@actions/http-client": "^2.0.1",
|
||||
"@actions/http-client": "^2.1.1",
|
||||
"@actions/tool-cache": "^2.0.1"
|
||||
},
|
||||
"devDependencies": {
|
||||
|
||||
@@ -6,13 +6,15 @@ export interface Inputs {
|
||||
version: string;
|
||||
files: string[];
|
||||
args: string;
|
||||
installOnly: boolean;
|
||||
}
|
||||
|
||||
export async function getInputs(): Promise<Inputs> {
|
||||
return {
|
||||
version: core.getInput('version') || 'latest',
|
||||
files: getInputList(core.getInput('files') || core.getInput('file'), true),
|
||||
args: core.getInput('args')
|
||||
args: core.getInput('args'),
|
||||
installOnly: core.getBooleanInput('install-only')
|
||||
};
|
||||
}
|
||||
|
||||
|
||||
@@ -1,12 +0,0 @@
|
||||
import * as httpm from '@actions/http-client';
|
||||
|
||||
export interface GitHubRelease {
|
||||
id: number;
|
||||
tag_name: string;
|
||||
}
|
||||
|
||||
export const getRelease = async (version: string): Promise<GitHubRelease | null> => {
|
||||
const url = `https://github.com/upx/upx/releases/${version}`;
|
||||
const http: httpm.HttpClient = new httpm.HttpClient('ghaction-upx');
|
||||
return (await http.getJson<GitHubRelease>(url)).result;
|
||||
};
|
||||
@@ -1,22 +1,40 @@
|
||||
import * as os from 'os';
|
||||
import * as path from 'path';
|
||||
import * as util from 'util';
|
||||
import * as github from './github';
|
||||
import * as core from '@actions/core';
|
||||
import * as httpm from '@actions/http-client';
|
||||
import * as tc from '@actions/tool-cache';
|
||||
|
||||
const osPlat: string = os.platform();
|
||||
const osArch: string = os.arch();
|
||||
|
||||
export async function getUPX(version: string): Promise<string> {
|
||||
core.startGroup(`Checking UPX ${version} release...`);
|
||||
const release: github.GitHubRelease | null = await github.getRelease(version);
|
||||
if (!release) {
|
||||
throw new Error(`Cannot find UPX ${version} release`);
|
||||
export interface GitHubRelease {
|
||||
id: number;
|
||||
tag_name: string;
|
||||
html_url: string;
|
||||
assets: Array<string>;
|
||||
}
|
||||
|
||||
export const getRelease = async (version: string): Promise<GitHubRelease> => {
|
||||
const url = `https://raw.githubusercontent.com/crazy-max/ghaction-upx/master/.github/upx-releases.json`;
|
||||
const http: httpm.HttpClient = new httpm.HttpClient('ghaction-upx');
|
||||
const resp: httpm.HttpClientResponse = await http.get(url);
|
||||
const body = await resp.readBody();
|
||||
const statusCode = resp.message.statusCode || 500;
|
||||
if (statusCode >= 400) {
|
||||
throw new Error(`Failed to get UPX release ${version} from ${url} with status code ${statusCode}: ${body}`);
|
||||
}
|
||||
const releases = <Record<string, GitHubRelease>>JSON.parse(body);
|
||||
if (!releases[version]) {
|
||||
throw new Error(`Cannot find UPX release ${version} in ${url}`);
|
||||
}
|
||||
return releases[version];
|
||||
};
|
||||
|
||||
export async function getUPX(version: string): Promise<string> {
|
||||
const release: GitHubRelease = await getRelease(version);
|
||||
const semver: string = release.tag_name.replace(/^v/, '');
|
||||
core.info(`UPX ${semver} found`);
|
||||
core.endGroup();
|
||||
|
||||
const filename = util.format('%s.%s', getName(semver), osPlat == 'win32' ? 'zip' : 'tar.xz');
|
||||
const downloadUrl = util.format('https://github.com/upx/upx/releases/download/v%s/%s', semver, filename);
|
||||
|
||||
@@ -1,4 +1,5 @@
|
||||
import * as os from 'os';
|
||||
import * as path from 'path';
|
||||
import * as context from './context';
|
||||
import * as installer from './installer';
|
||||
import * as core from '@actions/core';
|
||||
@@ -14,6 +15,13 @@ async function run(): Promise<void> {
|
||||
const inputs: context.Inputs = await context.getInputs();
|
||||
const upx = await installer.getUPX(inputs.version);
|
||||
|
||||
if (inputs.installOnly) {
|
||||
const dir = path.dirname(upx);
|
||||
core.addPath(dir);
|
||||
core.debug(`Added ${dir} to PATH`);
|
||||
return;
|
||||
}
|
||||
|
||||
const files: string[] = context.resolvePaths(inputs.files);
|
||||
if (files.length == 0) {
|
||||
core.warning(`No files were found. Please check the 'files' input.`);
|
||||
|
||||
101
yarn.lock
101
yarn.lock
@@ -17,10 +17,10 @@
|
||||
dependencies:
|
||||
"@actions/io" "^1.0.1"
|
||||
|
||||
"@actions/http-client@^2.0.1":
|
||||
version "2.0.1"
|
||||
resolved "https://registry.yarnpkg.com/@actions/http-client/-/http-client-2.0.1.tgz#873f4ca98fe32f6839462a6f046332677322f99c"
|
||||
integrity sha512-PIXiMVtz6VvyaRsGY268qvj57hXQEpsYogYOu2nrQhlf+XCGmZstmuZBbAybUl1nQGnvS1k1eEsQ69ZoD7xlSw==
|
||||
"@actions/http-client@^2.0.1", "@actions/http-client@^2.1.1":
|
||||
version "2.1.1"
|
||||
resolved "https://registry.yarnpkg.com/@actions/http-client/-/http-client-2.1.1.tgz#a8e97699c315bed0ecaeaaeb640948470d4586a0"
|
||||
integrity sha512-qhrkRMB40bbbLo7gF+0vu+X+UawOvQQqNAA/5Unx774RS8poaOhThDOG6BGmxvAnxhQnDp2BG/ZUm65xZILTpw==
|
||||
dependencies:
|
||||
tunnel "^0.0.6"
|
||||
|
||||
@@ -1206,9 +1206,9 @@ babel-preset-jest@^27.5.1:
|
||||
babel-preset-current-node-syntax "^1.0.0"
|
||||
|
||||
balanced-match@^1.0.0:
|
||||
version "1.0.0"
|
||||
resolved "https://registry.yarnpkg.com/balanced-match/-/balanced-match-1.0.0.tgz#89b4d199ab2bee49de164ea02b89ce462d71b767"
|
||||
integrity sha1-ibTRmasr7kneFk6gK4nORi1xt2c=
|
||||
version "1.0.2"
|
||||
resolved "https://registry.yarnpkg.com/balanced-match/-/balanced-match-1.0.2.tgz#e83e3a7e3f300b34cb9d87f615fa0cbf357690ee"
|
||||
integrity sha512-3oSeUO0TMV67hN1AmbXsK4yaqU7tjiHlbxRDZOpH0KW9+CeX4bRAaX0Anxt0tx2MrpRpWwQaPwIlISEJhYU5Pw==
|
||||
|
||||
brace-expansion@^1.1.7:
|
||||
version "1.1.11"
|
||||
@@ -1365,7 +1365,7 @@ combined-stream@^1.0.8:
|
||||
concat-map@0.0.1:
|
||||
version "0.0.1"
|
||||
resolved "https://registry.yarnpkg.com/concat-map/-/concat-map-0.0.1.tgz#d8a96bd77fd68df7793a73036a3ba0d5405d477b"
|
||||
integrity sha1-2Klr13/Wjfd5OnMDajug1UBdR3s=
|
||||
integrity sha512-/Srv4dswyQNBfohGpz9o6Yb3Gz3SrUDqBH5rTuhGR7ahtlbYKnVxw2bCFMRljaA7EXHaXZ8wsHdodFvbkhKmqg==
|
||||
|
||||
convert-source-map@^1.4.0, convert-source-map@^1.6.0, convert-source-map@^1.7.0:
|
||||
version "1.7.0"
|
||||
@@ -2584,17 +2584,10 @@ json-stable-stringify-without-jsonify@^1.0.1:
|
||||
resolved "https://registry.yarnpkg.com/json-stable-stringify-without-jsonify/-/json-stable-stringify-without-jsonify-1.0.1.tgz#9db7b59496ad3f3cfef30a75142d2d930ad72651"
|
||||
integrity sha1-nbe1lJatPzz+8wp1FC0tkwrXJlE=
|
||||
|
||||
json5@2.x, json5@^2.1.2:
|
||||
version "2.1.3"
|
||||
resolved "https://registry.yarnpkg.com/json5/-/json5-2.1.3.tgz#c9b0f7fa9233bfe5807fe66fcf3a5617ed597d43"
|
||||
integrity sha512-KXPvOm8K9IJKFM0bmdn8QXh7udDh1g/giieX0NLCaMnb4hEiVFqnop2ImTXCc5e0/oHz3LTqmHGtExn5hfMkOA==
|
||||
dependencies:
|
||||
minimist "^1.2.5"
|
||||
|
||||
json5@^2.2.1:
|
||||
version "2.2.1"
|
||||
resolved "https://registry.yarnpkg.com/json5/-/json5-2.2.1.tgz#655d50ed1e6f95ad1a3caababd2b0efda10b395c"
|
||||
integrity sha512-1hqLFMSrGHRHxav9q9gNjJ5EXznIxGVO09xQRrwplcS8qs28pZ8s8hupZAmqDwZUmVZ2Qb2jnyPOWcDH8m8dlA==
|
||||
json5@2.x, json5@^2.1.2, json5@^2.2.1:
|
||||
version "2.2.3"
|
||||
resolved "https://registry.yarnpkg.com/json5/-/json5-2.2.3.tgz#78cd6f1a19bdc12b73db5ad0c61efd66c1e29283"
|
||||
integrity sha512-XmOWe7eyHYH14cLdVPoyg+GOH3rYX++KpzrylJwSW98t3Nk+U8XOl8FWKOgwtzdb8lXGf6zYwDUzeHMWfxasyg==
|
||||
|
||||
kleur@^3.0.3:
|
||||
version "3.0.3"
|
||||
@@ -2716,17 +2709,12 @@ mimic-fn@^2.1.0:
|
||||
integrity sha512-OqbOk5oEQeAZ8WXWydlu9HJjz9WVdEIvamMCcXmuqUYjTknH/sqsWvhQ3vgwKFRR1HpjvNBKQ37nbJgYzGqGcg==
|
||||
|
||||
minimatch@^3.0.4:
|
||||
version "3.0.4"
|
||||
resolved "https://registry.yarnpkg.com/minimatch/-/minimatch-3.0.4.tgz#5166e286457f03306064be5497e8dbb0c3d32083"
|
||||
integrity sha512-yJHVQEhyqPLUTgt9B83PXu6W3rx4MvvHvSUvToogpwoGDOUQ+yDrR0HRot+yOCdCO7u4hX3pWft6kWBBcqh0UA==
|
||||
version "3.1.2"
|
||||
resolved "https://registry.yarnpkg.com/minimatch/-/minimatch-3.1.2.tgz#19cd194bfd3e428f049a70817c038d89ab4be35b"
|
||||
integrity sha512-J7p63hRiAjw1NDEww1W7i37+ByIrOWO5XQQAzZ3VOcL0PNybwpfmV/N05zFAzwQ9USyEcX6t3UO+K5aqBQOIHw==
|
||||
dependencies:
|
||||
brace-expansion "^1.1.7"
|
||||
|
||||
minimist@^1.2.5:
|
||||
version "1.2.6"
|
||||
resolved "https://registry.yarnpkg.com/minimist/-/minimist-1.2.6.tgz#8637a5b759ea0d6e98702cfb3a9283323c93af44"
|
||||
integrity sha512-Jsjnk4bw3YJqYzbdyBiNsPWHPfO++UGG749Cxs6peCu5Xg4nrena6OVxOYxrQTqww0Jmwt+Ref8rggumkTLz9Q==
|
||||
|
||||
ms@2.1.2, ms@^2.1.1:
|
||||
version "2.1.2"
|
||||
resolved "https://registry.yarnpkg.com/ms/-/ms-2.1.2.tgz#d09d1f357b443f493382a8eb3ccd183872ae6009"
|
||||
@@ -2944,6 +2932,11 @@ punycode@^2.1.0, punycode@^2.1.1:
|
||||
resolved "https://registry.yarnpkg.com/punycode/-/punycode-2.1.1.tgz#b58b010ac40c22c5657616c8d2c2c02c7bf479ec"
|
||||
integrity sha512-XRsRjdf+j5ml+y/6GKHPZbrF/8p2Yga0JPtdqTIY2Xe5ohJPD9saDJJLPvp9+NSBprVvevdXZybnj2cv8OEd0A==
|
||||
|
||||
querystringify@^2.1.1:
|
||||
version "2.2.0"
|
||||
resolved "https://registry.yarnpkg.com/querystringify/-/querystringify-2.2.0.tgz#3345941b4153cb9d082d8eee4cda2016a9aef7f6"
|
||||
integrity sha512-FIqgj2EUvTa7R50u0rGsyTftzjYmv/a3hO345bZNrqabNqjtgiDMgmo4mkUjd+nzU5oF3dClKqFIPUKybUyqoQ==
|
||||
|
||||
queue-microtask@^1.2.2:
|
||||
version "1.2.3"
|
||||
resolved "https://registry.yarnpkg.com/queue-microtask/-/queue-microtask-1.2.3.tgz#4929228bbc724dfac43e0efb058caf7b6cfb6243"
|
||||
@@ -2964,6 +2957,11 @@ require-directory@^2.1.1:
|
||||
resolved "https://registry.yarnpkg.com/require-directory/-/require-directory-2.1.1.tgz#8c64ad5fd30dab1c976e2344ffe7f792a6a6df42"
|
||||
integrity sha1-jGStX9MNqxyXbiNE/+f3kqam30I=
|
||||
|
||||
requires-port@^1.0.0:
|
||||
version "1.0.0"
|
||||
resolved "https://registry.yarnpkg.com/requires-port/-/requires-port-1.0.0.tgz#925d2601d39ac485e091cf0da5c6e694dc3dcaff"
|
||||
integrity sha512-KigOCHcocU3XODJxsu8i/j8T9tzT4adHiecwORRQ0ZZFcp7ahwXuRU1m+yuO90C5ZUyGeGfocHDI14M3L3yDAQ==
|
||||
|
||||
resolve-cwd@^3.0.0:
|
||||
version "3.0.0"
|
||||
resolved "https://registry.yarnpkg.com/resolve-cwd/-/resolve-cwd-3.0.0.tgz#0f0075f1bb2544766cf73ba6a6e2adfebcb13f2d"
|
||||
@@ -3039,21 +3037,21 @@ saxes@^5.0.1:
|
||||
xmlchars "^2.2.0"
|
||||
|
||||
semver@7.x, semver@^7.3.2, semver@^7.3.5:
|
||||
version "7.3.7"
|
||||
resolved "https://registry.yarnpkg.com/semver/-/semver-7.3.7.tgz#12c5b649afdbf9049707796e22a4028814ce523f"
|
||||
integrity sha512-QlYTucUYOews+WeEujDoEGziz4K6c47V/Bd+LjSSYcA94p+DmINdf7ncaUinThfvZyu13lN9OY1XDxt8C0Tw0g==
|
||||
version "7.5.4"
|
||||
resolved "https://registry.yarnpkg.com/semver/-/semver-7.5.4.tgz#483986ec4ed38e1c6c48c34894a9182dbff68a6e"
|
||||
integrity sha512-1bCSESV6Pv+i21Hvpxp3Dx+pSD8lIPt8uVjRrxAUt/nbswYc+tK6Y2btiULjd4+fnq15PX+nqQDC7Oft7WkwcA==
|
||||
dependencies:
|
||||
lru-cache "^6.0.0"
|
||||
|
||||
semver@^5.4.1:
|
||||
version "5.7.1"
|
||||
resolved "https://registry.yarnpkg.com/semver/-/semver-5.7.1.tgz#a954f931aeba508d307bbf069eff0c01c96116f7"
|
||||
integrity sha512-sauaDf/PZdVgrLTNYHRtpXa1iRiKcaebiKQ1BJdpQlWH2lCvexQdX55snPFyK7QzpudqbCI0qXFfOasHdyNDGQ==
|
||||
version "5.7.2"
|
||||
resolved "https://registry.yarnpkg.com/semver/-/semver-5.7.2.tgz#48d55db737c3287cd4835e17fa13feace1c41ef8"
|
||||
integrity sha512-cBznnQ9KjJqU67B52RMC65CMarK2600WFnbkcaiwWq3xy/5haFJlshgnpjovMVJ+Hff49d8GEn0b87C5pDQ10g==
|
||||
|
||||
semver@^6.0.0, semver@^6.1.0, semver@^6.3.0:
|
||||
version "6.3.0"
|
||||
resolved "https://registry.yarnpkg.com/semver/-/semver-6.3.0.tgz#ee0a64c8af5e8ceea67687b133761e1becbd1d3d"
|
||||
integrity sha512-b39TBaTSfV6yBrapU89p5fKekE2m/NwnDocOVruQFS1/veMgdzuPcnOM34M6CwxW8jH/lxEa5rBoDeUwu5HHTw==
|
||||
version "6.3.1"
|
||||
resolved "https://registry.yarnpkg.com/semver/-/semver-6.3.1.tgz#556d2ef8689146e46dcea4bfdd095f3434dffcb4"
|
||||
integrity sha512-BR7VvDCVHO+q2xBEWskxS6DJE1qRnb7DxzUrogb71CWoSficBxYsiAGd+Kl0mmq/MprG9yArRkyrQxTO6XjMzA==
|
||||
|
||||
shebang-command@^2.0.0:
|
||||
version "2.0.0"
|
||||
@@ -3252,13 +3250,14 @@ to-regex-range@^5.0.1:
|
||||
is-number "^7.0.0"
|
||||
|
||||
tough-cookie@^4.0.0:
|
||||
version "4.0.0"
|
||||
resolved "https://registry.yarnpkg.com/tough-cookie/-/tough-cookie-4.0.0.tgz#d822234eeca882f991f0f908824ad2622ddbece4"
|
||||
integrity sha512-tHdtEpQCMrc1YLrMaqXXcj6AxhYi/xgit6mZu1+EDWUn+qhUf8wMQoFIy9NXuq23zAwtcB0t/MjACGR18pcRbg==
|
||||
version "4.1.3"
|
||||
resolved "https://registry.yarnpkg.com/tough-cookie/-/tough-cookie-4.1.3.tgz#97b9adb0728b42280aa3d814b6b999b2ff0318bf"
|
||||
integrity sha512-aX/y5pVRkfRnfmuX+OdbSdXvPe6ieKX/G2s7e98f4poJHnqH3281gDPm/metm6E/WRamfx7WC4HUqkWHfQHprw==
|
||||
dependencies:
|
||||
psl "^1.1.33"
|
||||
punycode "^2.1.1"
|
||||
universalify "^0.1.2"
|
||||
universalify "^0.2.0"
|
||||
url-parse "^1.5.3"
|
||||
|
||||
tr46@^2.0.2:
|
||||
version "2.0.2"
|
||||
@@ -3365,10 +3364,10 @@ typescript@^4.4.4:
|
||||
resolved "https://registry.yarnpkg.com/typescript/-/typescript-4.6.3.tgz#eefeafa6afdd31d725584c67a0eaba80f6fc6c6c"
|
||||
integrity sha512-yNIatDa5iaofVozS/uQJEl3JRWLKKGJKh6Yaiv0GLGSuhpFJe7P3SbHZ8/yjAHRQwKRoA6YZqlfjXWmVzoVSMw==
|
||||
|
||||
universalify@^0.1.2:
|
||||
version "0.1.2"
|
||||
resolved "https://registry.yarnpkg.com/universalify/-/universalify-0.1.2.tgz#b646f69be3942dabcecc9d6639c80dc105efaa66"
|
||||
integrity sha512-rBJeI5CXAlmy1pV+617WB9J63U6XcazHHF2f2dbJix4XzpUF0RS3Zbj0FGIOCAva5P/d/GBOYaACQ1w+0azUkg==
|
||||
universalify@^0.2.0:
|
||||
version "0.2.0"
|
||||
resolved "https://registry.yarnpkg.com/universalify/-/universalify-0.2.0.tgz#6451760566fa857534745ab1dde952d1b1761be0"
|
||||
integrity sha512-CJ1QgKmNg3CwvAv/kOFmtnEN05f0D/cn9QntgNOQlQF9dgvVTHj3t+8JPdjqawCHk7V/KA+fbUqzZ9XWhcqPUg==
|
||||
|
||||
uri-js@^4.2.2:
|
||||
version "4.2.2"
|
||||
@@ -3377,6 +3376,14 @@ uri-js@^4.2.2:
|
||||
dependencies:
|
||||
punycode "^2.1.0"
|
||||
|
||||
url-parse@^1.5.3:
|
||||
version "1.5.10"
|
||||
resolved "https://registry.yarnpkg.com/url-parse/-/url-parse-1.5.10.tgz#9d3c2f736c1d75dd3bd2be507dcc111f1e2ea9c1"
|
||||
integrity sha512-WypcfiRhfeUP9vvF0j6rw0J3hrWrw6iZv3+22h6iRMJ/8z1Tj6XfLP4DsUix5MhMPnXpiHDoKyoZ/bdCkwBCiQ==
|
||||
dependencies:
|
||||
querystringify "^2.1.1"
|
||||
requires-port "^1.0.0"
|
||||
|
||||
uuid@^3.3.2:
|
||||
version "3.4.0"
|
||||
resolved "https://registry.yarnpkg.com/uuid/-/uuid-3.4.0.tgz#b23e4358afa8a202fe7a100af1f5f883f02007ee"
|
||||
@@ -3475,9 +3482,9 @@ which@^2.0.1:
|
||||
isexe "^2.0.0"
|
||||
|
||||
word-wrap@^1.2.3, word-wrap@~1.2.3:
|
||||
version "1.2.3"
|
||||
resolved "https://registry.yarnpkg.com/word-wrap/-/word-wrap-1.2.3.tgz#610636f6b1f703891bd34771ccb17fb93b47079c"
|
||||
integrity sha512-Hz/mrNwitNRh/HUAtM/VT/5VH+ygD6DV7mYKZAtHOrbs8U7lvPS6xf7EJKMF0uW1KJCl0H701g3ZGus+muE5vQ==
|
||||
version "1.2.5"
|
||||
resolved "https://registry.yarnpkg.com/word-wrap/-/word-wrap-1.2.5.tgz#d2c45c6dd4fbce621a66f136cbe328afd0410b34"
|
||||
integrity sha512-BN22B5eaMMI9UMtjrGd5g5eCYPpCPDUy0FJXbYsaT5zYxjFOckS53SQDE3pWkVoWpHXVb3BrYcEN4Twa55B5cA==
|
||||
|
||||
wrap-ansi@^7.0.0:
|
||||
version "7.0.0"
|
||||
|
||||
Reference in New Issue
Block a user