zoukankan      html  css  js  c++  java
  • wkhtmltox 在Linux上安装

    参考:https://gist.github.com/apphancer/8654e82aa582d1cf02c955536df06449

    # Install dependencies (if needed)
    $ yum install -y xorg-x11-fonts-75dpi
    $ yum install -y xorg-x11-fonts-Type1
    $ yum install xz
    
    # Get latest version of wkhtmltopdf (replace version number if needed)
    $ wget https://github.com/wkhtmltopdf/wkhtmltopdf/releases/download/0.12.4/wkhtmltox-0.12.4_linux-generic-amd64.tar.xz
    
    # Untar and move wkhtmltox
    $ unxz wkhtmltox-0.12.4_linux-generic-amd64.tar.xz
    $ tar -xvf wkhtmltox-0.12.4_linux-generic-amd64.tar
    $ mv wkhtmltox /usr/bin/wkhtmltox
    
    # Add wkhtmltopdf to .bash_profile (optional)
    nano .bash_profile
    # Add the following line at the end of the .bash_profile file
    # export PATH=/usr/bin/wkhtmltox/bin:$PATH
    
    # And don't forget..
    $ rm wkhtmltox-0.12.4_linux-generic-amd64.tar
    
    # Finally enjoy!
    $ wkhtmltopdf http://www.google.com google.pdf
    如果是此文是转载文章,本人会附上转载链接,此篇文章的版权归原创作者所属,如果侵权请与我联系,我会删除此文。

    若没有标明转载链接,此篇文章属于本人的原创文章,其版权所属:
    作者:feiquan
    出处:http://www.cnblogs.com/feiquan/
    版权声明:本文版权归作者和博客园共有,欢迎转载,但未经作者同意必须保留此段声明,且在文章页面明显位置给出原文连接,否则保留追究法律责任的权利。
    大家写文都不容易,请尊重劳动成果~ 这里谢谢大家啦(*/ω\*)
  • 相关阅读:
    143. Reorder List
    圆圈中最后剩下的数
    求1+2+3+...+n
    不用加减乘除做加法
    构建乘积数组
    199. Binary Tree Right Side View
    把字符串转换成整数
    java stream
    物流运费的维护架构
    9、定义类与方法
  • 原文地址:https://www.cnblogs.com/feiquan/p/14690836.html
Copyright © 2011-2022 走看看