Giter Club home page Giter Club logo

laravel-php-latex's Introduction

A laravel package to generate pdfs using latex

Laravel LaTex

LaTex is an extraordinary typesetting system, using which you can highly professional and clean documentation. The document can be a simple article or huge technical/scientific book.

The reason to choose LaTex is that, it has extensive features inbuilt have headers, footers, book index, page numbers, watermarks and so on... Once you explore the possibilities of a LaTex document, you would be amazed.

This package makes entire scaffolding using which you can generate, save or download PDF documents.

Pre-requisites :

You need to have texlive-full program installed on your server. This program has tex packages and language libraries which help you generate documents.

Note : You can also opt to install textlive which is the lighter and primitive version of the package where as texlive-full contains all package bundles.

The different is : - When you install textlive and want to use any additional tex package, you need to install it manually. - texlive-full comes with these extra packages. As a result it may take up some additional space on server (to store the package library files).

Installation :

composer require techsemicolon/laravel-php-latex

Dry Run :

Before diving into the usage directly, it is important to make sure required programms are installed properly on yoru server. The package comes with dryrun method which you can use in put inside any controller or route. It will automatically generate dryrun.pdf if everything is set up prperly on the server. If not, it will throw LatexException with detailed server errors.

<?php

namespace App\Http\Controllers;

use App\Http\Controllers\Controller;
use Techsemicolon\Latex;

class TestController extends Controller
{
    /**
     * Download PDF generated from latex
     * 
     * @return Illuminate\Http\Response
     */
    public function download(){

        return (new Latex)->dryRun();
    }
}

Dryrun will download a beautifully clean test pdf like below :

dryrun.pdf sample

Usage :

  • Create a view file with tex data :

Create a view files inside resources/views/latex/tex.blade.php

\documentclass[a4paper,9pt,landscape]{article}

\usepackage{adjustbox}
\usepackage[english]{babel}
\usepackage[scaled=.92]{helvet}
\usepackage{fancyhdr}
\usepackage[svgnames,table]{xcolor}
\usepackage[a4paper,inner=1.5cm,outer=1.5cm,top=1cm,bottom=1cm,bindingoffset=0cm]{geometry}
\usepackage{blindtext}
\geometry{textwidth=\paperwidth, textheight=\paperheight, noheadfoot, nomarginpar}

\renewcommand{\familydefault}{\sfdefault}

\pagestyle{fancy}
\fancyhead{}
\renewcommand{\headrulewidth}{0pt}
\fancyfoot{}
\fancyfoot[LE,RO]{\thepage}

\fancyfoot[C]{\fontsize{8pt}{8pt}\selectfont Above document is auto-generated.}
\renewcommand{\footrulewidth}{0.2pt}


\begin{document}

\section*{\centering{Test Document}}

\begin{center}
    \item[Name :] {{ $name }}
    \item[Date of Birth :] {{ $dob }}
\end{center}

\blindtext

\begin{table}[ht]
\centering
\begin{adjustbox}{center}
\renewcommand{\arraystretch}{2}
\begin{tabular}{|l|l|}

\hline

\rowcolor[HTML]{E3E3E3}
\textbf{Sr. No} 
& \textbf{Addresses}\\
\hline

@foreach($addresses as $key => $address)

    \renewcommand{\arraystretch}{1.5}
    {{ $key }} & {{ $address }} \\
    \hline

@endforeach

\end{tabular}
\end{adjustbox}
\caption{Address Summmary}
\end{table}

\blindtext

\vfill
\centering

\end{document}

You can see how we have easily used blade directives for {{ $name }} or @foreach to show addresses in table to dynamically generate the content.

  • Generate the file :

There are few actions you can choose take to generate.

  1. You can download the file as a response :
<?php

namespace App\Http\Controllers;

use App\Http\Controllers\Controller;
use Techsemicolon\Latex;

class TestController extends Controller
{
    /**
     * Download PDF generated from LaTex
     * 
     * @return Illuminate\Http\Response
     */
    public function download(){

        return (new Latex('latex.tex'))->with([
            'name' => 'John Doe',
            'dob' => '01/01/1994',
            'addresses' => [
                '20 Pumpkin Hill Drive Satellite Beach, FL 32937',
                '7408 South San Juan Ave. Beaver Falls, PA 15010'
            ]
        ])->download('test.pdf');
    }
}
  1. You can save pdf to the location you want for later use :
