From patchwork Wed Jun 2 19:31:50 2021 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Patchwork-Submitter: Luis Felipe X-Patchwork-Id: 29801 Return-Path: X-Original-To: patchwork@mira.cbaines.net Delivered-To: patchwork@mira.cbaines.net Received: by mira.cbaines.net (Postfix, from userid 113) id 52FAB27BC78; Wed, 2 Jun 2021 20:33:15 +0100 (BST) X-Spam-Checker-Version: SpamAssassin 3.4.2 (2018-09-13) on mira.cbaines.net X-Spam-Level: X-Spam-Status: No, score=-2.8 required=5.0 tests=BAYES_00,DKIM_SIGNED, FREEMAIL_FROM,MAILING_LIST_MULTI,RCVD_IN_MSPIKE_H4,RCVD_IN_MSPIKE_WL, SPF_HELO_PASS,T_DKIM_INVALID,URIBL_BLOCKED autolearn=unavailable autolearn_force=no version=3.4.2 Received: from lists.gnu.org (lists.gnu.org [209.51.188.17]) by mira.cbaines.net (Postfix) with ESMTPS id 4B3DA27BC81 for ; Wed, 2 Jun 2021 20:33:11 +0100 (BST) Received: from localhost ([::1]:39910 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1loWc2-0004nP-6M for patchwork@mira.cbaines.net; Wed, 02 Jun 2021 15:33:10 -0400 Received: from eggs.gnu.org ([2001:470:142:3::10]:39150) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1loWbu-0004j4-2l for guix-patches@gnu.org; Wed, 02 Jun 2021 15:33:02 -0400 Received: from debbugs.gnu.org ([209.51.188.43]:58052) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1loWbt-0006Ic-Qe for guix-patches@gnu.org; Wed, 02 Jun 2021 15:33:01 -0400 Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84_2) (envelope-from ) id 1loWbt-0006lD-NG for guix-patches@gnu.org; Wed, 02 Jun 2021 15:33:01 -0400 X-Loop: help-debbugs@gnu.org Subject: [bug#48637] [PATCH] website: Add publications page Resent-From: Luis Felipe Original-Sender: "Debbugs-submit" Resent-CC: guix-patches@gnu.org Resent-Date: Wed, 02 Jun 2021 19:33:01 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 48637 X-GNU-PR-Package: guix-patches X-GNU-PR-Keywords: patch To: Ludovic =?utf-8?q?Court=C3=A8s?= Cc: "48637@debbugs.gnu.org" <48637@debbugs.gnu.org> Received: via spool by 48637-submit@debbugs.gnu.org id=B48637.162266233825936 (code B ref 48637); Wed, 02 Jun 2021 19:33:01 +0000 Received: (at 48637) by debbugs.gnu.org; 2 Jun 2021 19:32:18 +0000 Received: from localhost ([127.0.0.1]:41365 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1loWb6-0006kA-0T for submit@debbugs.gnu.org; Wed, 02 Jun 2021 15:32:18 -0400 Received: from mail4.protonmail.ch ([185.70.40.27]:39485) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1loWb3-0006jv-Gu for 48637@debbugs.gnu.org; Wed, 02 Jun 2021 15:32:10 -0400 Date: Wed, 02 Jun 2021 19:31:50 +0000 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=protonmail.com; s=protonmail; t=1622662319; bh=OTzOP1A+QHR8Xx33Jh7NuVxsE8H8fJJ3+AqHbg7rIH4=; h=Date:To:From:Cc:Reply-To:Subject:In-Reply-To:References:From; b=Sfi1HSlG5GOUoGq44G7TEcxxNNJOFdDeBpDit1gmFPX+wzrwFFzeQO8HjSDnTyge5 TR2vTRqgnvavpHWNfwvttw2+KphQpJQKzh/iGaUQynIeUbw/g/1iAkJQF9s286XcB3 qIDznMeo4iP8c/J3dJpXpxL8psyfcnKpxgCf8jbA= Message-ID: <4jhiBWvAzsdTXmZFj_GgZTPWkIZncoQeId2pbbzXXMRNFk0FPGJXxIrp8ysGXNwuZk54pS5l5Ba2jkRcqE8omsfVgItw1gMcDJW1tqMPn-M=@protonmail.com> In-Reply-To: <87bl8vi0d8.fsf@gnu.org> References: <4BtcqLwBY7LgeYhUd41lhUUAcT5n2Zn9OTJUzGswTuBpLla8nBHyrQ3kJzwEMI9E7MPEnr6wBqSeCMqByldZ6i5jPR8B7ZtEi0XhwextyQo=@protonmail.com> <87bl8vi0d8.fsf@gnu.org> MIME-Version: 1.0 X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list X-BeenThere: guix-patches@gnu.org List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: guix-patches-bounces+patchwork=mira.cbaines.net@gnu.org Sender: "Guix-patches" Reply-to: Luis Felipe X-ACL-Warn: , Luis Felipe via Guix-patches X-Patchwork-Original-From: Luis Felipe via Guix-patches via From: Luis Felipe X-getmail-retrieved-from-mailbox: Patches Hey, On Friday, May 28, 2021 11:06 AM, Ludovic Courtès wrote: > I see that you want to keep it open to non-academic publications, which > is a good idea. I wonder if there should be a visual distinction > between peer-reviewed scientific articles, journal articles, and other > types of publications? > > I started adding historical LWN articles (patch below; the titles look > funny in hindsight :-)), and wondered whether this was a good idea since > they would come first in the list. > > Thoughts? Here is a patch that adds publication types. From ef4e97ec9a49e65d70c9ba8d4c1926b2eeec2cba Mon Sep 17 00:00:00 2001 From: Luis Felipe Date: Wed, 2 Jun 2021 14:17:03 -0500 Subject: [PATCH] website: publications: Add publication type. * website/apps/media/types.scm (): Add "type" field. * website/apps/media/data.scm (publications): Specify publication types. * website/apps/media/templates/components.scm (publication->shtml): Show publication type. --- website/apps/media/data.scm | 21 ++++++++++++++------- website/apps/media/templates/components.scm | 8 +++++--- website/apps/media/types.scm | 15 +++++++++++---- 3 files changed, 30 insertions(+), 14 deletions(-) diff --git a/website/apps/media/data.scm b/website/apps/media/data.scm index fc7854e..812f9e3 100644 --- a/website/apps/media/data.scm +++ b/website/apps/media/data.scm @@ -105,40 +105,47 @@ distribution.")) #:title "Functional Package Management with Guix" #:url "https://arxiv.org/abs/1305.4584" #:authors "Ludovic Courtès" - #:date (string->date "2013-05-20" "~Y-~m-~d")) + #:date (string->date "2013-05-20" "~Y-~m-~d") + #:type (C_ "publication type" "Conference paper")) (publication #:title "Reproducible and User-Controlled Software Environments in HPC with Guix" #:url "https://hal.inria.fr/hal-01161771/en" #:authors (G_ "Ludovic Courtès, Ricardo Wurmus") - #:date (string->date "2015-07-25" "~Y-~m-~d")) + #:date (string->date "2015-07-25" "~Y-~m-~d") + #:type (C_ "publication type" "Conference paper")) (publication #:title "Code Staging in GNU Guix" #:url "https://arxiv.org/abs/1709.00833" #:authors "Ludovic Courtès" - #:date (string->date "2017-09-04" "~Y-~m-~d")) + #:date (string->date "2017-09-04" "~Y-~m-~d") + #:type (C_ "publication type" "Conference paper")) (publication #:title "Scientific Data Analysis Pipelines and Reproducibility" #:authors "Altuna Akalin" #:url "https://towardsdatascience.com/scientific-data-analysis-pipelines-and-reproducibility-75ff9df5b4c5" - #:date (string->date "2018-10-01" "~Y-~m-~d")) + #:date (string->date "2018-10-01" "~Y-~m-~d") + #:type (C_ "publication type" "Article")) (publication #:title "Reproducible Genomics Analysis Pipelines with GNU Guix" #:url "http://dx.doi.org/10.1093/gigascience/giy123" #:authors "Ricardo Wurmus, Bora Uyar, Brendan Osberg, Vedran Franke, \ Alexander Gosdschan, Katarzyna Wreczycka, Jonathan Ronen, Altuna Akalin" - #:date (string->date "2018-10-02" "~Y-~m-~d")) + #:date (string->date "2018-10-02" "~Y-~m-~d") + #:type (C_ "publication type" "Journal article")) (publication #:title "Guix: A most advanced operating system" #:url "https://ambrevar.xyz/guix-advance/index.html" #:authors "Pierre Neidhardt" - #:date (string->date "2019-01-14" "~Y-~m-~d")) + #:date (string->date "2019-01-14" "~Y-~m-~d") + #:type (C_ "publication type" "Article")) (publication #:title "Scalable Workflows and Reproducible Data Analysis for Genomics" #:url "https://link.springer.com/protocol/10.1007%2F978-1-4939-9074-0_24" #:authors "Francesco Strozzi, Roel Janssen, Ricardo Wurmus, \ Michael R. Crusoe, George Githinji, Paolo Di Tommaso, Dominique Belhachemi, \ Steffen Möller, Geert Smant, Joep de Ligt, Pjotr Prins" - #:date (string->date "2019-07-06" "~Y-~m-~d")))) + #:date (string->date "2019-07-06" "~Y-~m-~d") + #:type (C_ "publication type" "Book chapter")))) (define screenshots diff --git a/website/apps/media/templates/components.scm b/website/apps/media/templates/components.scm index ce9d944..20fa3a9 100644 --- a/website/apps/media/templates/components.scm +++ b/website/apps/media/templates/components.scm @@ -46,9 +46,11 @@ (p (@ (class "publication-info")) - ;; TRANSLATORS: <1/> is a date, and <2/> a list of authors. - ,(G_ `("Published " ,date " by " - ,(publication-authors publication) "")))))) + ;; TRANSLATORS: <1/> is a publication type, <2/> is a date, and + ;; <3/> is a list of authors. + ,(G_ + `("" ,(publication-type publication) ". Published " ,date + " by " ,(publication-authors publication) ". ")))))) (define (screenshot->shtml shot) diff --git a/website/apps/media/types.scm b/website/apps/media/types.scm index 579e642..2c219e5 100644 --- a/website/apps/media/types.scm +++ b/website/apps/media/types.scm @@ -11,6 +11,7 @@ publication-date publication-language publication-title + publication-type publication-url screenshot screenshot? @@ -66,20 +67,26 @@ ;;; IETF language tag corresponding to the language in which the ;;; publication is written. ;;; +;;; type (string) +;;; The kind of publication. See the list of publications in the +;;; (apps media data) module for examples. +;;; +;;; (define-record-type - (make-publication title url authors date language) + (make-publication title url authors date language type) publication? (title publication-title) (url publication-url) (authors publication-authors) (date publication-date) - (language publication-language)) + (language publication-language) + (type publication-type)) ;;; Helper procedures. -(define* (publication #:key title url authors date (language "en")) +(define* (publication #:key title url authors date (language "en") type) "Return a object with the given attributes." - (make-publication title url authors date language)) + (make-publication title url authors date language type)) ;;; Screenshot (record type) base-commit: aa3ec5059f92ac5a0a47367cb886c87bb26d44fa -- 2.31.1