Overleaf is a popular LaTeX editor used for writing resumes. But the free-tier plan lacks Git and cloud drive integration. So every time you update your resume, you have to manually download the latest pdf for sharing - which quickly becomes tedious.
This GitHub action solves this by automatically fetching the latest pdf from overleaf and commits it to your GitHub repo, from where it can be easily hosted and shared.
Note
Privacy: If you prefer not to store your resume in a public repo, use a private repo and Google Drive Sync to keep your shareable resume link up to date.
name: Sync Overleaf PDF
permissions:
contents: write
on:
schedule:
- cron: '0 0 * * *' # Daily at midnight
workflow_dispatch: # For manual trigger
jobs:
get-pdf:
runs-on: ubuntu-latest
steps:
- uses: Sbrjt/overleaf-resume-syncer@v2
with:
overleaf_url: 'https://www.overleaf.com/read/your-project-id' # Replace with your overleaf sharing link (not your project url!)
# Optional:
gdrive_link: ${{ vars.GDRIVE_LINK }}
gdrive_service_account_key: ${{ secrets.GDRIVE_SERVICE_ACCOUNT_KEY }}Detailed Steps
resume-syncer.mp4
- Open your project on Overleaf.
- Click Share in the top-right corner.
- Enable Link Sharing and copy the view-only link.
- Create a repo to host your resume (or fork this template).
Create a workflow at
.github/workflows/update-resume.ymlusing the example above. - Provide the
overleaf_url(or you can use a repo Variable). - Run the workflow once (Actions > Fetch Overleaf Resume > Run workflow).
- (Optional) Enable GitHub Pages to host your resume.
[!NOTE] This setup is a pain in the ass—but you only have to do it once.
- Go to Google Cloud Console. See video.
- Create a project and enable the Google Drive API.
- Create a Service Account under IAM & Admin > Service Accounts.
- Generate a JSON service account key (Keys > Add Key > Create new key > JSON) and download it.
- Create a blank
resume.pdffile in Google Drive. - Share the file with the service account's email address (eg
your-uploader@...iam.gserviceaccount.com) with Editor permission, then copy its share link. - Navigate to Settings > Secrets and variables > Actions:
- Under Variables, add:
GDRIVE_LINK: eg,https://drive.google.com/file/d/.../view?...
- Under Secrets, add:
GDRIVE_SERVICE_ACCOUNT_KEY: The entire JSON content of the downloaded service account key file.
- Under Variables, add:
The most trivial solution might seem like having some latex previewer/builder and editing the .tex file locally. But TeX distributions like TeX-live are huge and can be a hassle to set up. More info here.
Using Selenium sidesteps Overleaf's protections (which block curl and unauthenticated scrapers) by simulating an actual user session.