<?xml version="1.0" encoding="utf-8"?>
<rss version="2.0" xmlns:dc="http://purl.org/dc/elements/1.1/">
<channel>
<title>Snipplr - noah</title>
<link>http://snipplr.com/users/noah/tags/commandline</link>
<description>Recent snippets posted on Snipplr.com</description>
<language>en-us</language>
<pubDate>Thu, 16 Feb 2012 00:08:18 GMT</pubDate>
<item>
<title>(Bash) test that pwgen does not produce duplicate words</title>
<link>http://snipplr.com/view/45623/test-that-pwgen-does-not-produce-duplicate-words/</link>
<description><![CDATA[ <p></p> ]]></description>
<pubDate>Sat, 11 Dec 2010 15:20:34 GMT</pubDate>
<guid>http://snipplr.com/view/45623/test-that-pwgen-does-not-produce-duplicate-words/</guid>
</item>
<item>
<title>(Ruby) Howto set up a Rake task that passes a parameter to a shell command or script</title>
<link>http://snipplr.com/view/27991/howto-set-up-a-rake-task-that-passes-a-parameter-to-a-shell-command-or-script/</link>
<description><![CDATA[ <p></p> ]]></description>
<pubDate>Mon, 08 Feb 2010 22:48:53 GMT</pubDate>
<guid>http://snipplr.com/view/27991/howto-set-up-a-rake-task-that-passes-a-parameter-to-a-shell-command-or-script/</guid>
</item>
<item>
<title>(Bash) SVN log, only for this branch</title>
<link>http://snipplr.com/view/26955/svn-log-only-for-this-branch/</link>
<description><![CDATA[ <p>Use SVN log to print only the history of the current branch.  The `--stop-on-copy` option will print the entire history of the current branch, and then stop.</p> ]]></description>
<pubDate>Sun, 24 Jan 2010 12:52:05 GMT</pubDate>
<guid>http://snipplr.com/view/26955/svn-log-only-for-this-branch/</guid>
</item>
<item>
<title>(Perl) Renumber the files in a directory, or prefix file names with numbers</title>
<link>http://snipplr.com/view/26527/renumber-the-files-in-a-directory-or-prefix-file-names-with-numbers/</link>
<description><![CDATA[ <p>Useful for renumbering frames to feed into `ffmpeg`</p> ]]></description>
<pubDate>Fri, 15 Jan 2010 16:16:57 GMT</pubDate>
<guid>http://snipplr.com/view/26527/renumber-the-files-in-a-directory-or-prefix-file-names-with-numbers/</guid>
</item>
<item>
<title>(Bash) Grep for files that do not match a pattern</title>
<link>http://snipplr.com/view/16699/grep-for-files-that-do-not-match-a-pattern/</link>
<description><![CDATA[ <p>The -L option lists files that do *not* contain a line matching the pattern given.</p> ]]></description>
<pubDate>Mon, 06 Jul 2009 16:37:12 GMT</pubDate>
<guid>http://snipplr.com/view/16699/grep-for-files-that-do-not-match-a-pattern/</guid>
</item>
<item>
<title>(Bash) preview Markdown in the shell, without launching Firefox</title>
<link>http://snipplr.com/view/15687/preview-markdown-in-the-shell-without-launching-firefox/</link>
<description><![CDATA[ <p>You may need to first `sudo gem install maruku` and install Lynx using your favorite package manager [or just download Lynx by itself](http://www.google.com/search?q=download+lynx)</p> ]]></description>
<pubDate>Mon, 08 Jun 2009 00:27:33 GMT</pubDate>
<guid>http://snipplr.com/view/15687/preview-markdown-in-the-shell-without-launching-firefox/</guid>
</item>
<item>
<title>(Perl) grep with Perl</title>
<link>http://snipplr.com/view/11878/grep-with-perl/</link>
<description><![CDATA[ <p>A combination of the instructions in the book _Minimal Perl_ and [this Perl one-liners page](http://sial.org/howto/perl/one-liner/)

The general form of the one-liner is:

    > perl -wnl -e '/REGEX/ and print $ARGV." $.: $_"; close ARGV if eof' 

The example below shows how to print the hex colors that are defined in a [Sass](http://haml.hamptoncatlin.com/docs/rdoc/classes/Sass.html) source tree.</p> ]]></description>
<pubDate>Thu, 05 Feb 2009 13:29:59 GMT</pubDate>
<guid>http://snipplr.com/view/11878/grep-with-perl/</guid>
</item>
<item>
<title>(Bash) Delicious ego boost from the command line</title>
<link>http://snipplr.com/view/9964/delicious-ego-boost-from-the-command-line/</link>
<description><![CDATA[ <p>This one-liner counts how many of the links to onemorebug.com there are on http://delicous.com/tag/noahsussman.

Basically it prints a number, and that number is the percentage of the top 100 links for that tag in delicious that point to your URL. 

Requires Grep, Lynx and Wc.</p> ]]></description>
<pubDate>Fri, 21 Nov 2008 22:29:39 GMT</pubDate>
<guid>http://snipplr.com/view/9964/delicious-ego-boost-from-the-command-line/</guid>
</item>
<item>
<title>(Perl) Rake routes filtering with Perl</title>
<link>http://snipplr.com/view/9570/rake-routes-filtering-with-perl/</link>
<description><![CDATA[ <p></p> ]]></description>
<pubDate>Sat, 08 Nov 2008 11:29:05 GMT</pubDate>
<guid>http://snipplr.com/view/9570/rake-routes-filtering-with-perl/</guid>
</item>
<item>
<title>(Ruby) Rdoc</title>
<link>http://snipplr.com/view/9534/rdoc/</link>
<description><![CDATA[ <p></p> ]]></description>
<pubDate>Thu, 06 Nov 2008 11:54:26 GMT</pubDate>
<guid>http://snipplr.com/view/9534/rdoc/</guid>
</item>
<item>
<title>(Bash) Get the length of a string on the command line with Ruby</title>
<link>http://snipplr.com/view/5584/get-the-length-of-a-string-on-the-command-line-with-ruby/</link>
<description><![CDATA[ <p>The following command prints 21.</p> ]]></description>
<pubDate>Thu, 27 Mar 2008 23:08:41 GMT</pubDate>
<guid>http://snipplr.com/view/5584/get-the-length-of-a-string-on-the-command-line-with-ruby/</guid>
</item>
<item>
<title>(Perl) lwp-request</title>
<link>http://snipplr.com/view/5196/lwprequest/</link>
<description><![CDATA[ <p></p> ]]></description>
<pubDate>Mon, 25 Feb 2008 12:28:41 GMT</pubDate>
<guid>http://snipplr.com/view/5196/lwprequest/</guid>
</item>
<item>
<title>(Perl) Generate XHTML on the command line with XML::API::XHTML</title>
<link>http://snipplr.com/view/4971/generate-xhtml-on-the-command-line-with-xmlapixhtml/</link>
<description><![CDATA[ <p>Build a simple XHTML document, format it with Tidy and print the result to "temp.html."

You may first need to `cpan   XML::API::XHTML`, and install Tidy using your favorite package manager, or just [download Tidy by itself](http://tidy.sourceforge.net/#binaries)

### If you can't install XML::API::XHTML

On my system, CPAN complained that "make test had returned bad status" during installation of XML::API::XHTML.  To solve this I started the CPAN shell (just type `cpan`) and then forced the install, like this:
    
    cpan> force XML::API::XHTML</p> ]]></description>
<pubDate>Sun, 10 Feb 2008 02:21:23 GMT</pubDate>
<guid>http://snipplr.com/view/4971/generate-xhtml-on-the-command-line-with-xmlapixhtml/</guid>
</item>
<item>
<title>(Bash) Validate XHTML with Tidy and/or OpenJade, just like the FF extension</title>
<link>http://snipplr.com/view/4970/validate-xhtml-with-tidy-andor-openjade-just-like-the-ff-extension/</link>
<description><![CDATA[ <p>Neither command will give any feedback unless invalid markup is found.</p> ]]></description>
<pubDate>Sun, 10 Feb 2008 02:14:45 GMT</pubDate>
<guid>http://snipplr.com/view/4970/validate-xhtml-with-tidy-andor-openjade-just-like-the-ff-extension/</guid>
</item>
<item>
<title>(Other) ClearCase commands</title>
<link>http://snipplr.com/view/4328/clearcase-commands/</link>
<description><![CDATA[ <p>Here is a list of commands that work with Rational Software's ClearTool for Rational ClearCase version control system.</p> ]]></description>
<pubDate>Fri, 14 Dec 2007 11:24:19 GMT</pubDate>
<guid>http://snipplr.com/view/4328/clearcase-commands/</guid>
</item>
<item>
<title>(Bash) Scrape Google from the command line</title>
<link>http://snipplr.com/view/4299/scrape-google-from-the-command-line/</link>
<description><![CDATA[ <p>This code is POC only -- actually using it would violate Google's TOS, which forbids scraping.  It is published here for educational value only.

Hypothetically, the following command should return a list of the top 500 or so hits in Google for onemorebug.com.

The results will be prepended with digits, followed by a dot and some whitespace (Lynx adds these).

_You must have Lynx and Wget installed on your system for this to work._

Keep in mind that *nix shells don't like it when you double-quote strings, see the comments.</p> ]]></description>
<pubDate>Sun, 09 Dec 2007 21:16:58 GMT</pubDate>
<guid>http://snipplr.com/view/4299/scrape-google-from-the-command-line/</guid>
</item>
<item>
<title>(Bash) check linked pages for Tidy validation errors, on the command line</title>
<link>http://snipplr.com/view/4130/check-linked-pages-for-tidy-validation-errors-on-the-command-line/</link>
<description><![CDATA[ <p>Given a list of HTML links (for example, a Google results page that has been saved locally) check each link that points to a page on a given domain, and report if Tidy complains that its doctype declaration is missing.

Besides DOCTYPE, other strings to search for include "discarding", "lacks value" and "Error:"

Remember to replace MY_DOMAIN with the actual domain you want to validate against.</p> ]]></description>
<pubDate>Tue, 13 Nov 2007 23:47:28 GMT</pubDate>
<guid>http://snipplr.com/view/4130/check-linked-pages-for-tidy-validation-errors-on-the-command-line/</guid>
</item>
<item>
<title>(Bash) Validate a list of Web pages with Tidy, on the command line</title>
<link>http://snipplr.com/view/4129/validate-a-list-of-web-pages-with-tidy-on-the-command-line/</link>
<description><![CDATA[ <p></p> ]]></description>
<pubDate>Tue, 13 Nov 2007 22:54:37 GMT</pubDate>
<guid>http://snipplr.com/view/4129/validate-a-list-of-web-pages-with-tidy-on-the-command-line/</guid>
</item>
<item>
<title>(Bash) Tail requests for HTML files</title>
<link>http://snipplr.com/view/4069/tail-requests-for-html-files/</link>
<description><![CDATA[ <p>This command will tail an Apache access log, but only print lines where an HTML file was requested.</p> ]]></description>
<pubDate>Mon, 05 Nov 2007 12:40:54 GMT</pubDate>
<guid>http://snipplr.com/view/4069/tail-requests-for-html-files/</guid>
</item>
<item>
<title>(Bash) Download linked JPEGs from a Web page, on the command line</title>
<link>http://snipplr.com/view/4063/download-linked-jpegs-from-a-web-page-on-the-command-line/</link>
<description><![CDATA[ <p>The following command will download all the files with a JPG extension that are linked from http://flickr.com.

_Requires the LWP and HTML::Tree Perl modules.  You must also have Wget installed on your system for this to work._</p> ]]></description>
<pubDate>Fri, 02 Nov 2007 22:57:45 GMT</pubDate>
<guid>http://snipplr.com/view/4063/download-linked-jpegs-from-a-web-page-on-the-command-line/</guid>
</item>
</channel>
</rss>
