summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorCoprDistGit <infra@openeuler.org>2023-05-18 03:44:28 +0000
committerCoprDistGit <infra@openeuler.org>2023-05-18 03:44:28 +0000
commit10bd50536aa40de7dbe235eac8cab7fae797048c (patch)
treefafa52da3a29c646f58035c45b019f12d717dd0e
parente4c74bdd5c8cd26d3b77dac19b58b04799f672db (diff)
automatic import of python-arg
-rw-r--r--.gitignore1
-rw-r--r--python-arg.spec435
-rw-r--r--sources1
3 files changed, 437 insertions, 0 deletions
diff --git a/.gitignore b/.gitignore
index e69de29..5fda702 100644
--- a/.gitignore
+++ b/.gitignore
@@ -0,0 +1 @@
+/arg-0.0.1.tar.gz
diff --git a/python-arg.spec b/python-arg.spec
new file mode 100644
index 0000000..67133ec
--- /dev/null
+++ b/python-arg.spec
@@ -0,0 +1,435 @@
+%global _empty_manifest_terminate_build 0
+Name: python-arg
+Version: 0.0.1
+Release: 1
+Summary: Parse command line arguments made easier...
+License: MIT License
+URL: https://projects.abranhe.com/arg
+Source0: https://mirrors.nju.edu.cn/pypi/web/packages/09/1c/17c9b364125562788c4072d579be26848047f9f25b817e4f095e28fc4e49/arg-0.0.1.tar.gz
+BuildArch: noarch
+
+
+%description
+<p align="center" id="top">
+ <a href="https://pypi.org/project/arg"><img src="https://cdn.abraham.gq/projects/arg/logo.svg"></a>
+ <br>
+ <br>
+ <br>
+ <a href="https://pypi.org/project/arg"><b>π˜Όπ™π™‚</b></a>
+ : Parse command line arguments made easier...
+</p>
+
+<p align="center">
+ <!-- Travis CI -->
+ <a href="https://travis-ci.org/abranhe/arg"><img src="https://img.shields.io/travis/abranhe/arg.svg?logo=travis" /></a>
+ <!-- LICENSE -->
+ <a href="https://github.com/abranhe/arg/blob/master/LICENSE"><img src="https://img.shields.io/github/license/abranhe/arg.svg" /></a>
+ <!-- @abranhe -->
+ <a href="https://github.com/abranhe"><img src="https://abranhe.com/badge.svg"></a>
+ <!-- Cash me -->
+ <a href="https://cash.me/$abranhe"><img src="https://cdn.abranhe.com/badges/cash-me.svg"></a>
+ <!-- Patreon -->
+ <a href="https://www.patreon.com/abranhe"><img src="https://cdn.abranhe.com/badges/patreon.svg" /></a>
+ <!-- Paypal -->
+ <a href="https://paypal.me/abranhe/10"><img src="https://cdn.abranhe.com/badges/paypal.svg" /></a>
+</p>
+
+
+# Install
+
+```
+pip install arg
+```
+
+# Usage
+
+```
+$ python test.py ford -m mustang --year 2017 red
+```
+
+> *test.py*
+
+```py
+import arg
+
+# argv without file name
+print(arg())
+# => ['ford', '-m', 'mustang', '--year', '2017', 'red']
+
+# argv
+print(arg.v())
+# => ['test.py', 'ford', '-m', 'mustang', '--year', '2017', 'red']
+
+# argc
+print(arg.c())
+# => 7
+
+# args as string
+print(arg.s())
+# => test.py ford -m mustang --year 2017 red
+
+# file name
+print(arg.fileName())
+# => test.py
+
+# argument at n
+print(arg.at(2))
+# => -m
+
+```
+
+# API
+
+### `arg()`
+
+> Return an array with the arguments without the file name
+
+**Return Type**: `list`
+
+### `.v()`
+
+> Return an array with all the arguments. (**arg.v** ~> argv *Argumet Vector*)
+
+**Return Type**: `list`
+
+### `.c()`
+
+> Return an array with all the arguments. (**arg.c** ~> argc *Argument Count*)
+
+**Return Type**: `int`
+
+### `.s()`
+
+> Return an string with all the arguments. (arg.s ~> Arguments to String)
+
+**Return Type**: `str`
+
+### `.fileName()`
+
+> Return an string with the name of the file
+
+**Return Type**: `str`
+
+### `.at(n)`
+
+> Return the value of the argument at value at **n**
+
+**Return Type**: `str`
+
+# Related
+
+- [**lupe**](https://github.com/abranhe/lupe): A better CLI Helper.
+
+# Team
+
+|[![Carlos Abraham Logo](https://avatars3.githubusercontent.com/u/21347264?s=50&v=4)](https://abranhe.com)|
+| :-: |
+| [Carlos Abraham](https://github.com/abranhe) |
+
+# License
+
+[MIT](https://github.com/abranhe/arg/blob/master/LICENSE) License Β© [Carlos Abraham](https://github.com/abranhe/)
+
+
+
+
+%package -n python3-arg
+Summary: Parse command line arguments made easier...
+Provides: python-arg
+BuildRequires: python3-devel
+BuildRequires: python3-setuptools
+BuildRequires: python3-pip
+%description -n python3-arg
+<p align="center" id="top">
+ <a href="https://pypi.org/project/arg"><img src="https://cdn.abraham.gq/projects/arg/logo.svg"></a>
+ <br>
+ <br>
+ <br>
+ <a href="https://pypi.org/project/arg"><b>π˜Όπ™π™‚</b></a>
+ : Parse command line arguments made easier...
+</p>
+
+<p align="center">
+ <!-- Travis CI -->
+ <a href="https://travis-ci.org/abranhe/arg"><img src="https://img.shields.io/travis/abranhe/arg.svg?logo=travis" /></a>
+ <!-- LICENSE -->
+ <a href="https://github.com/abranhe/arg/blob/master/LICENSE"><img src="https://img.shields.io/github/license/abranhe/arg.svg" /></a>
+ <!-- @abranhe -->
+ <a href="https://github.com/abranhe"><img src="https://abranhe.com/badge.svg"></a>
+ <!-- Cash me -->
+ <a href="https://cash.me/$abranhe"><img src="https://cdn.abranhe.com/badges/cash-me.svg"></a>
+ <!-- Patreon -->
+ <a href="https://www.patreon.com/abranhe"><img src="https://cdn.abranhe.com/badges/patreon.svg" /></a>
+ <!-- Paypal -->
+ <a href="https://paypal.me/abranhe/10"><img src="https://cdn.abranhe.com/badges/paypal.svg" /></a>
+</p>
+
+
+# Install
+
+```
+pip install arg
+```
+
+# Usage
+
+```
+$ python test.py ford -m mustang --year 2017 red
+```
+
+> *test.py*
+
+```py
+import arg
+
+# argv without file name
+print(arg())
+# => ['ford', '-m', 'mustang', '--year', '2017', 'red']
+
+# argv
+print(arg.v())
+# => ['test.py', 'ford', '-m', 'mustang', '--year', '2017', 'red']
+
+# argc
+print(arg.c())
+# => 7
+
+# args as string
+print(arg.s())
+# => test.py ford -m mustang --year 2017 red
+
+# file name
+print(arg.fileName())
+# => test.py
+
+# argument at n
+print(arg.at(2))
+# => -m
+
+```
+
+# API
+
+### `arg()`
+
+> Return an array with the arguments without the file name
+
+**Return Type**: `list`
+
+### `.v()`
+
+> Return an array with all the arguments. (**arg.v** ~> argv *Argumet Vector*)
+
+**Return Type**: `list`
+
+### `.c()`
+
+> Return an array with all the arguments. (**arg.c** ~> argc *Argument Count*)
+
+**Return Type**: `int`
+
+### `.s()`
+
+> Return an string with all the arguments. (arg.s ~> Arguments to String)
+
+**Return Type**: `str`
+
+### `.fileName()`
+
+> Return an string with the name of the file
+
+**Return Type**: `str`
+
+### `.at(n)`
+
+> Return the value of the argument at value at **n**
+
+**Return Type**: `str`
+
+# Related
+
+- [**lupe**](https://github.com/abranhe/lupe): A better CLI Helper.
+
+# Team
+
+|[![Carlos Abraham Logo](https://avatars3.githubusercontent.com/u/21347264?s=50&v=4)](https://abranhe.com)|
+| :-: |
+| [Carlos Abraham](https://github.com/abranhe) |
+
+# License
+
+[MIT](https://github.com/abranhe/arg/blob/master/LICENSE) License Β© [Carlos Abraham](https://github.com/abranhe/)
+
+
+
+
+%package help
+Summary: Development documents and examples for arg
+Provides: python3-arg-doc
+%description help
+<p align="center" id="top">
+ <a href="https://pypi.org/project/arg"><img src="https://cdn.abraham.gq/projects/arg/logo.svg"></a>
+ <br>
+ <br>
+ <br>
+ <a href="https://pypi.org/project/arg"><b>π˜Όπ™π™‚</b></a>
+ : Parse command line arguments made easier...
+</p>
+
+<p align="center">
+ <!-- Travis CI -->
+ <a href="https://travis-ci.org/abranhe/arg"><img src="https://img.shields.io/travis/abranhe/arg.svg?logo=travis" /></a>
+ <!-- LICENSE -->
+ <a href="https://github.com/abranhe/arg/blob/master/LICENSE"><img src="https://img.shields.io/github/license/abranhe/arg.svg" /></a>
+ <!-- @abranhe -->
+ <a href="https://github.com/abranhe"><img src="https://abranhe.com/badge.svg"></a>
+ <!-- Cash me -->
+ <a href="https://cash.me/$abranhe"><img src="https://cdn.abranhe.com/badges/cash-me.svg"></a>
+ <!-- Patreon -->
+ <a href="https://www.patreon.com/abranhe"><img src="https://cdn.abranhe.com/badges/patreon.svg" /></a>
+ <!-- Paypal -->
+ <a href="https://paypal.me/abranhe/10"><img src="https://cdn.abranhe.com/badges/paypal.svg" /></a>
+</p>
+
+
+# Install
+
+```
+pip install arg
+```
+
+# Usage
+
+```
+$ python test.py ford -m mustang --year 2017 red
+```
+
+> *test.py*
+
+```py
+import arg
+
+# argv without file name
+print(arg())
+# => ['ford', '-m', 'mustang', '--year', '2017', 'red']
+
+# argv
+print(arg.v())
+# => ['test.py', 'ford', '-m', 'mustang', '--year', '2017', 'red']
+
+# argc
+print(arg.c())
+# => 7
+
+# args as string
+print(arg.s())
+# => test.py ford -m mustang --year 2017 red
+
+# file name
+print(arg.fileName())
+# => test.py
+
+# argument at n
+print(arg.at(2))
+# => -m
+
+```
+
+# API
+
+### `arg()`
+
+> Return an array with the arguments without the file name
+
+**Return Type**: `list`
+
+### `.v()`
+
+> Return an array with all the arguments. (**arg.v** ~> argv *Argumet Vector*)
+
+**Return Type**: `list`
+
+### `.c()`
+
+> Return an array with all the arguments. (**arg.c** ~> argc *Argument Count*)
+
+**Return Type**: `int`
+
+### `.s()`
+
+> Return an string with all the arguments. (arg.s ~> Arguments to String)
+
+**Return Type**: `str`
+
+### `.fileName()`
+
+> Return an string with the name of the file
+
+**Return Type**: `str`
+
+### `.at(n)`
+
+> Return the value of the argument at value at **n**
+
+**Return Type**: `str`
+
+# Related
+
+- [**lupe**](https://github.com/abranhe/lupe): A better CLI Helper.
+
+# Team
+
+|[![Carlos Abraham Logo](https://avatars3.githubusercontent.com/u/21347264?s=50&v=4)](https://abranhe.com)|
+| :-: |
+| [Carlos Abraham](https://github.com/abranhe) |
+
+# License
+
+[MIT](https://github.com/abranhe/arg/blob/master/LICENSE) License Β© [Carlos Abraham](https://github.com/abranhe/)
+
+
+
+
+%prep
+%autosetup -n arg-0.0.1
+
+%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-arg -f filelist.lst
+%dir %{python3_sitelib}/*
+
+%files help -f doclist.lst
+%{_docdir}/*
+
+%changelog
+* Thu May 18 2023 Python_Bot <Python_Bot@openeuler.org> - 0.0.1-1
+- Package Spec generated
diff --git a/sources b/sources
new file mode 100644
index 0000000..1f132a1
--- /dev/null
+++ b/sources
@@ -0,0 +1 @@
+c884314e163e2795a117cb81e150c6f8 arg-0.0.1.tar.gz