diff options
author | CoprDistGit <infra@openeuler.org> | 2023-05-05 14:56:58 +0000 |
---|---|---|
committer | CoprDistGit <infra@openeuler.org> | 2023-05-05 14:56:58 +0000 |
commit | f7a5449a83a4fe1adb5ac0cfc2adbf74e4366377 (patch) | |
tree | a9e45328b8a93eb5c92559aaac62289ab7b62f42 | |
parent | bf0d3888d539e9c6cacfe878d25f314b22c574b8 (diff) |
automatic import of python-fortuneopeneuler20.03
-rw-r--r-- | .gitignore | 1 | ||||
-rw-r--r-- | python-fortune.spec | 283 | ||||
-rw-r--r-- | sources | 1 |
3 files changed, 285 insertions, 0 deletions
@@ -0,0 +1 @@ +/fortune-1.1.0.tar.gz diff --git a/python-fortune.spec b/python-fortune.spec new file mode 100644 index 0000000..099d207 --- /dev/null +++ b/python-fortune.spec @@ -0,0 +1,283 @@ +%global _empty_manifest_terminate_build 0 +Name: python-fortune +Version: 1.1.0 +Release: 1 +Summary: Python version of old BSD Unix fortune program +License: BSD-style license +URL: http://software.clapper.org/fortune/ +Source0: https://mirrors.nju.edu.cn/pypi/web/packages/e7/7a/d6361169d78c761216348e69b3c446be522b0b515a31f7333817f44ee56e/fortune-1.1.0.tar.gz +BuildArch: noarch + +Requires: python3-grizzled-python + +%description + +# Introduction + +`fortune` is a stripped-down implementation of the classic BSD Unix +`fortune` command. It combines the capabilities of the `strfile` command +(which produces the fortune index file) and the `fortune` command (which +displays a random fortune). It reads the traditional `fortune` program's +text file format. + +# Usage + +Usage: + + fortune [OPTIONS] /path/to/fortunes + + OPTIONS + + -h, --help Show usage and exit. + -u, --update Update the index file. + -q, --quiet When updating the index file, do so quietly. + -V, --version Show version and exit. + +If you omit the path, `fortune` looks at the `FORTUNE_FILE` environment +variable. If that environment variable isn't set, `fortune` aborts. + +# Fortune Cookie File Format + +A fortune cookie file is a text file full of quotes. The format is simple: +The file consists of paragraphs separated by lines containing a single '%' +character. For example:: + + A little caution outflanks a large cavalry. + -- Bismarck + % + A little retrospection shows that although many fine, useful software + systems have been designed by committees and built as part of multipart + projects, those software systems that have excited passionate fans are + those that are the products of one or a few designing minds, great + designers. Consider Unix, APL, Pascal, Modula, the Smalltalk interface, + even Fortran; and contrast them with Cobol, PL/I, Algol, MVS/370, and + MS-DOS. + -- Fred Brooks, Jr. + % + A man is not old until regrets take the place of dreams. + -- John Barrymore + + +# Generating a Random Fortune + +Just run: + + fortune /path/to/fortunes + +If your `FORTUNE_FILE` environment variable is set, you can run it as + + fortune + +# Differences + +This version of `fortune` does not provide some of the more advanced +capabilities of the original BSD program. For instance, it lacks: + +- the ability to mark offensive and inoffensive fortunes +- the ability to separate long and short quotes +- the ability to print all fortunes matching a regular expression + +It does, however, provide the most important function: The ability to display +a random quote from a set of quotes. + + + + +%package -n python3-fortune +Summary: Python version of old BSD Unix fortune program +Provides: python-fortune +BuildRequires: python3-devel +BuildRequires: python3-setuptools +BuildRequires: python3-pip +%description -n python3-fortune + +# Introduction + +`fortune` is a stripped-down implementation of the classic BSD Unix +`fortune` command. It combines the capabilities of the `strfile` command +(which produces the fortune index file) and the `fortune` command (which +displays a random fortune). It reads the traditional `fortune` program's +text file format. + +# Usage + +Usage: + + fortune [OPTIONS] /path/to/fortunes + + OPTIONS + + -h, --help Show usage and exit. + -u, --update Update the index file. + -q, --quiet When updating the index file, do so quietly. + -V, --version Show version and exit. + +If you omit the path, `fortune` looks at the `FORTUNE_FILE` environment +variable. If that environment variable isn't set, `fortune` aborts. + +# Fortune Cookie File Format + +A fortune cookie file is a text file full of quotes. The format is simple: +The file consists of paragraphs separated by lines containing a single '%' +character. For example:: + + A little caution outflanks a large cavalry. + -- Bismarck + % + A little retrospection shows that although many fine, useful software + systems have been designed by committees and built as part of multipart + projects, those software systems that have excited passionate fans are + those that are the products of one or a few designing minds, great + designers. Consider Unix, APL, Pascal, Modula, the Smalltalk interface, + even Fortran; and contrast them with Cobol, PL/I, Algol, MVS/370, and + MS-DOS. + -- Fred Brooks, Jr. + % + A man is not old until regrets take the place of dreams. + -- John Barrymore + + +# Generating a Random Fortune + +Just run: + + fortune /path/to/fortunes + +If your `FORTUNE_FILE` environment variable is set, you can run it as + + fortune + +# Differences + +This version of `fortune` does not provide some of the more advanced +capabilities of the original BSD program. For instance, it lacks: + +- the ability to mark offensive and inoffensive fortunes +- the ability to separate long and short quotes +- the ability to print all fortunes matching a regular expression + +It does, however, provide the most important function: The ability to display +a random quote from a set of quotes. + + + + +%package help +Summary: Development documents and examples for fortune +Provides: python3-fortune-doc +%description help + +# Introduction + +`fortune` is a stripped-down implementation of the classic BSD Unix +`fortune` command. It combines the capabilities of the `strfile` command +(which produces the fortune index file) and the `fortune` command (which +displays a random fortune). It reads the traditional `fortune` program's +text file format. + +# Usage + +Usage: + + fortune [OPTIONS] /path/to/fortunes + + OPTIONS + + -h, --help Show usage and exit. + -u, --update Update the index file. + -q, --quiet When updating the index file, do so quietly. + -V, --version Show version and exit. + +If you omit the path, `fortune` looks at the `FORTUNE_FILE` environment +variable. If that environment variable isn't set, `fortune` aborts. + +# Fortune Cookie File Format + +A fortune cookie file is a text file full of quotes. The format is simple: +The file consists of paragraphs separated by lines containing a single '%' +character. For example:: + + A little caution outflanks a large cavalry. + -- Bismarck + % + A little retrospection shows that although many fine, useful software + systems have been designed by committees and built as part of multipart + projects, those software systems that have excited passionate fans are + those that are the products of one or a few designing minds, great + designers. Consider Unix, APL, Pascal, Modula, the Smalltalk interface, + even Fortran; and contrast them with Cobol, PL/I, Algol, MVS/370, and + MS-DOS. + -- Fred Brooks, Jr. + % + A man is not old until regrets take the place of dreams. + -- John Barrymore + + +# Generating a Random Fortune + +Just run: + + fortune /path/to/fortunes + +If your `FORTUNE_FILE` environment variable is set, you can run it as + + fortune + +# Differences + +This version of `fortune` does not provide some of the more advanced +capabilities of the original BSD program. For instance, it lacks: + +- the ability to mark offensive and inoffensive fortunes +- the ability to separate long and short quotes +- the ability to print all fortunes matching a regular expression + +It does, however, provide the most important function: The ability to display +a random quote from a set of quotes. + + + + +%prep +%autosetup -n fortune-1.1.0 + +%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-fortune -f filelist.lst +%dir %{python3_sitelib}/* + +%files help -f doclist.lst +%{_docdir}/* + +%changelog +* Fri May 05 2023 Python_Bot <Python_Bot@openeuler.org> - 1.1.0-1 +- Package Spec generated @@ -0,0 +1 @@ +9c58b9216b74d47db49783f3b7efaea1 fortune-1.1.0.tar.gz |