Using gihub action for creating digital book

Hi
I’m a newbie in Github Actions, I intend to create my digital book with Github Actions, I intend to make a repository that contains folders and subfolders for each chapter, section, and article of my book.
I intend to make a script alongside Actions, whenever I update any part of the repository , the script concat these part and make an identical file
I really appreciate any guide or help

That’s possible in principle, but how to do it depends on the format you’re using for the book. Are you looking to just concatenate text files, or render something (e.g. Markdown or LaTeX to PDF)?

Tnx for the comments, I may use the simple text format such word rtf or html for final version
I have experience in python and I can make this script, but I was wondering how to use such programs in my github action script

If you have a script that does what you need, add it to your repository, and call it in a run step in your workflow. Note that you’ll have to install any dependencies before.

thx for the reply, I create mockup files in new reposiory
https://github.com/KavehSons/tools/tree/main/book
and try to make a sample script for running this job, however, another problem raised
in python code , should find the the sections files in subcategories and then concat the text files
Github Action has a command for define input and output for scripts as well as could run bash script in Linux environment
I was wonder which approach would be fast and best option rather than using FTP python library for expelorereing the flies in subdirecores

The script looks almost like you’re trying to download the files individually. There’s no need to do that, just use actions/checkout to get your repository and work work with the local files.

You can find some examples that check out a repository, build in some way, and store the result as an artifact in the documentation: Storing workflow data as artifacts - GitHub Docs