Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

How to use cpan2aur? #29

Open
xeruf opened this issue Mar 9, 2022 · 3 comments
Open

How to use cpan2aur? #29

xeruf opened this issue Mar 9, 2022 · 3 comments

Comments

@xeruf
Copy link

xeruf commented Mar 9, 2022

❯ cpan2aur -d Text::Layout
==> Creating a new package directory for Text::Layout...
  -> Looking up module for Text::Layout on CPAN...
Running [/usr/bin/perl -MCPANPLUS::Internals::Utils::Autoflush /home/janek/.cpanplus/5.34.0/build/LX8hqQhqCJ/Text-Layout-0.028/Makefile.PL]...
Checking if your kit is complete...
Looks good
Generating a Unix-style Makefile
Writing Makefile for Text::Layout
Writing MYMETA.yml and MYMETA.json
  -> Creating new PKGBUILD.tt template file...
==> Created perl-text-layout source package directory.
❯ cpan2aur --check perl-text-layout
==> Checking if perl-text-layout is up to date...
==> ERROR: perl-text-layout does not contain a PKGBUILD or source package
           file.
❯ cpan2aur --upload perl-text-layout
-u[pload] feature not implemented due to AUR 4.0 changes

I do not want "Automatic packaging" when installing from CPAN (which I don't do), I merely maintain a few perl packages on the AUR which I want to keep updated automatically. I am a little confused how to proceed here.

@juster
Copy link
Owner

juster commented Mar 10, 2022 via email

@xeruf
Copy link
Author

xeruf commented Mar 10, 2022

It seems the check flag is utterly useless now, though:

❯ cpan2aur -d Text::Layout
==> Creating a new package directory for Text::Layout...
  -> Looking up module for Text::Layout on CPAN...
Running [/usr/bin/perl -MCPANPLUS::Internals::Utils::Autoflush /home/janek/.cpanplus/5.34.0/build/F0maXqvAik/Text-Layout-0.028/Makefile.PL]...
Checking if your kit is complete...
Looks good
Generating a Unix-style Makefile
Writing Makefile for Text::Layout
Writing MYMETA.yml and MYMETA.json
  -> Creating new PKGBUILD.tt template file...
==> Created perl-text-layout source package directory.
❯ cd perl-text-layout
PKGBUILD.tt
❯ cpan2aur Text::Layout
==> Creating new source package for Text::Layout...
  -> Looking up module for Text::Layout on CPAN...
Running [/usr/bin/perl -MCPANPLUS::Internals::Utils::Autoflush /home/janek/.cpanplus/5.34.0/build/8R3IKMqIsX/Text-Layout-0.028/Makefile.PL]...
Checking if your kit is complete...
Looks good
Generating a Unix-style Makefile
Writing Makefile for Text::Layout
Writing MYMETA.yml and MYMETA.json
==> Making package: perl-text-layout 0.028-1 (Thu 10 Mar 2022 01:31:40)
==> Retrieving sources...
  -> Found Text-Layout-0.028.tar.gz
==> Validating source files with md5sums...
    Text-Layout-0.028.tar.gz ... Passed
==> Validating source files with sha512sums...
    Text-Layout-0.028.tar.gz ... Passed
==> Entering fakeroot environment...
==> Creating source package...
  -> Adding PKGBUILD...
  -> Generating .SRCINFO file...
  -> Compressing source package...
==> Leaving fakeroot environment.
==> Source package created: perl-text-layout (Thu 10 Mar 2022 01:31:41)
❯ cpan2aur --check perl-text-layout-0.028-1.src.tar.gz
==> Checking if perl-text-layout-0.028-1.src.tar.gz is up to date...
==> ERROR: perl-text-layout-0.028-1.src.tar.gz's PKGBUILD does not seem to
           be made by cpan2aur. We are unable to extract the CPAN
           distribution name from it.
❯ cpan2aur --check .
==> Checking if . is up to date...
==> ERROR: . does not contain a PKGBUILD or source package file.
❯ ls -l
total 8,0K
-rw-r--r-- 1 janek janek 1,6K Mar 10 01:31 PKGBUILD.tt
-rw-r--r-- 1 janek janek 1,1K Mar 10 01:31 perl-text-layout-0.028-1.src.tar.gz

The only thing I can do is build the source package, compare the version number and adjust my PKGBUILD accordingly, because I found no flag to create the actual PKGBUILD from the .tt template.

@juster
Copy link
Owner

juster commented Mar 10, 2022 via email

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants