本文主要是介绍dreamhost 好用吗_在Dreamhost上安装pngcrush,希望对大家解决编程问题提供一定的参考价值,需要的开发者们随着小编来一起学习吧!

dreamhost 好用吗
pngcrush is an excellent optimizer for png images, simple and fast, highly recommended. Basically any time before you post a PNG on the web, you should run it through PNGCrush. It's a command line utility, there's a quick way to integrate pngcrush in windows explorer. (note to self: I actually wrote a wordpress plugin to do crush uploaded images, gotta find and post it)
pngcrush是用于png图像的出色优化器,简单,快速,强烈建议使用。 基本上,在将PNG发布到网络上之前的任何时间,都应该通过PNGCrush运行它。 这是一个命令行实用程序,有一种将pngcrush集成到Windows资源管理器中的快速方法。 (请注意:我实际上写了一个wordpress插件来粉碎上传的图像,必须查找并发布)
I'm working (together with Nicole) on an online image optimizer, using the free command line tools I talked about at PHP Quebec, Montreal, O'Reilly's Velocity and the Yahoo! Performance pages. The tool will be free, of course, and hosted on Dreamhost. OK, finally getting to the point, am I?
我正在(与Nicole一起)使用我在PHP Quebec,Montreal , O'Reilly的Velocity和Yahoo!上讨论的免费命令行工具,开发一个在线图像优化器。 绩效页面。 该工具当然是免费的,并托管在Dreamhost上。 好,终于到了要点,是吗?
Here's what I did to install pngcrush on Dreamhost, hope it helps anyone out there who's sweating with the same task.
这是我在Dreamhost上安装pngcrush所做的工作,希望它可以帮助正在忙于同一任务的任何人。
ssh to your dreamhost box, you need to give yourself ssh privileges from the dreamhost control panel
ssh到您的dreamhost框中,您需要从dreamhost控制面板中给自己ssh特权
mkdir tmp
- make a temp directorymkdir tmp
一个临时目录cd tmp
- enter the temp directorycd tmp
进入临时目录wget http://voxel.dl.sourceforge.net/sourceforge/pmt/pngcrush-1.6.10.tar.gz
- download latest version of the pngcrush source code, this is the sourceforge mirror, closest to me, yours might be different and the pngcrush version might be newer at the time you install it, you can check herewget http://voxel.dl.sourceforge.net/sourceforge/pmt/pngcrush-1.6.10.tar.gz
下载pngcrush源代码的最新版本,这是sourceforge镜像,离我最近,您的可能有所不同并且pngcrush版本在安装时可能是较新的,您可以在此处查看tar zxvf pngcrush-1.6.10.tar.gz
- uncompress the code. This creates a new directory, enter it like so:cd pngcrush-1.6.10
tar zxvf pngcrush-1.6.10.tar.gz
解压缩代码。 这将创建一个新目录,如下所示输入:cd pngcrush-1.6.10
now all you need to do is run
make
, but didn't work for me, so I edited theMakefile
file first, like sovi Makefile
. In the vi editor, press i to enter INSERT mode and once you're done with the changes, press ESC, then type:wq
(meaining write, quit). Here I removed the version information from the gcc compiler, so the two lines I edited became现在您所需要做的就是运行
make
,但是对我不起作用,所以我首先编辑了Makefile
文件,就像vi Makefile
。 在vi编辑器中,按i进入INSERT模式,完成更改后,按ESC,然后键入:wq
(表示写入,退出)。 在这里,我从gcc编译器中删除了版本信息,所以我编辑的两行变成了CC = gcc LD = gcc
make
- this compiles the pngcrush code and creates a binary calledpngcrush
make
-这编译pngcrush代码,并创建了一个名为二进制pngcrush
cp pngcrush /usr/bin/
- copy the new binary to where binaries usually livecp pngcrush /usr/bin/
-将新的二进制文件复制到二进制文件通常所在的位置All set, try if everything is ok
pngcrush
, this should display the pngcrush's help information全部设置,如果一切正常,请尝试
pngcrush
,这应该显示pngcrush的帮助信息
Crush'em PNG!(Crush'em PNGs!)
Like so: pngcrush image.png -rem alla -reduce -brute result.png
像这样: pngcrush image.png -rem alla -reduce -brute result.png
需要托管吗? (Need hosting?)
[advertisement]Dreamhost is a really good host, use this code MAXDISCO
for $50 off [/advertisement] 😉
[广告] Dreamhost是一个非常好的主机,请使用此代码MAXDISCO
减$ 50 [/广告]😉
Tell your friends about this post on Facebook and Twitter
在Facebook和Twitter上告诉您的朋友有关此帖子的信息
翻译自: https://www.phpied.com/installing-pngcrush-at-dreamhost/
dreamhost 好用吗
这篇关于dreamhost 好用吗_在Dreamhost上安装pngcrush的文章就介绍到这儿,希望我们推荐的文章对编程师们有所帮助!