Skip to content

Commit

Permalink
doc: worked on ci
Browse files Browse the repository at this point in the history
  • Loading branch information
BRAVO68WEB committed Aug 1, 2024
1 parent d4d081e commit 6d2e03e
Show file tree
Hide file tree
Showing 9 changed files with 32 additions and 614 deletions.
121 changes: 4 additions & 117 deletions .github/README.md
Original file line number Diff line number Diff line change
@@ -1,137 +1,24 @@
<h1 align="center">Alicia Sykes - CV</h1>
<h1 align="center">Jyotirmoy Bandyopadhayaya - CV</h1>
<p align="center">
<!-- <a href="https://github.com/Lissy93/cv"><img src="https://i.ibb.co/8BV5p7L/CV-Logo-Alicia-Sykes.png" width="128" /><br /></a> -->
<i>This repo contains the source for my personal CV</i>
<br />
<b>🌐 <a href="https://cv.aliciasykes.com/">cv.aliciasykes.com</a> | 📄 <a href="https://cv.aliciasykes.com/cv.pdf"><code>Alicia-Sykes-CV.pdf</code></a></b> <br />
</p>
<br />




> **Motivation**<br>
> Why spend 30 minutes writing your CV, when you could spend 30 hours automating it?

The resume content is defined in [`resume.yml`]() following the [jsonresume.org](https://jsonresume.org/) standard, and validated against [`schema.json`](/schema.json).
A LaTex document is then generated from [`template.jinja`](/template.jinja) formated with [`resume-format.cls`](/tex/resume-format.cls), which is then compiled into a PDF by GitHub Actions, and published under the [Releases]() tab.
A markdown version is also generated by [`lib/markdown.py`](/lib/markdown.py), as well as a CV website which is built as a static Svelte site and deployed to GitHub Pages at [cv.aliciasykes.com](https://aliciasykes.com)


---

## Usage

### Option #1 - GitHub
Upon creating a tag (by triggering the [Tag Workflow](/.github/workflows/tag.yml)), a new Release will be drafted with your compiled CV PDF attatched

1. Fork the repo
2. Update resume.json with your own content
2. Update resume.yaml with your own content
3. Trigger the GitHub Action to compile the PDF


<details><summary>Workflows</summary>

- `tag` - Creates a new Git tag. Optionally specify the tag name and description, or by default it will just bump the sem ver patch number by 1
- `generate` - Generates your resume in PDF form as an artifact. If triggered by a tag, then a new release will be created, with the PDF attatched
- `validate` - Validates your resume data against the schema. This will also run whenever a new PR is opened, to ensure it's valid and working
</details>

---

### Option #2 - Local
See the [`Makefile`](/Makefile) for all the available commands. Or, just run `make` from the root, to install deps, validate content, generate LaTex, and compile PDF

1. Clone the repo
2. Update resume.json with your own content
3. Run `make` from the root, to install deps, validate content, generate LaTex, and compile PDF

<details><summary>Commands</summary>

- `make install` - Download dependencies
- `make validate` - Validate content
- `make generate` - Generate LaTex
- `make compile` - Compile PDF
- `make clean` - Remove generated files
- `make watch` - Watch for changes, recompile and refresh
</details>

---

### Editing
Modify data by editing [`resume.yml`](/resume.yml)<br>
If you need to customize the layout, edit [`template.jinja`](/template.jinja)<br>
Or to change the styles and formatting, edit [`resume-format.cls`](/lib/resume-format.cls)<br>
All the scripts used to generate output are located in [`lib/`](/lib/)<br>
These are triggered either by the [`Makefile`](/Makefile) or via GitHub Actions with the [`workflows/`](/.github/workflows)<br>
The source for the website version is located in [`web/`](/web)

---

## Attributions

### Contributors

![Contributors](https://readme-contribs.as93.net/contributors/lissy93/cv)

### Sponsors

![Sponsors](https://readme-contribs.as93.net/sponsors/lissy93)

---

## License

> _**[Lissy93/CV](https://github.com/Lissy93/cv)** is licensed under [MIT](https://github.com/Lissy93/cv/blob/HEAD/LICENSE) © [Alicia Sykes](https://aliciasykes.com) 2024._<br>
> <sup align="right">For information, see <a href="https://tldrlegal.com/license/mit-license">TLDR Legal > MIT</a></sup>
<details>
<summary>Expand License</summary>

```
The MIT License (MIT)
Copyright (c) Alicia Sykes <alicia@omg.com>
Permission is hereby granted, free of charge, to any person obtaining a copy
of this software and associated documentation files (the "Software"), to deal
in the Software without restriction, including without limitation the rights
to use, copy, modify, merge, publish, distribute, sub-license, and/or sell
copies of the Software, and to permit persons to whom the Software is furnished
to do so, subject to the following conditions:
The above copyright notice and this permission notice shall be included install
copies or substantial portions of the Software.
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED,
INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANT ABILITY, FITNESS FOR A
PARTICULAR PURPOSE AND NON INFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT
HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE
SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
```

</details>

<!-- License + Copyright -->
<p align="center">
<i>© <a href="https://aliciasykes.com">Alicia Sykes</a> 2024</i><br>
<i>Licensed under <a href="https://gist.github.com/Lissy93/143d2ee01ccc5c052a17">MIT</a></i><br>
<a href="https://github.com/lissy93"><img src="https://i.ibb.co/4KtpYxb/octocat-clean-mini.png" /></a><br>
<sup>Thanks for visiting :)</sup>
</p>

<!-- Dinosaur -->
<!--
. - ~ ~ ~ - .
.. _ .-~ ~-.
//| \ `..~ `.
|| | } } / \ \
(\ \\ \~^..' | } \
\`.-~ o / } | / \
(__ | / | / `.
`- - ~ ~ -._| /_ - ~ ~ ^| /- _ `.
| / | / ~-. ~- _
|_____| |_____| ~ - . _ _~_-_
-->
Modify data by editing [`resume.yaml`](/resume.yaml)<br>

---
23 changes: 23 additions & 0 deletions .github/workflows/compile.yml
Original file line number Diff line number Diff line change
Expand Up @@ -17,6 +17,8 @@ on:

env:
PDF_NAME: Jyotirmoy_Bandyopadhayaya_CV.pdf
MISC_NAME: resume.zip
HTML_NAME: Jyotirmoy_Bandyopadhayaya_CV.html

jobs:
build:
Expand Down Expand Up @@ -50,6 +52,12 @@ jobs:
name: resume-pdf
path: out/${{ env.PDF_NAME }}

- name: 📤 Upload Misc artifact
uses: actions/upload-artifact@v2
with:
name: resume-misc-zip
path: ${{ env.MISC_NAME }}

release:
needs: build
runs-on: ubuntu-latest
Expand Down Expand Up @@ -111,6 +119,11 @@ jobs:
name: resume-pdf
path: out/

- name: 📤 Download Misc artifact
uses: actions/download-artifact@v2
with:
name: resume-misc-zip

- name: 🔑 Set up GitHub CLI
run: |
echo "${{ secrets.GITHUB_TOKEN }}" | gh auth login --with-token
Expand All @@ -119,3 +132,13 @@ jobs:
run: |
gh release create $TAG_NAME out/${{ env.PDF_NAME }} --title "Release $TAG_NAME" --notes "Generated CV PDF for release $TAG_NAME"
- name: 📄 Upload assets to docs/ folder
run: |
mkdir -p docs
cp out/${{ env.PDF_NAME }} docs/cv.pdf
cp out/${{ env.HTML_NAME }} docs/index.html
git config user.name "b68web"
git config user.email "git@b68.dev"
git add docs/
git commit -m "Add release $TAG_NAME"
git push
2 changes: 2 additions & 0 deletions Makefile
Original file line number Diff line number Diff line change
@@ -1,9 +1,11 @@
# Define variables for common paths
RESUME := resume.yaml
OUTPUT_DIR := out
ZIP_FILE := resume.zip

all: generate

# Generate the LaTeX file from the template and JSON data
generate:
rendercv render $(RESUME) --output-folder-name $(OUTPUT_DIR)
zip -r $(ZIP_FILE) $(OUTPUT_DIR)
83 changes: 0 additions & 83 deletions lib/compile.py

This file was deleted.

Loading

0 comments on commit 6d2e03e

Please sign in to comment.