summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorCoprDistGit <infra@openeuler.org>2023-05-31 05:15:52 +0000
committerCoprDistGit <infra@openeuler.org>2023-05-31 05:15:52 +0000
commit6e3d470b15eddf5aa62a27e0b535d42bdd3a392a (patch)
tree353b020c5ff04a3fda8622e80c22b14d658d4068
parent7d2c9f204cb49c58871d199228e29174b656f4df (diff)
automatic import of python-sparksql-magic
-rw-r--r--.gitignore1
-rw-r--r--python-sparksql-magic.spec224
-rw-r--r--sources1
3 files changed, 226 insertions, 0 deletions
diff --git a/.gitignore b/.gitignore
index e69de29..f390b2c 100644
--- a/.gitignore
+++ b/.gitignore
@@ -0,0 +1 @@
+/sparksql-magic-0.0.3.tar.gz
diff --git a/python-sparksql-magic.spec b/python-sparksql-magic.spec
new file mode 100644
index 0000000..335b5a3
--- /dev/null
+++ b/python-sparksql-magic.spec
@@ -0,0 +1,224 @@
+%global _empty_manifest_terminate_build 0
+Name: python-sparksql-magic
+Version: 0.0.3
+Release: 1
+Summary: Spark SQL magic command for Jupyter notebooks
+License: MIT License
+URL: https://github.com/cryeo/sparksql-magic
+Source0: https://mirrors.nju.edu.cn/pypi/web/packages/13/7a/50cb4b79e86bafb530c392efd1d439dcf0b662679f05e7fef2f649fa70c0/sparksql-magic-0.0.3.tar.gz
+BuildArch: noarch
+
+Requires: python3-pyspark
+Requires: python3-ipython
+
+%description
+# sparksql-magic
+
+Spark SQL magic command for Jupyter notebooks.
+
+![Example](screenshots/example.png)
+
+## Prerequisites
+- Python >= 3.6
+- PySpark >= 2.3.0
+- IPython >= 7.4.0
+
+## Install
+```
+pip install sparksql-magic
+```
+
+## Usage
+
+### Load
+```
+%load_ext sparksql_magic
+```
+
+### Config
+```
+%config SparkSql.limit=<INT>
+```
+
+|Option|Default|Description|
+|---|---|---|
+|`SparkSql.limit`|20|The maximum number of rows to display|
+
+### Parameter
+```
+%%sparksql [-c|--cache] [-e|--eager] [-v|--view VIEW] [-l|--limit LIMIT] [variable]
+<QUERY>
+```
+
+|Parameter|Description|
+|---|---|
+|`-c` `--cache`|Cache dataframe|
+|`-e` `--eager`|Cache dataframe with eager load|
+|`-v VIEW` `--view VIEW`|Create or replace temporary view|
+|`-l LIMIT` `--limit LIMIT`|The maximum number of rows to display (Default: `SparkSql.limit`)|
+|`variable`|Capture dataframe in a local variable|
+
+
+
+
+
+
+
+%package -n python3-sparksql-magic
+Summary: Spark SQL magic command for Jupyter notebooks
+Provides: python-sparksql-magic
+BuildRequires: python3-devel
+BuildRequires: python3-setuptools
+BuildRequires: python3-pip
+%description -n python3-sparksql-magic
+# sparksql-magic
+
+Spark SQL magic command for Jupyter notebooks.
+
+![Example](screenshots/example.png)
+
+## Prerequisites
+- Python >= 3.6
+- PySpark >= 2.3.0
+- IPython >= 7.4.0
+
+## Install
+```
+pip install sparksql-magic
+```
+
+## Usage
+
+### Load
+```
+%load_ext sparksql_magic
+```
+
+### Config
+```
+%config SparkSql.limit=<INT>
+```
+
+|Option|Default|Description|
+|---|---|---|
+|`SparkSql.limit`|20|The maximum number of rows to display|
+
+### Parameter
+```
+%%sparksql [-c|--cache] [-e|--eager] [-v|--view VIEW] [-l|--limit LIMIT] [variable]
+<QUERY>
+```
+
+|Parameter|Description|
+|---|---|
+|`-c` `--cache`|Cache dataframe|
+|`-e` `--eager`|Cache dataframe with eager load|
+|`-v VIEW` `--view VIEW`|Create or replace temporary view|
+|`-l LIMIT` `--limit LIMIT`|The maximum number of rows to display (Default: `SparkSql.limit`)|
+|`variable`|Capture dataframe in a local variable|
+
+
+
+
+
+
+
+%package help
+Summary: Development documents and examples for sparksql-magic
+Provides: python3-sparksql-magic-doc
+%description help
+# sparksql-magic
+
+Spark SQL magic command for Jupyter notebooks.
+
+![Example](screenshots/example.png)
+
+## Prerequisites
+- Python >= 3.6
+- PySpark >= 2.3.0
+- IPython >= 7.4.0
+
+## Install
+```
+pip install sparksql-magic
+```
+
+## Usage
+
+### Load
+```
+%load_ext sparksql_magic
+```
+
+### Config
+```
+%config SparkSql.limit=<INT>
+```
+
+|Option|Default|Description|
+|---|---|---|
+|`SparkSql.limit`|20|The maximum number of rows to display|
+
+### Parameter
+```
+%%sparksql [-c|--cache] [-e|--eager] [-v|--view VIEW] [-l|--limit LIMIT] [variable]
+<QUERY>
+```
+
+|Parameter|Description|
+|---|---|
+|`-c` `--cache`|Cache dataframe|
+|`-e` `--eager`|Cache dataframe with eager load|
+|`-v VIEW` `--view VIEW`|Create or replace temporary view|
+|`-l LIMIT` `--limit LIMIT`|The maximum number of rows to display (Default: `SparkSql.limit`)|
+|`variable`|Capture dataframe in a local variable|
+
+
+
+
+
+
+
+%prep
+%autosetup -n sparksql-magic-0.0.3
+
+%build
+%py3_build
+
+%install
+%py3_install
+install -d -m755 %{buildroot}/%{_pkgdocdir}
+if [ -d doc ]; then cp -arf doc %{buildroot}/%{_pkgdocdir}; fi
+if [ -d docs ]; then cp -arf docs %{buildroot}/%{_pkgdocdir}; fi
+if [ -d example ]; then cp -arf example %{buildroot}/%{_pkgdocdir}; fi
+if [ -d examples ]; then cp -arf examples %{buildroot}/%{_pkgdocdir}; fi
+pushd %{buildroot}
+if [ -d usr/lib ]; then
+ find usr/lib -type f -printf "/%h/%f\n" >> filelist.lst
+fi
+if [ -d usr/lib64 ]; then
+ find usr/lib64 -type f -printf "/%h/%f\n" >> filelist.lst
+fi
+if [ -d usr/bin ]; then
+ find usr/bin -type f -printf "/%h/%f\n" >> filelist.lst
+fi
+if [ -d usr/sbin ]; then
+ find usr/sbin -type f -printf "/%h/%f\n" >> filelist.lst
+fi
+touch doclist.lst
+if [ -d usr/share/man ]; then
+ find usr/share/man -type f -printf "/%h/%f.gz\n" >> doclist.lst
+fi
+popd
+mv %{buildroot}/filelist.lst .
+mv %{buildroot}/doclist.lst .
+
+%files -n python3-sparksql-magic -f filelist.lst
+%dir %{python3_sitelib}/*
+
+%files help -f doclist.lst
+%{_docdir}/*
+
+%changelog
+* Wed May 31 2023 Python_Bot <Python_Bot@openeuler.org> - 0.0.3-1
+- Package Spec generated
diff --git a/sources b/sources
new file mode 100644
index 0000000..bf9be7b
--- /dev/null
+++ b/sources
@@ -0,0 +1 @@
+8e5c446863b7b3a3bb625802f3d93d00 sparksql-magic-0.0.3.tar.gz