Questions tagged [filesystem-access]
The filesystem-access tag has no usage guidance.
111
questions
1
vote
1answer
30 views
File extension *.pag when compiling document with pdflatex and bibtex
I'm compiling my document with pdflatex and bibtex, using the following command:
pdflatex main && bibtex main && pdflatex main && pdflatex main
This generated a couple of ...
2
votes
3answers
143 views
How to query if a file has changed (a \IfFileHasChanged conditional)?
We know \IfFileExists{<file>}{<yes>}{<no>}.
How can I create a command \IfFileHasChanged{<file>}{<yes>}{<no>}
for a file which has changed (and does exist!).
I mean ...
1
vote
0answers
39 views
Why my \AtBeginDocument and \AtEndDocument don't work in .sty file…?
I'm looking to set up a class that allows me to type a document for both teacher (complete) and students (with holes instead of text) that is differentiated using an \ifprof boolean. My macros and my ...
1
vote
0answers
27 views
Problem with latex files
I have a problem with one of my latex files. I was writing when my laptop stopped working. I don't know why, but I had to force it to restart and when I turned it on I had problem with my latex file: ...
0
votes
0answers
15 views
Set a timeout for pdflatex or latexmk disk access
My latex document includes figures located on a remote server, via a sshfs mountpoint. However, it happens that it disconnects, and if I run latexmk/pdflatex at this stage, it gets stuck trying to ...
1
vote
0answers
42 views
Use file with non-ascii letters in filename in \inputminted
I want to import some code into a LaTeX-File. The problem is, that in the path some special caracters appear. This still works fine:
\inputminted[autogobble,breaklines]{java}{C:/Path/to/my/File.java}
...
0
votes
1answer
38 views
Conditionally overriding the includegraphics command to print file size in the corresponding caption
I want to analyze the file size of each graphics file used in my report. Therefore, I am trying to implement a new command by conditionally overriding the includegraphics command to print file size in ...
0
votes
0answers
28 views
Latex - Common path name for different users using a common Dropbox folder
Is there a way to created common pathnames where the user name is automatically picked up depending on the person using the tex file. I collaborate with about 10 people, a path name such as "C:\Users\...
0
votes
1answer
41 views
Permission problems in accessing my local folder
I am having problems with file permissions in Windows 10. I am using
TeX Live 2020. PdfLaTeX/LuaLaTeX is unable to access files in my local texmf tree. I am getting the following error:
Process ...
2
votes
1answer
55 views
LuaLaTeX: How to include a generated file size in document?
How to include a generated file size in document with LuaLaTeX? Similar question was answered, but for pdflatex case here. The solution does not work with LuaLaTeX.
0
votes
0answers
31 views
Using l3file to append to a file
The code below overwrites erwlog.tex with
%pdfdate:202004[more digits]
Hello, world!
How can I make it append instead?
PS:
What's wrong with 1.a?
How to meet the requirement of 2.a?
\documentclass{...
2
votes
1answer
62 views
Which files can be found by \(pdf)filesize?
Compiling the following code with pdfTeX:
\documentclass{article}
\begin{document}
1 \pdffilesize{XITS-Regular.otf} \par
2 \pdffilesize{/usr/local/texlive/2020/texmf-dist/fonts/opentype/public/xits/...
0
votes
0answers
30 views
Accidentally restricted TexShop from a folder
I made an extremely stupid error. I installed TexShop on a new computer and the first time I went to compile a document, it asked me if it was ok for TexShop to access the Documents folder. I, ...
0
votes
1answer
167 views
XeLaTeX Can't Write to File [duplicate]
Occasionally, when running xelatex (using TeX Live 2018 on Linux Mint 19.2), I
encounter the following error message:
(/usr/local/texlive/2018/texmf-dist/tex/latex/microtype/mt-cmr.cfg))
(/usr/local/...
1
vote
0answers
149 views
Filenames and ps2pdf
System: Windows 10, MikTeX 2.9, WinEdt 10.2
Workflow: tex -> ps -> pdf
Problem: I created a file named "TeoriaTehtäviä.tex" containing two characters outside the 7 bit ASCII range. Here's what ...
1
vote
1answer
88 views
Can input command in pdflatex read files with extra long file names on Windows?
Is LaTeX (pdflatex) able to read files with extra long file names on Windows? (up to 32767 unicode characters)
https://ss64.com/nt/syntax-filenames.html
The NTFS file system supports large paths ...
4
votes
3answers
441 views
Read file contents to variable and iterate over each character in file (hexdump)
I need to read file content as string (binary file) to variable, then iterate over each character in that string, convert each character to its hexadecimal representation, use comma (or any other ...
1
vote
0answers
32 views
filename contains Chinese characters unable to be compiled by XeLaTeX [closed]
windows 10
TeXstudio 2.12.16
texlive2019 default installation
it said:
Could not start Build & View:XeLaTeX: xelatex.exe -synctex=1
-interaction=nonstopmode "hashujixian-副本".tex
but it ...
1
vote
1answer
393 views
opening a local .tex file in overleaf
I'd like to open a .tex file on my local system in overleaf.
The api allows for this over by passing the uri
https://www.overleaf.com/docs?snip_uri=http://pathtoyourfile.tex
I would like to do
...
1
vote
1answer
105 views
Recursively search parent directories when including/inputting file
I'm wondering if it's possible to modify the function of the \input command so that e.g.
\input{macros}
would work recursively.
Variant 1
Check if macros.tex exists in the current directory. If ...
0
votes
0answers
22 views
Where is the spelling exception list that TeXShop uses?
Does someone know where this file is on a Mac? I would like to access this file in order to make a copy of it, just in case TeXShop looses it...
1
vote
1answer
332 views
LuaLaTeX: How to correctly resolve absolute path with \directlua on Windows
I need to resolve absolute path to fonts:
\setmainjfont[
Path = \currfileabsdir,
UprightFont = fonts/HGS_Mincho/HGRMB.ttc,
BoldFont = fonts/HGS_Mincho/HGRME.ttc
]{HGS ...
0
votes
1answer
121 views
make tex glossaries files accessible for all documents across system
I created some rather big glossaries files with symbols, acronyms, ...
Glossary_Acronyms.tex
Glossary_Glossary.tex
Glossary_Symbols.tex
for a programming project with multiple tex documents as their ...
3
votes
1answer
425 views
Different file opened by \openin (was: between 2017 and 2018)
Short version:
It seems that some trivial behavior of file opening (\openin) changed between TeX Live 2017 and 2018 differs between environment. Only Overleaf one behaves differently. I did not see ...
5
votes
0answers
284 views
Include standalone files in subdirectories which read other files
I want to use package standalone together with PGFPlots and TikZ to generate figures.
In particular, I want figures to be generated only if missing, using buildmissing package option for standalone ...
3
votes
2answers
149 views
File name not handled correctly in /foreach loop
For some reason when I try to specify a file name for \includegraphics in a loop, either using \foreach or using \clist, I get a file not found error. The error displays a valid path for the file, and ...
4
votes
2answers
1k views
LaTeX Fonts with fontspec-package
Today i figured out how to use system-installed-fonts with the fontspec-package and LuaLaTeX. But i can't figure out how to use fonts, that are installed in my texmf-tree!
The fontspec-Manual says (...
2
votes
1answer
209 views
Write to a file outside of the current folder
Is it possible with TeX to write somewhere else than in the current folder?
The following does not work:
\documentclass{article}
\begin{document}
\newwrite\tempfile
\openout\tempfile=/Users/colas/...
0
votes
0answers
44 views
Save data from all my .tex files to a global file
I want to keep track of some info of my .tex files.
More precisely, I give an id (an integer) to my math exercises and would like to keep somewhere the maximal id already given (and maybe other info)....
0
votes
1answer
156 views
Shared MikTex install on windows server 2012 to generate PDF from IIS
I'm trying to install a shared MikTex on a Windows server 2012, so my web application (Perl CGI / IIS 8) can generate PDF files on the fly through pdflatex, and send them to the user.
I managed to ...
1
vote
1answer
159 views
Export code samples AND display verbatim
I'd like to write a LaTeX document with code samples in a verbatim environment. I'd also like to export those code samples to named files so that they can be built and run. This allows me to easily ...
4
votes
1answer
249 views
morewrites: Failure to Compile, “Bad Number”
I have a project for which I have needed to resort to the morewrites package due to getting a No room for new \write. Up until a few months ago (which was when I last worked on it), this worked quite ...
1
vote
0answers
206 views
Where does TeXworks hide temporary files?
I am running TeXWorks under Windows 10.
If I've made some changes to a .tex file, but have not yet saved those changes, then there surely must be a temporary file someplace where TeXworks keeps the ...
2
votes
1answer
51 views
Proper way of passing parametric filenames to \openin using xstring
I would like to open a file programmatically within latex depending on its filename. For example, if the filenames begin with '0' I know the path is in some folder, if it starts with '1' in another ...
9
votes
3answers
1k views
Read a file and store its contents in a variable
I am trying to implement single sourcing such that same document can be conditionally typeset for number of purposes. This is what I would like to do.
\IfFileExists{../DecMaker.txt}{
var x = ...
3
votes
0answers
111 views
Compiling issues with minted: I can't write on file `thesis.pyg' [closed]
In my thesis I am using minted
for listings and lots of short inline references.
I'm running TeXLive on Windows with python 3.6.
I am also using the cache, kpsewhich and outputdir options:
\...
6
votes
2answers
732 views
includepdf and file with comma
How can I use filenames with commas with pdfpages?
The grffile package didn't help, the \detokenize command didn't help either
Also the \string command doesn't work. For ex.
\includepdf{\string"C:/...
2
votes
1answer
549 views
How to delete a file in latex code?
How to delete a file in latex code with normal complie tex. I create temporary files and when i finish using them I want to delete them. It not delete by bash or editor.
Thankyou!
1
vote
2answers
2k views
! I can't find file `tikzlibraryshape.code.tex'
I am using LaTeX and do not know how to fix this error
! I can't find file `tikzlibraryshape.code.tex'.
<argument> ...nput tikzlibrary\pgf@temp .code.tex
\catcode `\@ =\csname tikz...
l.5 \...
3
votes
0answers
800 views
List all files in a folder [duplicate]
Does anybody know how I can read all the files in a specific folder and use the filenames in my LaTeX document?
I want to automatically create a seating chart with the fotos in a folder.
2
votes
2answers
120 views
tlmgr installs files outside /usr/local during update --all in TL2016
texlive 2016 was installed locally in /usr/local/texlive/2016/ on a gentoo Linux system by the install-tl -gui installer.
An update with tlmgr returns:
/usr/local/texlive/2016/bin/x86_64-linux# ./...
1
vote
1answer
62 views
How do I copy the contents of a file with a given prefix to another file in restricted write18 enabled mode?
I know the prefix of a file - and I also know that there exists exactly 1 file with that prefix.
I am running pdftex in restricted write18 enabled mode.
I want to copy the contents of that file to a ...
5
votes
1answer
50 views
Are open \newwriter files closed when LaTeX exits prematurely with errors?
I am writing a package that needs to write at various times to an external file. For that I am using the \newwrite\mywriter and \immediate\openout\mywriter method. I know to use \closeout when done ...
7
votes
2answers
690 views
What are the naming rules for \newwrites in TeX? Can \newwrites be created dynamically?
I can create a \newwrite like this:
\newwrite\filehandle
\immediate\openout\filehandle=\jobname-semantically_useful_suffix.txt
\immediate\closeout\filehandle
Let's say I have languages stored in a ...
0
votes
1answer
497 views
How to obtain absolute path of Latex file, regadless if it standalone or combined
I need to find the absolute path of a latex file, as it sits on file system. Seems like a simple task, but it turns out to be harder than I thought.
Here is a MWE. I have this tree
/media/data/latex/...
2
votes
2answers
175 views
How can I remove trailing \par when reading a file and writing the output to the log?
I put together a macro to write the contents of an external file to the log output. Unfortunately, I always read out the trailing \par that LaTeX adds when reading files. How do I test for this and ...
1
vote
2answers
899 views
Find files in subdirectories to use with \input
Is there a way to have TeX find all files ending on .tex in subdirectories of a certain directory to be used as \input?
In my document I would like to include a large number of files from a directory-...
1
vote
1answer
446 views
Read a text file by delimiter not by line break
I would like to populate a table, which I created in my LaTeX document, using iterating over cells of a text file.
In order to read the text file I use this code.
\newread\data
\openin\data = data
\...
3
votes
3answers
2k views
What's Happening With My Path After Upgrade to El Capitan?
I've tried everything I could find (within good reason) regarding how I should proceed in making my TeX files compile again and nothing works. After hunting it down in the computer, I have found that ...
3
votes
1answer
198 views
How avoid “\T1\ss ” as output from \immediate\write and get ß?
\usepackage[ngerman]{babel}
\usepackage[T1]{fontenc}
\usepackage[ansinew]{inputenc}
...
\newwrite\outfile
\immediate\openout\outfile=\jobname.txt
% aßbc is a replacement for a long german text-block, ...