MO
moehami/unzip-and-update-action
Upload Zipped file to GitHub and unzip it in seconds
Unzip and Update Repository Content Action
This GitHub Action unzips a specified .zip file, optionally removes target directories, moves the extracted content to the repository root, and commits the changes.
Usage
Create a workflow file (e.g., .github/workflows/my-unzip-workflow.yml) in your repository:
name: Deploy Unzipped Content
on:
workflow_dispatch:
inputs:
zip_path:
description: 'Path to the zip file to extract'
required: true
default: 'my-build/output.zip'
jobs:
deploy:
runs-on: ubuntu-latest
steps:
- name: Checkout repository
uses: actions/checkout@v3
- name: Use my Unzip Action
uses: your-username/unzip-and-update-action@v1 # Replace with your actual repo and version
with:
zip_file_path: ${{ github.event.inputs.zip_path }}
target_directories_to_clean: 'css,en,fonts,js' # Optional
extracted_subfolder: 'my-unzipped-root-folder' # Optional, if your zip contains a top-level folder
- name: Verify extracted content (optional)
run: ls -laOn this page
Contributors
Created June 22, 2025
Updated June 22, 2025