(new Latex('latex.tex'))->with([
    'name' => 'John Doe',
    'dob' => '01/01/1994',
    'addresses' => [
        '20 Pumpkin Hill Drive Satellite Beach, FL 32937',
        '7408 South San Juan Ave. Beaver Falls, PA 15010'
    ]
])->savePdf(storage_path('exports/pdf/test.pdf'));
  1. You can just render the tex without generating a pdf :
$tex = new Latex('latex.tex'))->with([
    'name' => 'John Doe',
    'dob' => '01/01/1994',
    'addresses' => [
        '20 Pumpkin Hill Drive Satellite Beach, FL 32937',
        '7408 South San Juan Ave. Beaver Falls, PA 15010'
    ]
])->render();

Setting up custom bin path :

If your server is not having pdflatex in the environment $PATH, you might need to give full path to execute the command. To find the path you can do :

which pdflatex

Then you can pass that path using binPath function as below :

return (new Latex('latex.tex'))->with([
    'name' => 'John Doe',
    'dob' => '01/01/1994',
    'addresses' => [
        '20 Pumpkin Hill Drive Satellite Beach, FL 32937',
        '7408 South San Juan Ave. Beaver Falls, PA 15010'
    ]
])->binPath('/usr/bin/pdflatex')->download('test.pdf');

Using Raw Tex :

If you do not want to use views as tex files, but already have tex content. Or are using other libraries to generate tex content like Markdown-to-LaTex, you can use RawTex class instead of passing a view path :

$tex = new RawTex('your_raw_tex_content_string.....');

return (new Latex($tex))->with([
    'name' => 'John Doe',
    'dob' => '01/01/1994',
    'addresses' => [
        '20 Pumpkin Hill Drive Satellite Beach, FL 32937',
        '7408 South San Juan Ave. Beaver Falls, PA 15010'
    ]
])->download('test.pdf');

Bulk download in a zip archive :

Want to expot multiple pdfs in zip? Package has that functionality ready for you. This gives a great flexibility for you. However, make sure you are not passing too many pdfs together, as it is going to consume good amount server memory to export those together.

$latexCollection = (new LatexCollection());
$users = User::limit(10)->get();
foreach ($users as $user) {
            
    $pdfName = $user->first_name.'-'.$user->last_name.'-'.$user->id.'.pdf';

    // Create latex instance
    $latex = (new Latex('latex.patientsummary'))->with([
        'user' => $user
    ])->setName($pdfName);

    // Add it to latex collection
    $latexCollection->add($latex);
}

// Download the zip
return $latexCollection->downloadZip('bulk.zip');

// OR you can also save it 
$latexCollection->saveZip(storage_path('exports/zips/users.zip'));

Listening to events :

Whenever a pdf is succesfully generated, it fires an event LatexPdfWasGenerated. Similarly whenever if pdf generation fails, it fires event LatexPdfFailed.

These events are important if you need to perform some actions depending on the generation stutus like updating the database. But mostly these pdf have some metadata like which user the pdf belongs to or which order the pdf belongs to. You can pass this metadata while instantiating latex as a second argument.

This metadata is then passed back to you from the fired event, which makes it much more meaningful to listen. The metadata can be anything, if can bt string, numeric, an array, object, collection etc. You can pass the metadata depending on your desired logic.

// $user will be our metadata in this example
$user = Auth::user();

(new Latex('latex.tex', $user))->with([
    'name' => 'John Doe',
    'dob' => '01/01/1994',
    'addresses' => [
        '20 Pumpkin Hill Drive Satellite Beach, FL 32937',
        '7408 South San Juan Ave. Beaver Falls, PA 15010'
    ]
])->savePdf(storage_path('exports/pdf/test.pdf'));

Then you can define a listener like :

<?php

namespace App\Listeners;

use Techsemicolon\LatexPdfWasGenerated;

class LatexPdfWasGeneratedConfirmation
{
    /**
     * Create the event listener.
     *
     * @return void
     */
    public function __construct()
    {
        //
    }

    /**
     * Handle the event.
     *
     * @param  LatexPdfWasGenerated  $event
     * @return void
     */
    public function handle(LatexPdfWasGenerated $event)
    {
        // Path  of pdf in case in was saved 
        // OR 
        // Downloaded name of pdf file in case it was downloaded in response directly
        $pdf = $event->pdf;

        // download OR savepdf
        $action = $event->action;

        // metadata $user in this example
        $user = $event->metadata;

        // Perform desired actions
    }
}

