From: bochard Date: Wed, 23 Jul 2025 12:44:30 +0000 (+0800) Subject: update README X-Git-Url: https://git.bochard.net/?a=commitdiff_plain;h=5b39926f800f17728c1a5c7f35bc028424290bb6;p=sync-works.sh.git update README --- diff --git a/README.md b/README.md index 2b7d98a..dd51a68 100644 --- a/README.md +++ b/README.md @@ -1,9 +1,31 @@ # sync-works.sh Update Git submodules on a final directory and removing the `.git` file. -## process... +## How it works? 1. Read the list of submodules in the `works-list.txt` file. +2. Creates two directory: `/works-tmp` and `works/`. 2. Checks if submodules from the txt file exists within `works-tmp` folder. If not, add it. 3. Update the submodules in their remote latest commit. 4. Copy the submodules from the `works-tmp` directory to the `works` directory while removing `.git` contents simultaneously. -5. Automatically stage and commit the changes. \ No newline at end of file +5. Automatically stage and commit the changes. + +## How to use? +1. Open the directory +``` +cd path/to/sync-works.sh/ +``` +2. Copy to your project +``` +cp './sync-work.sh' 'path/to/your/project/' +``` +3. Give permission to execute +``` +chmod +x ./sync-works.sh +``` +4. Then, run... +``` +./sync-works.sh +``` +5. Enjoy! + +---