Skip to content

Commit

Permalink
refactor: update latex source hierarchy
Browse files Browse the repository at this point in the history
Collect the latex source files in a src directory and update the
corresponding GitHub actions workflow.
  • Loading branch information
tunakasif committed Jul 18, 2024
1 parent d394eef commit 50312e4
Show file tree
Hide file tree
Showing 6 changed files with 11 additions and 8 deletions.
7 changes: 5 additions & 2 deletions .github/workflows/release.yml
Original file line number Diff line number Diff line change
Expand Up @@ -13,9 +13,12 @@ jobs:
- name: Compile LaTeX Document
uses: xu-cheng/latex-action@v2
with:
root_file: main.tex
work_in_root_file_dir: true
root_file: |
src/main.tex
- name: Release
uses: softprops/action-gh-release@v1
with:
generate_release_notes: true
files: main.pdf
files: |
src/main.pdf
12 changes: 6 additions & 6 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,6 @@

Template for writing CI enabled LaTeX documents. According to the version number provided with a [git-tag](https://git-scm.com/book/en/v2/Git-Basics-Tagging), state of the LaTeX project and its PDF output are saved as release assets.


## Usage

Make changes to the LaTeX documents, and provide [git-tags](https://git-scm.com/book/en/v2/Git-Basics-Tagging) to the commits where you see fit, with annotations regarding the version as in the form of `v*` (e.g. v1.0.2). A PDF file will automatically be generated from the tags. In the wake of PDF generation, it will be used as an additional asset for the automatic release based on the provided tag. This template is written in a self-evident manner, hence for demonstration, checkout the [Releases](https://github.com/tunakasif/latex-ci-template/releases) page.
Expand All @@ -28,11 +27,12 @@ The sample LaTeX document hierarchy is in the form below. It is a minimal demons

```stdout
.
├── bibliography.bib
├── images
│   └── space.jpg
├── main.tex
├── my_table.tex
└── src
├── images
│   └── space.jpg
├── bibliography.bib
├── main.tex
└── my_table.tex
```

As expected, building process depends on the document hierarchy. This template is designed for the base case provided in [xu-cheng/latex-action@v2](https://github.com/xu-cheng/latex-action) such that we have a single `root_file: main.tex`, and we are compiling with default settings of [xu-cheng/latex-action@v2](https://github.com/xu-cheng/latex-action). The provided hierarchy can be changed easily, however [`release.yml`](./.github/workflows/release.yml) needs to be changed, accordingly. Since [xu-cheng/latex-action@v2](https://github.com/xu-cheng/latex-action) provides a rich documentation, this aspect should not be problematic.
Expand Down
File renamed without changes.
File renamed without changes
File renamed without changes.
File renamed without changes.

0 comments on commit 50312e4

Please sign in to comment.