sloane 1.5 → 1.5.1
raw patch · 6 files changed
+153/−8 lines, 6 filesbuild-type:Customsetup-changed
Files
LICENSE view
@@ -1,4 +1,4 @@-Copyright (c) 2012, 2013, Anders Claesson+Copyright (c) 2012, 2013, 2014, Anders Claesson All rights reserved.
README.md view
@@ -1,5 +1,5 @@ ----title: SLOANE(1) Sloane User Manual | Version 1.5+title: SLOANE(1) Sloane User Manual | Version 1.5.1 date: March 9, 2014 --- @@ -119,4 +119,4 @@ # AUTHOR -Anders Claesson+Anders Claesson <http://akc.is>
Setup.hs view
@@ -1,2 +1,8 @@ import Distribution.Simple-main = defaultMain+import System.Process+import System.Exit++main = defaultMainWithHooks $ simpleUserHooks { postBuild = makeManPage }++makeManPage _ _ _ _ =+ runCommand "make sloane.1" >>= waitForProcess >>= exitWith
+ sloane.1 view
@@ -0,0 +1,139 @@+.TH "SLOANE" "1" "March 9, 2014" "Sloane User Manual" "Version 1.5.1"+.SH NAME+.PP+sloane \- a command line interface to Sloane\[aq]s On\-Line Encyclopedia+of Integer Sequences (OEIS) <http://oeis.org>+.SH SYNOPSIS+.PP+sloane [\f[I]options\f[]] \f[I]search\-terms\f[]+.SH DESCRIPTION+.PP+The sloane command searches Sloane\[aq]s On\-Line Encyclopedia of+Integer Sequences (OEIS).+The search terms are typically the leading term of a sequence, but can+be a sequence id (its A\-number) or even arbitrary words.+.SH OPTIONS+.TP+.B \-k \-\-keys=KEYS+Keys of fields to print (default: SN)+.RS+.RE+.TP+.B \-a \-\-all+Print all fields+.RS+.RE+.TP+.B \-u \-\-url+Only print urls of found entries+.RS+.RE+.TP+.B \-n \-\-limit=INT+Retrieve at most this many entries (default: 5)+.RS+.RE+.TP+.B \-? \-\-help+Display a short help message+.RS+.RE+.TP+.B \-V \-\-version+Print version information+.RS+.RE+.SH EXAMPLES+.PP+The most common search is for entries matching a sequence of consecutive+terms:+.IP+.nf+\f[C]+sloane\ 1,3,19,183,2371,38703+\f[]+.fi+.PP+At the time of writing this particular query would return+.IP+.nf+\f[C]+S\ A006531\ 1,1,3,19,183,2371,38703,763099,17648823,468603091,14050842303,+N\ A006531\ Semiorders\ on\ n\ elements.+\f[]+.fi+.PP+As this illustrates, the default is to return just the sequence (S) and+the name (N) fields.+To override the default one can use the keys option.+For instance, the following search shows the sequence, name, comments,+and formula fields of the sequence whose A\-number is A006531:+.IP+.nf+\f[C]+sloane\ \-kSNCF\ id:A006531+\f[]+.fi+.PP+The next example returns at most 3 results of a free text search:+.IP+.nf+\f[C]+sloane\ \-n3\ "(2+2)\-free\ posets"+\f[]+.fi+.PP+To view the full entries of these 3 results in a browser (e.g., firefox)+one can use the url option:+.IP+.nf+\f[C]+firefox\ `sloane\ \-\-url\ \-n3\ "(2+2)\-free\ posets"`+\f[]+.fi+.SH KEYS+.PP+These are the keys used by OEIS <http://oeis.org/eishelp2.html>.+.IP+.nf+\f[C]+I\ \ ID\ number++S\ \ 1st\ line\ of\ unsigned\ sequence+T\ \ 2nd\ line\ of\ unsigned\ sequence+U\ \ 3rd\ line\ of\ unsigned\ sequence++V\ \ 1st\ line\ of\ signed\ sequence+W\ \ 2nd\ line\ of\ signed\ sequence+X\ \ 3rd\ line\ of\ signed\ sequence++N\ \ Name+C\ \ Comments+D\ \ References+H\ \ Links+F\ \ Formula+e\ \ Examples++p\ \ Maple\ program+t\ \ Mathematica\ program+o\ \ Program\ in\ other\ language++Y\ \ Cross\-references+K\ \ Keywords+O\ \ Offset+A\ \ Author+E\ \ Extensions\ and\ errors+\f[]+.fi+.SH NOTES+.PP+Please use this program with moderation as not to overburden the+OEIS\-server; see OEIS\[aq] policy on searching the database:+<http://oeis.org/wiki/Welcome#Policy_on_Searching_the_Database>.+.SH SEE ALSO+.PP+The sloane source code may be downloaded from+<https://github.com/akc/sloane>.+.SH AUTHOR+.PP+Anders Claesson <http://akc.is>
sloane.cabal view
@@ -1,5 +1,5 @@ Name: sloane-Version: 1.5+Version: 1.5.1 Synopsis: A command line interface to Sloane's On-Line Encyclopedia of Integer Sequences Description: A command line interface to Sloane's On-Line Encyclopedia of Integer Sequences. For usage see <http://github.com/akc/sloane>.@@ -9,8 +9,8 @@ Author: Anders Claesson Maintainer: anders.claesson@gmail.com Category: Math-Build-type: Simple-Extra-Source-Files: README.md+Build-type: Custom+Extra-Source-Files: README.md sloane.1 Cabal-version: >=1.6
sloane.hs view
@@ -39,7 +39,7 @@ , limit = 5 &= name "n" &= help "Retrieve at most this many entries (default: 5)" , terms = def &= argPos 0 &= typ "SEARCH-TERMS" }- &= versionArg [summary "sloane 1.5"]+ &= versionArg [summary "sloane 1.5.1"] &= summary "Search Sloane's On-Line Encyclopedia of Integer Sequences" select :: Keys -> OEISEntries -> OEISEntries