Garbage Collection :

When you export the pdf, few extra files are generated by pdflatext along with it e.g. .aux, .log etc. The package takes care of the garbage collection process internally. It makes sure no residual files are remaining when pdf is generated or even when any error occures.

This makes sure the server does not waste it's space keeping the residual files.

Error Handling :

We are using pdflatex program from texlive to generate pdfs. If error a syntax occures in your tex file, it logs into a log file. Or it is turned off, it shows output in console.

The package takes care of the same internally and throws much ViewNotFoundException. The exception will have entire information about the error easily available for you to debug.

Please feel free to contribute if you want to add new functionalities to this package.

License :

This psckage is open-sourced software licensed under the MIT license

laravel-php-latex's People

Contributors

akmet avatar draxvint avatar techsemicolon avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar

laravel-php-latex's Issues

Incorrect escaping of output in example docs, {{ }} escapes HTML/makes quote safe, not suitable for LaTeX

This project just uses the standard blade template escaping, which is designed for HTML

This means that if you have, say an & in your data, and you insert it into a template, this will bork.

The docs need to state this, that you need to escape any dynamic data before inserting, and to user {!! !!} to insert the literal, after you have used your escaping routine.

a helper function I have used before is

public function le($string)
{
    return strtr($string, [
        "#"=>'\#',
        "$"=>'\$',
        "%"=>'\%',
        "&"=>'\&',
        "~"=>'\~{}',
        "_"=>'\_',
        "^"=>'\^{}',
        "\\"=>'\textbackslash',
        "{"=>'\{',
        "}"=>'\}',
    ]);
}

And in the blade you would then have

{!! le($customer->name) !!}

Problem with Laravel 7

Hi,
I'm trying to install this on Laravel 7.0.8

However this is the result

