Add texlive2024 bundle (#1230)
This commit is contained in:
commit
34d643ffb0
|
@ -1,7 +1,16 @@
|
|||
# Build files
|
||||
/cross
|
||||
/docs/book/*
|
||||
/target
|
||||
|
||||
# Tests
|
||||
/tests/plain.fmt
|
||||
/tests/00*00-latex-*.fmt
|
||||
/tests/*-plain-*.fmt
|
||||
/tests/xenia/paper.pdf
|
||||
|
||||
# Tectonic bundles
|
||||
*.ttb
|
||||
|
||||
# Misc
|
||||
*.ignore
|
|
@ -0,0 +1,89 @@
|
|||
[bundle]
|
||||
name = "texlive2024-0312"
|
||||
expected_hash = "8fae742a1d9453fc3abfe7c6971363696f611ade1266c17788ccb5c18ffd1312"
|
||||
|
||||
search_order = ["/", { input = "include" }, { input = "texlive" }]
|
||||
|
||||
# Note the triple-quoted multiline strings:
|
||||
# this is the best way to get raw strings in TOML.
|
||||
ignore = [
|
||||
# Files and extensions we usually want to ignore.
|
||||
'''.*/00readme\.txt''',
|
||||
'''.*/LICENSE\.md''',
|
||||
'''.*/Makefile''',
|
||||
'''.*/README''',
|
||||
'''.*/README.md''',
|
||||
'''.*/readme\.txt''',
|
||||
'''.*/ls-R''',
|
||||
'''.*\.fmt''',
|
||||
'''.*\.log''',
|
||||
'''.*\.lua''',
|
||||
'''.*\.mf''',
|
||||
'''.*\.pl''',
|
||||
'''.*\.ps''',
|
||||
]
|
||||
|
||||
|
||||
[inputs."include"]
|
||||
source.dir.path = "include"
|
||||
|
||||
|
||||
# Requires texlive-20240312-texmf, which is available at
|
||||
# https://ftp.math.utah.edu/pub/tex/historic/systems/texlive/2024/texlive-20240312-texmf.tar.xz
|
||||
# download and extract this file as a .tar in this directory.
|
||||
[inputs."texlive"]
|
||||
source.tarball.path = "texlive-20240312-texmf.tar"
|
||||
source.tarball.hash = "87f7f5fd9618689cd9ae436ad37cefe43fabf1f2f457ac3860ec2aa854578d20"
|
||||
source.tarball.root_dir = "texlive-20240312-texmf/texmf-dist"
|
||||
patch_dir = "patches/texlive"
|
||||
|
||||
ignore = [
|
||||
# I don't think tectonic has xindy support, ignore for now
|
||||
'''xindy/.*''',
|
||||
|
||||
# We may need this, but exclude for now.
|
||||
'''tex4ht/.*''',
|
||||
|
||||
# These require pLaTeX2e, tectonic uses XeTeX
|
||||
'''tex/uplatex/.*''',
|
||||
'''tex/uptex/.*''',
|
||||
|
||||
# Other odd tex formats & unnecessary files
|
||||
'''tex/cslatex/.*''',
|
||||
'''tex/csplain/.*''',
|
||||
'''tex/ptex/.*''',
|
||||
'''tex/platex/.*''',
|
||||
'''tex/lollipop/.*''',
|
||||
'''tex/context/.*''',
|
||||
'''context/.*''',
|
||||
'''texdoc/.*''',
|
||||
'''texdoctk/.*''',
|
||||
'''texconfig/.*''',
|
||||
'''scripts/.*''',
|
||||
'''dvips/.*''',
|
||||
'''asymptote/.*''',
|
||||
'''makeindex/.*''',
|
||||
'''luatex-cache/.*''',
|
||||
'''hb2gf/.*''',
|
||||
'''chktex/.*''',
|
||||
'''source/.*''',
|
||||
'''doc/.*''',
|
||||
'''tex/luatex/.*''',
|
||||
'''tex/lualatex/.*''',
|
||||
'''tex/lambda/.*''',
|
||||
'''omega/.*''',
|
||||
]
|
||||
|
||||
search_order = [
|
||||
"tex/{xelatex,latex,xetex,plain,generic}//",
|
||||
"bibtex/{bib,bst,csf}//",
|
||||
"web2c//",
|
||||
"fonts//",
|
||||
"biber//",
|
||||
"mft//",
|
||||
"dvips//",
|
||||
"makeindex//",
|
||||
"{web,cweb}//",
|
||||
"ttf2pk//",
|
||||
"dvipdfmx/",
|
||||
]
|
|
@ -0,0 +1 @@
|
|||
\input xelatex.ini
|
|
@ -0,0 +1 @@
|
|||
\input plain \dump
|
|
@ -0,0 +1,24 @@
|
|||
tex/latex/fithesis/style/mu/fithesis-mu-base.sty
|
||||
131c131,138
|
||||
< \setmainfont[Ligatures=TeX]{TeX Gyre Pagella}
|
||||
---
|
||||
> \setmainfont{texgyrepagella}[
|
||||
> Ligatures = TeX,
|
||||
> Extension = .otf,
|
||||
> UprightFont = *-regular,
|
||||
> ItalicFont = *-italic,
|
||||
> BoldFont = *-bold,
|
||||
> BoldItalicFont = *-bolditalic,
|
||||
> ]
|
||||
136c143,151
|
||||
< \setsansfont[Ligatures=TeX,Scale=MatchLowercase]{TeX Gyre Heros}
|
||||
---
|
||||
> \setmainfont{texgyreheros}[
|
||||
> Ligatures = TeX,
|
||||
> Scale = MatchLowercase,
|
||||
> Extension = .otf,
|
||||
> UprightFont = *-regular,
|
||||
> ItalicFont = *-italic,
|
||||
> BoldFont = *-bold,
|
||||
> BoldItalicFont = *-bolditalic,
|
||||
> ]
|
|
@ -0,0 +1,5 @@
|
|||
tex/latex/fontawesome/fontawesome.sty
|
||||
45c45
|
||||
< \newfontfamily{\FA}{FontAwesome}
|
||||
---
|
||||
> \newfontfamily{\FA}{FontAwesome.otf}
|
|
@ -0,0 +1,32 @@
|
|||
tex/{latex,latex-dev}/base/latex.ltx
|
||||
7211,7237c7211,7212
|
||||
< \typeout{^^J! LaTeX Error: File `#1.#2' not found.^^J^^J%
|
||||
< Type X to quit or <RETURN> to proceed,^^J%
|
||||
< or enter new name. (Default extension: #2)^^J}%
|
||||
< \message{Enter file name: }%
|
||||
< {\endlinechar\m@ne
|
||||
< \global\read\m@ne to\@gtempa}%
|
||||
< \ifx\@gtempa\@empty
|
||||
< \let\@missingfile@area\@empty
|
||||
< \let\@missingfile@base\@empty
|
||||
< \def\@missingfile@ext{tex}%
|
||||
< \else
|
||||
< \def\reserved@b{\batchmode\read-1 to \reserved@a}%
|
||||
< \def\reserved@a{x}\ifx\reserved@a\@gtempa\reserved@b\fi
|
||||
< \def\reserved@a{X}\ifx\reserved@a\@gtempa\reserved@b\fi
|
||||
< \filename@parse\@gtempa
|
||||
< \edef\filename@ext{%
|
||||
< \ifx\filename@ext\relax#2\else\filename@ext\fi}%
|
||||
< \edef\reserved@a{%
|
||||
< \noexpand\IfFileExists
|
||||
< {\filename@area\filename@base.\filename@ext}%
|
||||
< {\def\noexpand\@missingfile@area{\filename@area}%
|
||||
< \def\noexpand\@missingfile@base{\filename@base}%
|
||||
< \def\noexpand\@missingfile@ext {\filename@ext}}%
|
||||
< {\noexpand\@missingfileerror
|
||||
< {\filename@area\filename@base}{\filename@ext}}}%
|
||||
< \reserved@a
|
||||
< \fi
|
||||
---
|
||||
> % Tectonic: no terminal input allowed, so this is always a fatal error.
|
||||
> \errmessage{! LaTeX Error: File `#1.#2' not found.}%
|
|
@ -0,0 +1,25 @@
|
|||
tex/latex/listings/listings.sty
|
||||
2057,2075c2057,2059
|
||||
< \typeout{^^J! Package Listings Error: File `#1(.#2)' not found.^^J%
|
||||
< ^^JType X to quit or <RETURN> to proceed,^^J%
|
||||
< or enter new name. (Default extension: #2)^^J}%
|
||||
< \message{Enter file name: }%
|
||||
< {\endlinechar\m@ne \global\read\m@ne to\@gtempa}%
|
||||
< \ifx\@gtempa\@empty \else
|
||||
< \def\reserved@a{x}\ifx\reserved@a\@gtempa\batchmode\@@end\fi
|
||||
< \def\reserved@a{X}\ifx\reserved@a\@gtempa\batchmode\@@end\fi
|
||||
< \filename@parse\@gtempa
|
||||
< \edef\filename@ext{%
|
||||
< \ifx\filename@ext\relax#2\else\filename@ext\fi}%
|
||||
< \edef\reserved@a{\noexpand\IfFileExists %
|
||||
< {\filename@area\filename@base.\filename@ext}%
|
||||
< {\noexpand\lst@InputListing %
|
||||
< {\filename@area\filename@base.\filename@ext}}%
|
||||
< {\noexpand\lst@MissingFileError
|
||||
< {\filename@area\filename@base}{\filename@ext}}}%
|
||||
< \expandafter\reserved@a %
|
||||
< \fi}
|
||||
---
|
||||
> % Tectonic: no terminal input allowed, so this is always a fatal error.
|
||||
> \errmessage{! Package Listings Error: File `#1(.#2)' not found.}%
|
||||
> }
|
|
@ -38,32 +38,27 @@ pub(super) fn select(cli: &BundleCreateCommand) -> Result<()> {
|
|||
return Err(e);
|
||||
};
|
||||
|
||||
let build_dir = cli.build_dir.join(&bundle_config.bundle.name);
|
||||
|
||||
// Remove build dir if it exists
|
||||
if cli.build_dir.exists() {
|
||||
warn!(
|
||||
"build dir {} aleady exists",
|
||||
cli.build_dir.to_str().unwrap()
|
||||
);
|
||||
if build_dir.exists() {
|
||||
warn!("build dir {} aleady exists", build_dir.to_str().unwrap());
|
||||
|
||||
for i in (1..=5).rev() {
|
||||
warn!(
|
||||
"recursively removing {} in {i} second{}",
|
||||
cli.build_dir.to_str().unwrap(),
|
||||
build_dir.to_str().unwrap(),
|
||||
if i != 1 { "s" } else { "" }
|
||||
);
|
||||
thread::sleep(Duration::from_secs(1));
|
||||
}
|
||||
thread::sleep(Duration::from_secs(2));
|
||||
|
||||
fs::remove_dir_all(&cli.build_dir)?;
|
||||
fs::remove_dir_all(&build_dir)?;
|
||||
}
|
||||
fs::create_dir_all(&cli.build_dir).context("while creating build dir")?;
|
||||
fs::create_dir_all(&build_dir).context("while creating build dir")?;
|
||||
|
||||
let mut picker = FilePicker::new(
|
||||
bundle_config.clone(),
|
||||
cli.build_dir.clone(),
|
||||
bundle_dir.clone(),
|
||||
)?;
|
||||
let mut picker = FilePicker::new(bundle_config.clone(), build_dir.clone(), bundle_dir.clone())?;
|
||||
|
||||
// Run selector
|
||||
let sources: Vec<String> = picker.iter_sources().map(|x| x.to_string()).collect();
|
||||
|
@ -110,16 +105,18 @@ pub(super) fn pack(cli: &BundleCreateCommand) -> Result<()> {
|
|||
file.read_to_string(&mut file_str)?;
|
||||
let bundle_config: BundleSpec = toml::from_str(&file_str)?;
|
||||
|
||||
let build_dir = cli.build_dir.join(&bundle_config.bundle.name);
|
||||
|
||||
if !cli.build_dir.join("content").is_dir() {
|
||||
error!(
|
||||
"content directory `{}/content` doesn't exist, can't continue",
|
||||
cli.build_dir.to_str().unwrap()
|
||||
build_dir.to_str().unwrap()
|
||||
);
|
||||
return Ok(());
|
||||
}
|
||||
|
||||
let target_name = format!("{}.ttb", &bundle_config.bundle.name);
|
||||
let target = cli.build_dir.join(&target_name);
|
||||
let target = build_dir.join(&target_name);
|
||||
if target.exists() {
|
||||
if target.is_file() {
|
||||
warn!("target bundle `{target_name}` exists, removing");
|
||||
|
@ -132,7 +129,7 @@ pub(super) fn pack(cli: &BundleCreateCommand) -> Result<()> {
|
|||
|
||||
match cli.format {
|
||||
BundleFormat::BundleV1 => {
|
||||
BundleV1::make(Box::new(File::create(target)?), cli.build_dir.clone())?
|
||||
BundleV1::make(Box::new(File::create(target)?), build_dir.clone())?
|
||||
}
|
||||
}
|
||||
|
||||
|
|
|
@ -420,14 +420,14 @@ impl FilePicker {
|
|||
if x.hash().unwrap() != hash {
|
||||
if cli.allow_hash_mismatch {
|
||||
warn!("hash of tarball for source `{source}` doesn't match expected value");
|
||||
warn!("expected: {}", x.hash().unwrap());
|
||||
warn!("got: {}", hash);
|
||||
warn!("expected: {}", hash);
|
||||
warn!("got: {}", x.hash().unwrap());
|
||||
} else {
|
||||
error!(
|
||||
"hash of tarball for source `{source}` doesn't match expected value"
|
||||
);
|
||||
error!("expected: {}", x.hash().unwrap());
|
||||
error!("got: {}", hash);
|
||||
error!("expected: {}", hash);
|
||||
error!("got: {}", x.hash().unwrap());
|
||||
bail!("hash of tarball for source `{source}` doesn't match expected value")
|
||||
}
|
||||
}
|
||||
|
|
Loading…
Reference in New Issue