Add LaTeX install

main
Ethan Reece 2024-11-22 01:56:47 -06:00
parent c73bebb710
commit e695521dfa
Signed by: me
GPG Key ID: 198E9EB433DB1B28
6 changed files with 37 additions and 20 deletions

View File

@ -1,8 +1,5 @@
default: default:
guix time-machine --channels=./channels.scm.lock -- shell --container --emulate-fhs --manifest=./manifest.scm -- sh -c "mkdir -p ./out && typst compile ./src/document.typ ./out/document.pdf --font-path=/usr/share/fonts" guix time-machine --channels=./channels.scm.lock -- shell --container --emulate-fhs --manifest=./manifest.scm -- sh -c "mkdir -p ./out && pdflatex -output-directory=./out ./src/document.tex"
fonts:
guix time-machine --channels=./channels.scm.lock -- shell --container --emulate-fhs --manifest=./manifest.scm -- typst fonts --font-path=/usr/share/fonts
dev: dev:
guix time-machine --channels=./channels.scm.lock -- shell --manifest=./manifest.scm guix time-machine --channels=./channels.scm.lock -- shell --manifest=./manifest.scm

View File

@ -1,4 +1,4 @@
# Guix Typst project template # Guix LaTeX project template
1. Modify `./guix/modules/template-package.scm` (defines the project), `./channels.scm` (for project dependencies), and `./manifest.scm` (for development environment) to your requirements. 1. Modify `./guix/modules/template-package.scm` (defines the project), `./channels.scm` (for project dependencies), and `./manifest.scm` (for development environment) to your requirements.
@ -6,4 +6,4 @@
1. Run `just update` to update the dependencies. 1. Run `just update` to update the dependencies.
1. Run `just` to generate the document. Run `just run` to generate then open the document. Run `just dev` to open a shell environment with the document's dependencies. Run `just fonts` to show the available fonts. 1. Run `just` to generate the document. Run `just run` to generate then open the document. Run `just dev` to open a shell environment with the document's dependencies.

View File

@ -6,13 +6,4 @@
(make-channel-introduction (make-channel-introduction
"9edb3f66fd807b096b48283debdcddccfea34bad" "9edb3f66fd807b096b48283debdcddccfea34bad"
(openpgp-fingerprint (openpgp-fingerprint
"BBB0 2DDF 2CEA F6A8 0D1D E643 A2A0 6DF2 A33A 54FA")))) "BBB0 2DDF 2CEA F6A8 0D1D E643 A2A0 6DF2 A33A 54FA")))))
(channel
(name 'saayix)
(url "https://codeberg.org/look/saayix")
(branch "main")
(introduction
(make-channel-introduction
"12540f593092e9a177eb8a974a57bb4892327752"
(openpgp-fingerprint
"3FFA 7335 973E 0A49 47FC 0A8C 38D5 96BE 07D3 34AB")))))

View File

@ -1,6 +1,5 @@
(add-to-load-path ".guix/modules") (add-to-load-path ".guix/modules")
(use-modules (template-package) (use-modules (template-package)
(saayix packages typst) (gnu packages tex))
(gnu packages fontutils))
(packages->manifest (list typst fontconfig coreutils)) (packages->manifest (list texlive-scheme-basic texlive-pgf coreutils))

31
src/document.tex 100644
View File

@ -0,0 +1,31 @@
% This is a comment in LaTeX
% Preamble: This is where you define the document class, packages, and other settings
\documentclass{article}
\usepackage[utf8]{inputenc}
\usepackage{amsmath}
% Document environment: This is where you write the content of your document
\begin{document}
% Title and author
\title{My Simple LaTeX Document}
\author{Your Name}
\date{\today}
\maketitle
% Introduction
\section{Introduction}
This is a simple LaTeX document.
% Math example
\section{Math Example}
The quadratic formula is given by:
$$x = \frac{-b \pm \sqrt{b^2 - 4ac}}{2a}$$
% Conclusion
\section{Conclusion}
This is the end of my simple LaTeX document.
\end{document}

View File

@ -1 +0,0 @@
This document is located in `src/document.typ`.