#! @PYTHON@ # -*- mode: python -*- import glob import os import sys import warnings def __renpy_files(directory): for pattern in ['*.rpa', '*.rpyc', '*.rpy']: for file in glob.iglob(pattern, root_dir=directory): yield file def path_to_gamedir(basedir, name): candidates = [name, 'game', 'data', 'launcher/game'] if __renpy_files(basedir): return basedir for candidate in candidates: gamedir = os.path.join(basedir, candidate) if __renpy_files(gamedir): return gamedir return basedir def path_to_common(renpy_base): return renpy_base + "/common" def path_to_saves(gamedir, save_directory=None): import renpy if save_directory is None: save_directory = renpy.config.save_directory save_directory = renpy.exports.fsencode(save_directory) if not save_directory: return gamedir + "/saves" return os.path.join(os.path.expanduser("~/.renpy"), save_directory) def main(): try: import renpy.bootstrap import renpy.arguments except ImportError: print("""Could not import renpy.bootstrap. Please ensure you decompressed Ren'py correctly, preserving the directory structure.""", file=sys.stderr) raise args = renpy.arguments.bootstrap() if not args.basedir: print("""This Ren'py requires a basedir to launch. The basedir is the directory, in which .rpy source files or compiled .rpyc files live -- usually the 'game' subdirectory of a game packaged by Ren'py. If you want the Ren'py launcher, use \"renpy-launcher\" instead.""", file=sys.stderr) sys.exit() renpy.bootstrap.bootstrap("@RENPY_BASE@") if __name__ == "__main__": main() t type='hidden' name='showmsg' value='1'/>
path: root/tests/cpan.scm
AgeCommit message (Collapse)Author
2023-06-09tests: Ensure 'cpan' updater test does not access the network.Ludovic Courtès
Previously it would try to access the real metacpan.org. This would succeed when network is available because "Test-Script" is an existing package. * tests/cpan.scm ("package-latest-release"): Wrap 'upstream-source-inputs' call in 'parameterize'. Set 'current-http-proxy'. Change the order of responses in 'with-http-server'.
2023-05-31tests: Use quasiquoted 'match' patterns for package sexps.Ludovic Courtès
Turns out it's easier to read. * tests/cpan.scm ("cpan->guix-package"): Use a quasiquoted pattern. * tests/elpa.scm (eval-test-with-elpa): Likewise. * tests/gem.scm ("gem->guix-package") ("gem->guix-package with a specific version") ("gem-recursive-import") ("gem-recursive-import with a specific version"): Likewise. * tests/hexpm.scm ("hexpm-recursive-import"): Likewise. * tests/opam.scm ("opam->guix-package"): Likewise. * tests/pypi.scm ("pypi->guix-package, no wheel") ("pypi->guix-package, wheels") ("pypi->guix-package, no usable requirement file.") ("pypi->guix-package, package name contains \"-\" followed by digits"): Likewise. * tests/texlive.scm ("texlive->guix-package"): Likewise.
2023-05-31import: cpan: Updater provides input list.Ludovic Courtès
* guix/import/cpan.scm (latest-release): Add 'inputs' field. * tests/cpan.scm ("package-latest-release"): New test.
2023-05-31import: cpan: Represent dependencies as <upstream-input> records.Ludovic Courtès
* guix/import/cpan.scm (cpan-name->downstream-name) (cran-dependency->upstream-input, cran-module-inputs): New procedures. (cpan-module->sexp)[guix-name, convert-inputs]: Remove. [maybe-inputs]: Adjust to deal with <upstream-input>. Use 'cpan-name->downstream-name' instead of 'guix-name'. Add call to 'cpan-module-inputs' and adjust calls to 'maybe-inputs'. No longer emit input labels. * tests/cpan.scm ("cpan->guix-package"): Adjust test accordingly.