Skip to content

Commit 58a9c1f

Browse files
committed
Adding workflow to create an artifact
1 parent b405e06 commit 58a9c1f

File tree

1 file changed

+23
-0
lines changed

1 file changed

+23
-0
lines changed
Lines changed: 23 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,23 @@
1+
name: Create Repository Artifact
2+
3+
on:
4+
push:
5+
branches:
6+
- main
7+
workflow_dispatch: # Allows manual trigger from the GitHub UI
8+
9+
jobs:
10+
build-and-archive:
11+
runs-on: ubuntu-latest
12+
steps:
13+
- name: Checkout repository
14+
uses: actions/checkout@v4
15+
16+
- name: Archive repository files
17+
run: zip -r repository-archive.zip .
18+
19+
- name: Upload artifact
20+
uses: actions/upload-artifact@v4
21+
with:
22+
name: repo-archive-${{ github.sha }} # Unique name based on the commit SHA
23+
path: repository-archive.zip

0 commit comments

Comments
 (0)