Problem 1
- Installation request for techsemicolon/laravel-php-latex ^1.0 -> satisfiable by techsemicolon/laravel-php-latex[1.0.0].
- Conclusion: remove laravel/framework v7.0.8
- Conclusion: don't install laravel/framework v7.0.8
- techsemicolon/laravel-php-latex 1.0.0 requires illuminate/filesystem 5.0.x|5.1.x|5.2.x|5.3.x|5.4.x|5.5.X|5.6.X|5.7.X -> satisfiable by illuminate/filesystem[5.0.x-dev, 5.1.x-dev, 5.2.x-dev, 5.3.x-dev, 5.4.x-dev, 5.5.x-dev, 5.6.x-dev, 5.7.17, 5.7.18, 5.7.19, 5.7.x-dev, v5.0.0, v5.0.22, v5.0.25, v5.0.26, v5.0.28, v5.0.33, v5.0.4, v5.1.1, v5.1.13, v5.1.16, v5.1.2, v5.1.20, v5.1.22, v5.1.25, v5.1.28, v5.1.30, v5.1.31, v5.1.41, v5.1.6, v5.1.8, v5.2.0, v5.2.19, v5.2.21, v5.2.24, v5.2.25, v5.2.26, v5.2.27, v5.2.28, v5.2.31, v5.2.32, v5.2.37, v5.2.43, v5.2.45, v5.2.6, v5.2.7, v5.3.0, v5.3.16, v5.3.23, v5.3.4, v5.4.0, v5.4.13, v5.4.17, v5.4.19, v5.4.27, v5.4.36, v5.4.9, v5.5.0, v5.5.16, v5.5.17, v5.5.2, v5.5.28, v5.5.33, v5.5.34, v5.5.35, v5.5.36, v5.5.37, v5.5.39, v5.5.40, v5.5.41, v5.5.43, v5.5.44, v5.6.0, v5.6.1, v5.6.10, v5.6.11, v5.6.12, v5.6.13, v5.6.14, v5.6.15, v5.6.16, v5.6.17, v5.6.19, v5.6.2, v5.6.20, v5.6.21, v5.6.22, v5.6.23, v5.6.24, v5.6.25, v5.6.26, v5.6.27, v5.6.28, v5.6.29, v5.6.3, v5.6.30, v5.6.31, v5.6.32, v5.6.33, v5.6.34, v5.6.35, v5.6.36, v5.6.37, v5.6.38, v5.6.39, v5.6.4, v5.6.5, v5.6.6, v5.6.7, v5.6.8, v5.6.9, v5.7.0, v5.7.1, v5.7.10, v5.7.11, v5.7.15, v5.7.2, v5.7.20, v5.7.21, v5.7.22, v5.7.23, v5.7.26, v5.7.27, v5.7.28, v5.7.3, v5.7.4, v5.7.5, v5.7.6, v5.7.7, v5.7.8, v5.7.9].
- don't install illuminate/filesystem 5.6.x-dev|don't install laravel/framework v7.0.8
- don't install illuminate/filesystem v5.6.0|don't install laravel/framework v7.0.8
- don't install illuminate/filesystem v5.6.1|don't install laravel/framework v7.0.8
- don't install illuminate/filesystem v5.6.10|don't install laravel/framework v7.0.8
- don't install illuminate/filesystem v5.6.11|don't install laravel/framework v7.0.8
- don't install illuminate/filesystem v5.6.12|don't install laravel/framework v7.0.8
- don't install illuminate/filesystem v5.6.13|don't install laravel/framework v7.0.8
- don't install illuminate/filesystem v5.6.14|don't install laravel/framework v7.0.8
- don't install illuminate/filesystem v5.6.15|don't install laravel/framework v7.0.8
- don't install illuminate/filesystem v5.6.16|don't install laravel/framework v7.0.8
- don't install illuminate/filesystem v5.6.17|don't install laravel/framework v7.0.8
- don't install illuminate/filesystem v5.6.19|don't install laravel/framework v7.0.8
- don't install illuminate/filesystem v5.6.2|don't install laravel/framework v7.0.8
- don't install illuminate/filesystem v5.6.20|don't install laravel/framework v7.0.8
- don't install illuminate/filesystem v5.6.21|don't install laravel/framework v7.0.8
- don't install illuminate/filesystem v5.6.22|don't install laravel/framework v7.0.8
- don't install illuminate/filesystem v5.6.23|don't install laravel/framework v7.0.8
- don't install illuminate/filesystem v5.6.24|don't install laravel/framework v7.0.8
- don't install illuminate/filesystem v5.6.25|don't install laravel/framework v7.0.8
- don't install illuminate/filesystem v5.6.26|don't install laravel/framework v7.0.8
- don't install illuminate/filesystem v5.6.27|don't install laravel/framework v7.0.8
- don't install illuminate/filesystem v5.6.28|don't install laravel/framework v7.0.8
- don't install illuminate/filesystem v5.6.29|don't install laravel/framework v7.0.8
- don't install illuminate/filesystem v5.6.3|don't install laravel/framework v7.0.8
- don't install illuminate/filesystem v5.6.30|don't install laravel/framework v7.0.8
- don't install illuminate/filesystem v5.6.31|don't install laravel/framework v7.0.8
- don't install illuminate/filesystem v5.6.32|don't install laravel/framework v7.0.8
- don't install illuminate/filesystem v5.6.33|don't install laravel/framework v7.0.8
- don't install illuminate/filesystem v5.6.34|don't install laravel/framework v7.0.8
- don't install illuminate/filesystem v5.6.35|don't install laravel/framework v7.0.8
- don't install illuminate/filesystem v5.6.36|don't install laravel/framework v7.0.8
- don't install illuminate/filesystem v5.6.37|don't install laravel/framework v7.0.8
- don't install illuminate/filesystem v5.6.38|don't install laravel/framework v7.0.8
- don't install illuminate/filesystem v5.6.39|don't install laravel/framework v7.0.8
- don't install illuminate/filesystem v5.6.4|don't install laravel/framework v7.0.8
- don't install illuminate/filesystem v5.6.5|don't install laravel/framework v7.0.8
- don't install illuminate/filesystem v5.6.6|don't install laravel/framework v7.0.8
- don't install illuminate/filesystem v5.6.7|don't install laravel/framework v7.0.8
- don't install illuminate/filesystem v5.6.8|don't install laravel/framework v7.0.8
- don't install illuminate/filesystem v5.6.9|don't install laravel/framework v7.0.8
- don't install illuminate/filesystem 5.7.17|don't install laravel/framework v7.0.8
- don't install illuminate/filesystem 5.7.18|don't install laravel/framework v7.0.8
- don't install illuminate/filesystem 5.7.19|don't install laravel/framework v7.0.8
- don't install illuminate/filesystem 5.7.x-dev|don't install laravel/framework v7.0.8
- don't install illuminate/filesystem v5.7.0|don't install laravel/framework v7.0.8
- don't install illuminate/filesystem v5.7.1|don't install laravel/framework v7.0.8
- don't install illuminate/filesystem v5.7.10|don't install laravel/framework v7.0.8
- don't install illuminate/filesystem v5.7.11|don't install laravel/framework v7.0.8
- don't install illuminate/filesystem v5.7.15|don't install laravel/framework v7.0.8
- don't install illuminate/filesystem v5.7.2|don't install laravel/framework v7.0.8
- don't install illuminate/filesystem v5.7.20|don't install laravel/framework v7.0.8
- don't install illuminate/filesystem v5.7.21|don't install laravel/framework v7.0.8
- don't install illuminate/filesystem v5.7.22|don't install laravel/framework v7.0.8
- don't install illuminate/filesystem v5.7.23|don't install laravel/framework v7.0.8
- don't install illuminate/filesystem v5.7.26|don't install laravel/framework v7.0.8
- don't install illuminate/filesystem v5.7.27|don't install laravel/framework v7.0.8
- don't install illuminate/filesystem v5.7.28|don't install laravel/framework v7.0.8
- don't install illuminate/filesystem v5.7.3|don't install laravel/framework v7.0.8
- don't install illuminate/filesystem v5.7.4|don't install laravel/framework v7.0.8
- don't install illuminate/filesystem v5.7.5|don't install laravel/framework v7.0.8
- don't install illuminate/filesystem v5.7.6|don't install laravel/framework v7.0.8
- don't install illuminate/filesystem v5.7.7|don't install laravel/framework v7.0.8
- don't install illuminate/filesystem v5.7.8|don't install laravel/framework v7.0.8
- don't install illuminate/filesystem v5.7.9|don't install laravel/framework v7.0.8
- don't install illuminate/filesystem 5.4.x-dev|don't install laravel/framework v7.0.8
- don't install illuminate/filesystem v5.4.0|don't install laravel/framework v7.0.8
- don't install illuminate/filesystem v5.4.13|don't install laravel/framework v7.0.8
- don't install illuminate/filesystem v5.4.17|don't install laravel/framework v7.0.8
- don't install illuminate/filesystem v5.4.19|don't install laravel/framework v7.0.8
- don't install illuminate/filesystem v5.4.27|don't install laravel/framework v7.0.8
- don't install illuminate/filesystem v5.4.36|don't install laravel/framework v7.0.8
- don't install illuminate/filesystem v5.4.9|don't install laravel/framework v7.0.8
- don't install illuminate/filesystem 5.5.x-dev|don't install laravel/framework v7.0.8
- don't install illuminate/filesystem v5.5.0|don't install laravel/framework v7.0.8
- don't install illuminate/filesystem v5.5.16|don't install laravel/framework v7.0.8
- don't install illuminate/filesystem v5.5.17|don't install laravel/framework v7.0.8
- don't install illuminate/filesystem v5.5.2|don't install laravel/framework v7.0.8
- don't install illuminate/filesystem v5.5.28|don't install laravel/framework v7.0.8
- don't install illuminate/filesystem v5.5.33|don't install laravel/framework v7.0.8
- don't install illuminate/filesystem v5.5.34|don't install laravel/framework v7.0.8
- don't install illuminate/filesystem v5.5.35|don't install laravel/framework v7.0.8
- don't install illuminate/filesystem v5.5.36|don't install laravel/framework v7.0.8
- don't install illuminate/filesystem v5.5.37|don't install laravel/framework v7.0.8
- don't install illuminate/filesystem v5.5.39|don't install laravel/framework v7.0.8
- don't install illuminate/filesystem v5.5.40|don't install laravel/framework v7.0.8
- don't install illuminate/filesystem v5.5.41|don't install laravel/framework v7.0.8
- don't install illuminate/filesystem v5.5.43|don't install laravel/framework v7.0.8
- don't install illuminate/filesystem v5.5.44|don't install laravel/framework v7.0.8
- don't install illuminate/filesystem 5.0.x-dev|don't install laravel/framework v7.0.8
- don't install illuminate/filesystem 5.1.x-dev|don't install laravel/framework v7.0.8
- don't install illuminate/filesystem 5.2.x-dev|don't install laravel/framework v7.0.8
- don't install illuminate/filesystem 5.3.x-dev|don't install laravel/framework v7.0.8
- don't install illuminate/filesystem v5.0.0|don't install laravel/framework v7.0.8
- don't install illuminate/filesystem v5.0.22|don't install laravel/framework v7.0.8
- don't install illuminate/filesystem v5.0.25|don't install laravel/framework v7.0.8
- don't install illuminate/filesystem v5.0.26|don't install laravel/framework v7.0.8
- don't install illuminate/filesystem v5.0.28|don't install laravel/framework v7.0.8
- don't install illuminate/filesystem v5.0.33|don't install laravel/framework v7.0.8
- don't install illuminate/filesystem v5.0.4|don't install laravel/framework v7.0.8
- don't install illuminate/filesystem v5.1.1|don't install laravel/framework v7.0.8
- don't install illuminate/filesystem v5.1.13|don't install laravel/framework v7.0.8
- don't install illuminate/filesystem v5.1.16|don't install laravel/framework v7.0.8
- don't install illuminate/filesystem v5.1.2|don't install laravel/framework v7.0.8
- don't install illuminate/filesystem v5.1.20|don't install laravel/framework v7.0.8
- don't install illuminate/filesystem v5.1.22|don't install laravel/framework v7.0.8
- don't install illuminate/filesystem v5.1.25|don't install laravel/framework v7.0.8
- don't install illuminate/filesystem v5.1.28|don't install laravel/framework v7.0.8
- don't install illuminate/filesystem v5.1.30|don't install laravel/framework v7.0.8
- don't install illuminate/filesystem v5.1.31|don't install laravel/framework v7.0.8
- don't install illuminate/filesystem v5.1.41|don't install laravel/framework v7.0.8
- don't install illuminate/filesystem v5.1.6|don't install laravel/framework v7.0.8
- don't install illuminate/filesystem v5.1.8|don't install laravel/framework v7.0.8
- don't install illuminate/filesystem v5.2.0|don't install laravel/framework v7.0.8
- don't install illuminate/filesystem v5.2.19|don't install laravel/framework v7.0.8
- don't install illuminate/filesystem v5.2.21|don't install laravel/framework v7.0.8
- don't install illuminate/filesystem v5.2.24|don't install laravel/framework v7.0.8
- don't install illuminate/filesystem v5.2.25|don't install laravel/framework v7.0.8
- don't install illuminate/filesystem v5.2.26|don't install laravel/framework v7.0.8
- don't install illuminate/filesystem v5.2.27|don't install laravel/framework v7.0.8
- don't install illuminate/filesystem v5.2.28|don't install laravel/framework v7.0.8
- don't install illuminate/filesystem v5.2.31|don't install laravel/framework v7.0.8
- don't install illuminate/filesystem v5.2.32|don't install laravel/framework v7.0.8
- don't install illuminate/filesystem v5.2.37|don't install laravel/framework v7.0.8
- don't install illuminate/filesystem v5.2.43|don't install laravel/framework v7.0.8
- don't install illuminate/filesystem v5.2.45|don't install laravel/framework v7.0.8
- don't install illuminate/filesystem v5.2.6|don't install laravel/framework v7.0.8
- don't install illuminate/filesystem v5.2.7|don't install laravel/framework v7.0.8
- don't install illuminate/filesystem v5.3.0|don't install laravel/framework v7.0.8
- don't install illuminate/filesystem v5.3.16|don't install laravel/framework v7.0.8
- don't install illuminate/filesystem v5.3.23|don't install laravel/framework v7.0.8
- don't install illuminate/filesystem v5.3.4|don't install laravel/framework v7.0.8
- Installation request for laravel/framework (locked at v7.0.8, required as 7.0.*) -> satisfiable by laravel/framework[v7.0.8].

Which laravel versions are supported?

Logfile not found - dryRun

I get the following error when i want to call the dryRun function. I installed texlive-full on my homestead and laravell-php-latex via composer.

` private function parseError($tmpfname, $process){

    $logFile = $tmpfname.'.log';

    if(!\File::exists($logFile)){

        **throw new LatextException($process->getOutput());**
    }

    $error = \File::get($tmpfname.'.log');
    throw new LatextException($error);
}`

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.