Skip to content

Commit 74fad66

Browse files
authored
Update the readme with direct upload details (#795)
* Update the readme with direct upload details * Update the TOC and remove a section * Fix some wording * Remove a tautology
1 parent bbbca2d commit 74fad66

1 file changed

Lines changed: 32 additions & 53 deletions

File tree

README.md

Lines changed: 32 additions & 53 deletions
Original file line numberDiff line numberDiff line change
@@ -11,15 +11,14 @@ Upload [Actions Artifacts](https://docs.github.com/en/actions/using-workflows/st
1111
See also [download-artifact](https://github.com/actions/download-artifact).
1212

1313
- [`@actions/upload-artifact`](#actionsupload-artifact)
14-
- [v6 - What's new](#v6---whats-new)
15-
- [v4 - What's new](#v4---whats-new)
16-
- [Improvements](#improvements)
17-
- [Breaking Changes](#breaking-changes)
14+
- [What's new](#whats-new)
15+
- [GHES Support](#ghes-support)
1816
- [Usage](#usage)
1917
- [Inputs](#inputs)
2018
- [Outputs](#outputs)
2119
- [Examples](#examples)
22-
- [Upload an Individual File](#upload-an-individual-file)
20+
- [Upload an Individual File (Zipped)](#upload-an-individual-file-zipped)
21+
- [Upload an Individual File (Unzipped)](#upload-an-individual-file-unzipped)
2322
- [Upload an Entire Directory](#upload-an-entire-directory)
2423
- [Upload using a Wildcard Pattern](#upload-using-a-wildcard-pattern)
2524
- [Upload using Multiple Paths and Exclusions](#upload-using-multiple-paths-and-exclusions)
@@ -34,53 +33,16 @@ See also [download-artifact](https://github.com/actions/download-artifact).
3433
- [Overwriting an Artifact](#overwriting-an-artifact)
3534
- [Limitations](#limitations)
3635
- [Number of Artifacts](#number-of-artifacts)
37-
- [Zip archives](#zip-archives)
3836
- [Permission Loss](#permission-loss)
3937
- [Where does the upload go?](#where-does-the-upload-go)
4038

39+
## What's new
4140

42-
## v6 - What's new
43-
44-
> [!IMPORTANT]
45-
> actions/upload-artifact@v6 now runs on Node.js 24 (`runs.using: node24`) and requires a minimum Actions Runner version of 2.327.1. If you are using self-hosted runners, ensure they are updated before upgrading.
46-
47-
### Node.js 24
48-
49-
This release updates the runtime to Node.js 24. v5 had preliminary support for Node.js 24, however this action was by default still running on Node.js 20. Now this action by default will run on Node.js 24.
50-
51-
## v4 - What's new
52-
53-
> [!IMPORTANT]
54-
> upload-artifact@v4+ is not currently supported on GitHub Enterprise Server (GHES) yet. If you are on GHES, you must use [v3](https://github.com/actions/upload-artifact/releases/tag/v3) (Node 16) or [v3-node20](https://github.com/actions/upload-artifact/releases/tag/v3-node20) (Node 20).
55-
56-
The release of upload-artifact@v4 and download-artifact@v4 are major changes to the backend architecture of Artifacts. They have numerous performance and behavioral improvements.
57-
58-
For more information, see the [`@actions/artifact`](https://github.com/actions/toolkit/tree/main/packages/artifact) documentation.
59-
60-
There is also a new sub-action, `actions/upload-artifact/merge`. For more info, check out that action's [README](./merge/README.md).
61-
62-
### Improvements
63-
64-
1. Uploads are significantly faster, upwards of 90% improvement in worst case scenarios.
65-
2. Once uploaded, an Artifact ID is returned and Artifacts are immediately available in the UI and [REST API](https://docs.github.com/en/rest/actions/artifacts). Previously, you would have to wait for the run to be completed before an ID was available or any APIs could be utilized.
66-
3. The contents of an Artifact are uploaded together into an _immutable_ archive. They cannot be altered by subsequent jobs unless the Artifacts are deleted and recreated (where they will have a new ID). Both of these factors help reduce the possibility of accidentally corrupting Artifact files.
67-
4. The compression level of an Artifact can be manually tweaked for speed or size reduction.
68-
69-
### Breaking Changes
70-
71-
1. On self hosted runners, additional [firewall rules](https://github.com/actions/toolkit/tree/main/packages/artifact#breaking-changes) may be required.
72-
2. Uploading to the same named Artifact multiple times.
73-
74-
Due to how Artifacts are created in this new version, it is no longer possible to upload to the same named Artifact multiple times. You must either split the uploads into multiple Artifacts with different names, or only upload once. Otherwise you _will_ encounter an error.
75-
76-
3. Limit of Artifacts for an individual job. Each job in a workflow run now has a limit of 500 artifacts.
77-
4. With `v4.4` and later, hidden files are excluded by default.
78-
79-
For assistance with breaking changes, see [MIGRATION.md](docs/MIGRATION.md).
41+
Check out the [releases page](https://github.com/actions/upload-artifact/releases) for details on what's new.
8042

8143
## Note
8244

83-
Thank you for your interest in this GitHub repo, however, right now we are not taking contributions.
45+
Thank you for your interest in this GitHub repo, however, right now we are not taking contributions.
8446

8547
We continue to focus our resources on strategic areas that help our customers be successful while making developers' lives easier. While GitHub Actions remains a key part of this vision, we are allocating resources towards other areas of Actions and are not taking contributions to this repository at this time. The GitHub public roadmap is the best place to follow along for any updates on features we’re working on and what stage they’re in.
8648

@@ -96,6 +58,10 @@ We will still provide security updates for this project and fix major breaking c
9658

9759
You are welcome to still raise bugs in this repo.
9860

61+
## GHES Support
62+
63+
`upload-artifact@v4+` is not currently supported on GitHub Enterprise Server (GHES). If you are on GHES, you must use [v3.2.2](https://github.com/actions/upload-artifact/releases/tag/v3.2.2) (Node 24) or [v3.2.2-node20](https://github.com/actions/upload-artifact/releases/tag/v3.2.2-node20) (Node 20).
64+
9965
## Usage
10066

10167
### Inputs
@@ -142,6 +108,11 @@ You are welcome to still raise bugs in this repo.
142108
# enabled this to avoid uploading sensitive information.
143109
# Optional. Default is 'false'
144110
include-hidden-files:
111+
112+
# Whether to zip the artifact files before upload
113+
# If 'false', only a single file can be uploaded. The name of the file will be used as the artifact name (the 'name' parameter is ignored)
114+
# Optional. Default is 'true'
115+
archive:
145116
```
146117
147118
### Outputs
@@ -154,7 +125,7 @@ You are welcome to still raise bugs in this repo.
154125

155126
## Examples
156127

157-
### Upload an Individual File
128+
### Upload an Individual File (Zipped)
158129

159130
```yaml
160131
steps:
@@ -166,6 +137,18 @@ steps:
166137
path: path/to/artifact/world.txt
167138
```
168139

140+
### Upload an Individual File (Unzipped)
141+
142+
```yaml
143+
steps:
144+
- run: mkdir -p path/to/artifact
145+
- run: echo hello > path/to/artifact/world.txt
146+
- uses: actions/upload-artifact@v4
147+
with:
148+
path: path/to/artifact/world.txt
149+
archive: false
150+
```
151+
169152
### Upload an Entire Directory
170153

171154
```yaml
@@ -476,15 +459,11 @@ Within an individual job, there is a limit of 500 artifacts that can be created
476459

477460
You may also be limited by Artifacts if you have exceeded your shared storage quota. Storage is calculated every 6-12 hours. See [the documentation](https://docs.github.com/en/billing/managing-billing-for-github-actions/about-billing-for-github-actions#calculating-minute-and-storage-spending) for more info.
478461

479-
### Zip archives
480-
481-
When an Artifact is uploaded, all the files are assembled into an immutable Zip archive. There is currently no way to download artifacts in a format other than a Zip or to download individual artifact contents.
482-
483462
### Permission Loss
484463

485-
File permissions are not maintained during artifact upload. All directories will have `755` and all files will have `644`. For example, if you make a file executable using `chmod` and then upload that file, post-download the file is no longer guaranteed to be set as an executable.
464+
File permissions are not maintained during zipped artifact upload. All directories will have `755` and all files will have `644`. For example, if you make a file executable using `chmod` and then upload that file with `archive: true`, post-download the file is no longer guaranteed to be set as an executable.
486465

487-
If you must preserve permissions, you can `tar` all of your files together before artifact upload. Post download, the `tar` file will maintain file permissions and case sensitivity.
466+
If you must preserve permissions, you can `tar` all of your files together before artifact upload and upload that file directly with `archive: false`. Post download, the `tar` file will maintain file permissions and case sensitivity.
488467

489468
```yaml
490469
- name: 'Tar files'
@@ -493,8 +472,8 @@ If you must preserve permissions, you can `tar` all of your files together befor
493472
- name: 'Upload Artifact'
494473
uses: actions/upload-artifact@v4
495474
with:
496-
name: my-artifact
497475
path: my_files.tar
476+
archive: false
498477
```
499478

500479
## Where does the upload go?

0 commit comments

Comments
 (0)