diff mbox series

[bug#60838,3/8] gnu: Add python-sqlite-utils.

Message ID 20230115215153.25235-1-felgru@posteo.net
State New
Headers show
Series Add datasette and python-sqlite-utils. | expand

Commit Message

Felix Gruber Jan. 15, 2023, 9:51 p.m. UTC
* gnu/packages/databases.scm (python-sqlite-utils): New variable.
---
 gnu/packages/databases.scm | 39 ++++++++++++++++++++++++++++++++++++++
 1 file changed, 39 insertions(+)

Comments

Maxim Cournoyer March 22, 2023, 1:08 a.m. UTC | #1
Hi,

Felix Gruber <felgru@posteo.net> writes:

> * gnu/packages/databases.scm (python-sqlite-utils): New variable.
> ---
>  gnu/packages/databases.scm | 39 ++++++++++++++++++++++++++++++++++++++
>  1 file changed, 39 insertions(+)
>
> diff --git a/gnu/packages/databases.scm b/gnu/packages/databases.scm
> index 375d34b051..9831a3b761 100644
> --- a/gnu/packages/databases.scm
> +++ b/gnu/packages/databases.scm
> @@ -3575,6 +3575,45 @@ (define-public python-sqlite-fts4
>  documents indexed using the SQLite's FTS4 full text search extension.")
>      (license license:asl2.0)))
>  
> +(define-public python-sqlite-utils
> +  (package
> +    (name "python-sqlite-utils")
> +    (version "3.30")
> +    (source (origin
> +              (method url-fetch)
> +              (uri (pypi-uri "sqlite-utils" version))
> +              (sha256
> +               (base32
> +                "0cvfbyvkh7gjh3ws3gj2yhjhr459nsz6c5vrkxjlad7isl95q01h"))))
> +    (build-system python-build-system)
> +    (arguments
> +     '(#:tests? #f)) ; No tests provided in pypi package.

Try fetching the source from git to enable the test suite.

> +    (propagated-inputs (list python-click python-click-default-group-wheel
> +                             python-dateutil python-sqlite-fts4
> +                             python-tabulate))
> +    (home-page "https://github.com/simonw/sqlite-utils")
> +    (synopsis
> +     "CLI tool and Python utility functions for manipulating SQLite databases")
> +    (description
> +     "This package provides a CLI tool and Python utility functions for
> +manipulating SQLite databases.
> +
> +It's main features are:
> +@itemize
> +@item Pipe JSON (or CSV or TSV) directly into a new SQLite database file,
> +      automatically creating a table with the appropriate schema.
> +@item Run in-memory SQL queries, including joins, directly against data
> +      in CSV, TSV or JSON files and view the results.
> +@item Configure SQLite full-text search against your database tables and
> +      run search queries against them, ordered by relevance.
> +@item Run transformations against your tables to make schema changes
> +      that SQLite ALTER TABLE does not directly support, such as
> +      changing the type of a column.
> +@item Extract columns into separate tables to better normalize your
> +      existing data.
> +@end itemize")
> +    (license license:asl2.0)))

I think the conventional way to indent @item is to use something like:

--8<---------------cut here---------------start------------->8---
@item
Text on
multiple lines.
@item
More text
on multiple lines.
@item
etc.
--8<---------------cut here---------------end--------------->8---
diff mbox series

Patch

diff --git a/gnu/packages/databases.scm b/gnu/packages/databases.scm
index 375d34b051..9831a3b761 100644
--- a/gnu/packages/databases.scm
+++ b/gnu/packages/databases.scm
@@ -3575,6 +3575,45 @@  (define-public python-sqlite-fts4
 documents indexed using the SQLite's FTS4 full text search extension.")
     (license license:asl2.0)))
 
+(define-public python-sqlite-utils
+  (package
+    (name "python-sqlite-utils")
+    (version "3.30")
+    (source (origin
+              (method url-fetch)
+              (uri (pypi-uri "sqlite-utils" version))
+              (sha256
+               (base32
+                "0cvfbyvkh7gjh3ws3gj2yhjhr459nsz6c5vrkxjlad7isl95q01h"))))
+    (build-system python-build-system)
+    (arguments
+     '(#:tests? #f)) ; No tests provided in pypi package.
+    (propagated-inputs (list python-click python-click-default-group-wheel
+                             python-dateutil python-sqlite-fts4
+                             python-tabulate))
+    (home-page "https://github.com/simonw/sqlite-utils")
+    (synopsis
+     "CLI tool and Python utility functions for manipulating SQLite databases")
+    (description
+     "This package provides a CLI tool and Python utility functions for
+manipulating SQLite databases.
+
+It's main features are:
+@itemize
+@item Pipe JSON (or CSV or TSV) directly into a new SQLite database file,
+      automatically creating a table with the appropriate schema.
+@item Run in-memory SQL queries, including joins, directly against data
+      in CSV, TSV or JSON files and view the results.
+@item Configure SQLite full-text search against your database tables and
+      run search queries against them, ordered by relevance.
+@item Run transformations against your tables to make schema changes
+      that SQLite ALTER TABLE does not directly support, such as
+      changing the type of a column.
+@item Extract columns into separate tables to better normalize your
+      existing data.
+@end itemize")
+    (license license:asl2.0)))
+
 (define-public python-pickleshare
   (package
     (name "python-pickleshare")