diff --git a/Justfile b/Justfile index 3294ea7..b85f431 100644 --- a/Justfile +++ b/Justfile @@ -1,8 +1,5 @@ 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" - -fonts: - guix time-machine --channels=./channels.scm.lock -- shell --container --emulate-fhs --manifest=./manifest.scm -- typst fonts --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" dev: guix time-machine --channels=./channels.scm.lock -- shell --manifest=./manifest.scm diff --git a/README.md b/README.md index 7d0a665..fc5d04a 100644 --- a/README.md +++ b/README.md @@ -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. @@ -6,4 +6,4 @@ 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. diff --git a/channels.scm b/channels.scm index f98373c..ef2ae0d 100644 --- a/channels.scm +++ b/channels.scm @@ -6,13 +6,4 @@ (make-channel-introduction "9edb3f66fd807b096b48283debdcddccfea34bad" (openpgp-fingerprint - "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"))))) + "BBB0 2DDF 2CEA F6A8 0D1D E643 A2A0 6DF2 A33A 54FA"))))) diff --git a/manifest.scm b/manifest.scm index 5df8109..8edc3d0 100644 --- a/manifest.scm +++ b/manifest.scm @@ -1,6 +1,5 @@ (add-to-load-path ".guix/modules") (use-modules (template-package) - (saayix packages typst) - (gnu packages fontutils)) + (gnu packages tex)) -(packages->manifest (list typst fontconfig coreutils)) +(packages->manifest (list texlive-scheme-basic texlive-pgf coreutils)) diff --git a/src/document.tex b/src/document.tex new file mode 100644 index 0000000..1e34605 --- /dev/null +++ b/src/document.tex @@ -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} + diff --git a/src/document.typ b/src/document.typ deleted file mode 100644 index f1e87ac..0000000 --- a/src/document.typ +++ /dev/null @@ -1 +0,0 @@ -This document is located in `src/document.typ`.