import: Beautify descriptions when appropriate.
* guix/import/elpa.scm (elpa-package->sexp) * guix/import/gnu.scm (gnu-package->sexp) * guix/import/hackage.scm (hackage-module->sexp) * guix/import/minetest.scm (make-minetest-sexp) * guix/import/opam.scm (opam->guix-package) * guix/import/pypi.scm (make-pypi-sexp): Beautify descriptions. Signed-off-by: Ludovic Courtès <ludo@gnu.org>
This commit is contained in:
		
							parent
							
								
									5cd1019488
								
							
						
					
					
						commit
						155fc235b5
					
				
					 6 changed files with 9 additions and 7 deletions
				
			
		| 
						 | 
				
			
			@ -388,7 +388,7 @@ type '<elpa-package>'."
 | 
			
		|||
            '())
 | 
			
		||||
      (home-page ,(elpa-package-home-page pkg))
 | 
			
		||||
      (synopsis ,(elpa-package-synopsis pkg))
 | 
			
		||||
      (description ,(elpa-package-description pkg))
 | 
			
		||||
      (description ,(beautify-description (elpa-package-description pkg)))
 | 
			
		||||
      (license ,license))
 | 
			
		||||
   dependencies-names))
 | 
			
		||||
 | 
			
		||||
| 
						 | 
				
			
			
 | 
			
		|||
| 
						 | 
				
			
			@ -100,7 +100,8 @@ download policy (see 'download-tarball' for details.)"
 | 
			
		|||
                        (file-sha256 tarball))))))
 | 
			
		||||
          (build-system gnu-build-system)
 | 
			
		||||
          (synopsis ,(gnu-package-doc-summary package))
 | 
			
		||||
          (description ,(gnu-package-doc-description package))
 | 
			
		||||
          (description ,(beautify-description
 | 
			
		||||
                         (gnu-package-doc-description package)))
 | 
			
		||||
          (home-page ,(match (gnu-package-doc-urls package)
 | 
			
		||||
                        ((head . tail) (qualified-url head))))
 | 
			
		||||
          (license find-by-yourself!)))
 | 
			
		||||
| 
						 | 
				
			
			
 | 
			
		|||
| 
						 | 
				
			
			@ -33,7 +33,7 @@
 | 
			
		|||
  #:use-module ((guix utils) #:select (package-name->name+version
 | 
			
		||||
                                       canonical-newline-port))
 | 
			
		||||
  #:use-module (guix http-client)
 | 
			
		||||
  #:use-module ((guix import utils) #:select (factorize-uri recursive-import))
 | 
			
		||||
  #:use-module (guix import utils)
 | 
			
		||||
  #:use-module (guix import cabal)
 | 
			
		||||
  #:use-module (guix store)
 | 
			
		||||
  #:use-module (gcrypt hash)
 | 
			
		||||
| 
						 | 
				
			
			@ -315,7 +315,7 @@ the hash of the Cabal file."
 | 
			
		|||
        ,@(maybe-arguments)
 | 
			
		||||
        (home-page ,(cabal-package-home-page cabal))
 | 
			
		||||
        (synopsis ,(cabal-package-synopsis cabal))
 | 
			
		||||
        (description ,(cabal-package-description cabal))
 | 
			
		||||
        (description ,(beautify-description (cabal-package-description cabal)))
 | 
			
		||||
        (license ,(string->license (cabal-package-license cabal))))
 | 
			
		||||
     (append hackage-dependencies hackage-native-dependencies))))
 | 
			
		||||
 | 
			
		||||
| 
						 | 
				
			
			
 | 
			
		|||
| 
						 | 
				
			
			@ -322,7 +322,7 @@ MEDIA-LICENSE and LICENSE."
 | 
			
		|||
     ,@(maybe-propagated-inputs (map contentdb->package-name inputs))
 | 
			
		||||
     (home-page ,home-page)
 | 
			
		||||
     (synopsis ,(delete-cr synopsis))
 | 
			
		||||
     (description ,(delete-cr description))
 | 
			
		||||
     (description ,(beautify-description (delete-cr description)))
 | 
			
		||||
     (license ,(if (eq? media-license license)
 | 
			
		||||
                   license
 | 
			
		||||
                   `(list ,media-license ,license)))
 | 
			
		||||
| 
						 | 
				
			
			
 | 
			
		|||
| 
						 | 
				
			
			@ -371,7 +371,8 @@ or #f on failure."
 | 
			
		|||
                               ,(list 'quasiquote `((upstream-name . ,name))))))
 | 
			
		||||
                       (home-page ,(metadata-ref opam-content "homepage"))
 | 
			
		||||
                       (synopsis ,(metadata-ref opam-content "synopsis"))
 | 
			
		||||
                       (description ,(metadata-ref opam-content "description"))
 | 
			
		||||
                       (description ,(beautify-description
 | 
			
		||||
                                      (metadata-ref opam-content "description")))
 | 
			
		||||
                       (license ,(spdx-string->license
 | 
			
		||||
                                  (metadata-ref opam-content "license"))))
 | 
			
		||||
                    (filter
 | 
			
		||||
| 
						 | 
				
			
			
 | 
			
		|||
| 
						 | 
				
			
			@ -471,7 +471,7 @@ VERSION, SOURCE-URL, HOME-PAGE, SYNOPSIS, DESCRIPTION, and LICENSE."
 | 
			
		|||
                   ,@(maybe-inputs native-inputs 'native-inputs)
 | 
			
		||||
                   (home-page ,home-page)
 | 
			
		||||
                   (synopsis ,synopsis)
 | 
			
		||||
                   (description ,description)
 | 
			
		||||
                   (description ,(beautify-description description))
 | 
			
		||||
                   (license ,(license->symbol license)))
 | 
			
		||||
                upstream-dependencies))))))))
 | 
			
		||||
 | 
			
		||||
| 
						 | 
				
			
			
 | 
			
		|||
		Reference in a new issue