简体   繁体   English

如何升级pygments.rb使用和最新的pygments库(python)

[英]How to upgrade pygments.rb use and the latest library of pygments(python)

I am using pygments.rb in one of my projects I want to upgrade the python library which is used by pygments.rb to the latest version. 我在其中一个项目中使用pygments.rb,我想将pygments.rb使用的python库升级到最新版本。

I am using a ubuntu 12.04 machine. 我正在使用Ubuntu 12.04机器。

The Pygments Python package provides the command line utility pygmentize and so does the the ubuntu package python-pygments . Pygments Python软件包提供了命令行实用程序pygmentize ,而ubuntu软件包python-pygments Pygments is at 1.6 and ubuntu is at 1.4. Pygments为1.6,Ubuntu为1.4。

If you are currently using the ubuntu package you may want to remove it to avoid any conflicts 如果您当前正在使用ubuntu软件包,则可能需要将其删除以避免任何冲突

sudo apt-get remove python-pygments

The easiest way to manage Python packages is with pip 管理Python软件包的最简单方法是使用pip

sudo apt-get install python-pip python-dev build-essential

Then install/upgrade the Pygments package 然后安装/升级Pygments软件包

sudo pip install Pygments --upgrade

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM