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

Species archetypes 🎃 #65

Open
wants to merge 60 commits into
base: main
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from 58 commits
Commits
Show all changes
60 commits
Select commit Hold shift + click to select a range
83db6c7
Bundle assembly resources
kwentine Oct 19, 2024
a78ee2c
Simplify species assembly layout
kwentine Oct 19, 2024
700abd4
Add archetype stub
kwentine Oct 21, 2024
f1fdc66
Start halloween experiment
kwentine Oct 26, 2024
2170e58
Specify cover image as page resource
kwentine Oct 26, 2024
afd4ed1
Use lastmod property in last_updated partial
kwentine Oct 26, 2024
9da233a
fixup! Specify cover image as page resource
kwentine Oct 26, 2024
5f58849
Properly name pumpkin directory
kwentine Oct 26, 2024
b971432
Use concise form of crossorigin HTML attribute
kwentine Oct 26, 2024
15140fc
Show debug information in development environment
kwentine Oct 26, 2024
a2f2634
Add forgotten content directory
kwentine Oct 26, 2024
8d753d7
Use XML taxonomy as resource
kwentine Oct 26, 2024
db7345a
Correct typo in .gitignore
kwentine Oct 28, 2024
07ae293
Generate lineage using a partial
kwentine Oct 28, 2024
1ff6d60
Comment taxonomy templates
kwentine Oct 28, 2024
1160dd8
Remove obsolete references
kwentine Oct 28, 2024
defc5f1
Create download page bundle
kwentine Oct 29, 2024
ac8fd6f
Remove unused data tables event listener
kwentine Oct 31, 2024
0de94d9
Remove labels assmbly description configuration
kwentine Oct 31, 2024
b7648a9
Partial for assembly stats table
kwentine Oct 31, 2024
9f32d16
fixup! Remove labels assmbly description configuration
kwentine Oct 31, 2024
0edfc6d
fixup! Partial for assembly stats table
kwentine Oct 31, 2024
2e0d0c5
Partial for annotation statistics
kwentine Oct 31, 2024
b2980ab
Shared context for assembly page tables
kwentine Oct 31, 2024
4f6165f
Restore contributions section
kwentine Oct 31, 2024
fabeaef
Minor tweaks
kwentine Oct 31, 2024
13b6b45
Add basic archetype
kwentine Oct 31, 2024
e08de83
Include placeholder image in archetype
kwentine Oct 31, 2024
4252a4b
Extensible assembly fields
kwentine Nov 16, 2024
8e5d859
Use templates for templates
kwentine Nov 16, 2024
37ed418
Allow optional fields defined globally
kwentine Nov 18, 2024
5e6a61b
Inline taxonomic lineage in archetype
kwentine Nov 18, 2024
8a12653
Add error handling to partials fetching ENA taxonomic information
kwentine Nov 19, 2024
ece0659
Restore dashing header
kwentine Nov 19, 2024
b324693
Define lineage fields in site parameters
kwentine Nov 19, 2024
9fbd520
Remove taxonomy.xml
kwentine Nov 19, 2024
2a4b49b
Introduce helper partial to fetch remote data
kwentine Nov 20, 2024
66da5a8
Uppercase only firts letter of scientific name
kwentine Nov 20, 2024
34ad61f
Allow to define taxonomic ranks at species level
kwentine Nov 20, 2024
fb74f20
GBIF usage key and Goat link support
kwentine Nov 20, 2024
4d0732e
Cleanup archetype content
kwentine Nov 20, 2024
9a2810c
Fix default map coordinates
kwentine Nov 20, 2024
c1cde56
Use simple quotes to appease syntax highlighter
kwentine Nov 20, 2024
4602489
Remove unnecessary intro bundle
kwentine Nov 20, 2024
53efb43
fixup! Use simple quotes to appease syntax highlighter
kwentine Nov 20, 2024
d41ab0f
Use medium date format to avoid ambiguities
kwentine Nov 20, 2024
87147ec
Introduce `species_bundle` namespace (formerly `halloween`)
kwentine Nov 20, 2024
25537e9
Explicit content type
kwentine Nov 20, 2024
c65dc67
Manage URL in site configuration
kwentine Nov 20, 2024
0fcaf2b
Bona fide pumpkin example
kwentine Nov 20, 2024
fa5eba7
Cascade draft status
kwentine Nov 21, 2024
fd1fe9e
Rename layouts
kwentine Nov 21, 2024
c298ee3
Remove unused layouts
kwentine Nov 21, 2024
b5f300e
Revert add_new_species
kwentine Nov 21, 2024
c9fc8db
Merge branch 'main' into archetypal-halloween
kwentine Nov 21, 2024
46fc111
Revert add_new_specie templates
kwentine Nov 21, 2024
85c710b
Revert out-of-topic changes
kwentine Nov 21, 2024
aeb558c
Genome portal kit 🎁
kwentine Nov 21, 2024
0c0c454
Restore assembly page weight
kwentine Nov 29, 2024
eccba11
Restore alias_file_url parameter
kwentine Nov 29, 2024
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 4 additions & 0 deletions hugo/config.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -12,6 +12,10 @@ markup:
endLevel: 4
ordered: false

module:
imports:
- path: genome-portal-kit

menus:
main:
- name: About
Expand Down
97 changes: 97 additions & 0 deletions hugo/content/species/cucurbita_pepo/_index.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,97 @@
---
date: 2024-11-20T16:23:21+01:00
title: Cucurbita pepo
subtitle:
lastmod: 2024-11-20T16:23:21+01:00
draft: true
cascade:
params:
draft: true
type: species_bundle
layout: "intro"
weight: 1

resources:
- title: 'Cucurbita pepo'
name: cover_image
src: "pepo.jpg"
params:
attribution: CC-BY-SA
link: "https://placehold.co/600x400/png"


lineage: {
"clade": {
"scientificName": "Embryophyta",
"taxId": "3193"
},
"class": {
"scientificName": "Magnoliopsida",
"taxId": "3398"
},
"family": {
"scientificName": "Cucurbitaceae",
"taxId": "3650"
},
"genus": {
"scientificName": "Cucurbita",
"taxId": "3660"
},
"kingdom": {
"scientificName": "Viridiplantae",
"taxId": "33090"
},
"order": {
"scientificName": "Cucurbitales",
"taxId": "71239"
},
"phylum": {
"scientificName": "Streptophyta",
"taxId": "35493"
},
"species": {
"scientificName": "Cucurbita pepo",
"taxId": "3663"
},
"subphylum": {
"scientificName": "Streptophytina",
"taxId": "131221"
},
"superkingdom": {
"scientificName": "Eukaryota",
"taxId": "2759"
},
"tribe": {
"scientificName": "Cucurbiteae",
"taxId": "1003878"
}
}
# Use this setting to override the default taxonomy ranks to display.
# See config/_default/params.yaml for the syntax to use.
taxonomy_ranks:
params:
banner_title: "Species overview"
goat_webpage: 'https://goat.genomehubs.org/record?recordId=3663&result=taxon&taxonomy=ncbi'

# Map
gbif_taxon_id: 2874508
latitude: 0
longitude: 0
initialZoom: 1

# Optional
iucn_category:
iucn_link:
swe_red_list:
swe_red_list_link:
---

### Description

#### Genome reference

#### References

#### Changelog

- Nov 20, 2024 - Species first published on the Portal
29 changes: 29 additions & 0 deletions hugo/content/species/cucurbita_pepo/assembly/assembly.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,29 @@
description:
name:
type:
level:
repr:
accession:
stats:
length:
gc:
contig:
contig_n50:
contig_l50:
contig_n90:
contig_l90:
scaffold:
scaffold_n50:
scaffold_l50:
scaffold_n90:
scaffold_l90:
scaffold_gt_10:
busco:
annotation:
gene_cnt:
transcript_cnt:
exons_avg:
gene_length_avg:
transcript_length_avg:
exon_length_avg:
intron_length_avg:
14 changes: 14 additions & 0 deletions hugo/content/species/cucurbita_pepo/assembly/contrib.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,14 @@
---
build:
list: never
publishResources: false
render: never
---
<!-- markdownlint-disable first-line-heading -->
### Contributor(s)

### Publication(s)

### Funding

### Acknowledgements
8 changes: 8 additions & 0 deletions hugo/content/species/cucurbita_pepo/assembly/index.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,8 @@
---
title: "Genome assembly"
type: species_bundle
layout: assembly
lastmod: 2024-11-21T10:58:49+01:00
---

### Methods
16 changes: 16 additions & 0 deletions hugo/content/species/cucurbita_pepo/download/data_tracks.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,16 @@
[
{
"dataTrackName": "Genome",
"description": "Reference genome sequence",
"fileName": "placeholder.fasta.gz",
"links": [
{"Download": "#"},
{"Website": "#"},
{"Article": "#"}
],
"accessionOrDOI": "GCA_1234",
"principalInvestigator": "Someone",
"principalInvestigatorAffiliation": "Some university",
"firstDateOnPortal": "15 October 2024"
}
]
7 changes: 7 additions & 0 deletions hugo/content/species/cucurbita_pepo/download/index.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,7 @@
---
title: "Download"
type: species_bundle
layout: download
weight: 3
lastmod: 2024-11-21T10:58:49+01:00
---
35 changes: 35 additions & 0 deletions hugo/content/species/cucurbita_pepo/lineage.default.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,35 @@
# Example lineage configuration.
# This format is expeced by the .Params.lineage front matter key in `_index.md`
clade:
scientificName: Embryophyta
taxId: "3193"
class:
scientificName: Magnoliopsida
taxId: "3398"
family:
scientificName: Cucurbitaceae
taxId: "3650"
genus:
scientificName: Cucurbita
taxId: "3660"
kingdom:
scientificName: Viridiplantae
taxId: "33090"
order:
scientificName: Cucurbitales
taxId: "71239"
phylum:
scientificName: Streptophyta
taxId: "35493"
species:
scientificName: Cucurbita pepo
taxId: "3663"
subphylum:
scientificName: Streptophytina
taxId: "131221"
superkingdom:
scientificName: Eukaryota
taxId: "2759"
tribe:
scientificName: Cucurbiteae
taxId: "1003878"
Binary file added hugo/content/species/cucurbita_pepo/pepo.jpg
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
8 changes: 8 additions & 0 deletions hugo/themes/genome-portal-kit/README.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,8 @@
# Genome portal
A Hugo theme for a genome portal embedding the JBrowse2 genome browser.

## Features

## Installation

## Configuration
57 changes: 57 additions & 0 deletions hugo/themes/genome-portal-kit/archetypes/species/_index.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,57 @@
{{- $scientificName := replace .File.ContentBaseName `_` ` ` | strings.FirstUpper -}}
---
date: {{ .Date }}
title: {{ $scientificName }}
subtitle:
lastmod: {{ .Date }}

draft: true
cascade:
params:
draft: true
type: species_bundle
layout: intro
weight: 1

resources:
- title: '{{ $scientificName }}'
name: cover_image
src: "placeholder.png"
params:
attribution: CC-BY-SA
link: "https://placehold.co/600x400/png"

{{ $taxId := partial "species_bundle/GetTaxId" $scientificName }}
lineage: {{ partial "species_bundle/LineageConfig" $taxId }}
# Use this setting to override the default taxonomy ranks to display.
# See config/_default/params.yaml for the syntax to use.
taxonomy_ranks:
params:
banner_title: "Species overview"
goat_webpage: '{{ printf
"https://goat.genomehubs.org/record?recordId=%s&result=taxon&taxonomy=ncbi"
$taxId
}}'

# Map
gbif_taxon_id: {{ partial "species_bundle/GetGbifKey.html" $scientificName }}
latitude: 0
longitude: 0
initialZoom: 1

# Optional
iucn_category:
iucn_link:
swe_red_list:
swe_red_list_link:
---

### Description

#### Genome reference

#### References

#### Changelog

- {{ .Date | time.Format ":date_medium" }} - Species first published on the Portal
Original file line number Diff line number Diff line change
@@ -0,0 +1,29 @@
description:
name:
type:
level:
repr:
accession:
stats:
length:
gc:
contig:
contig_n50:
contig_l50:
contig_n90:
contig_l90:
scaffold:
scaffold_n50:
scaffold_l50:
scaffold_n90:
scaffold_l90:
scaffold_gt_10:
busco:
annotation:
gene_cnt:
transcript_cnt:
exons_avg:
gene_length_avg:
transcript_length_avg:
exon_length_avg:
intron_length_avg:
Original file line number Diff line number Diff line change
@@ -0,0 +1,14 @@
---
build:
list: never
publishResources: false
render: never
---
<!-- markdownlint-disable first-line-heading -->
### Contributor(s)

### Publication(s)

### Funding

### Acknowledgements
Original file line number Diff line number Diff line change
@@ -0,0 +1,8 @@
---
title: "Genome assembly"
type: species_bundle
layout: assembly
kwentine marked this conversation as resolved.
Show resolved Hide resolved
lastmod: {{ .Date }}
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Could the lastmod be defined only in the species intro markdown page and this and the download file (hugo/themes/genome-portal-kit/archetypes/species/download/index.md) could read the lastmod from the intro page instead?

As an example I have that setup for the non-bundled approach in hugo/layouts/partials/last_updated.html

Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

It could certainly suit to our needs, but perhaps providing the lastmod field everywhere leaves more flexibility to the (very hypothetical) user (related to the discussion above). But I have no strong opinion on this.

---

### Methods
Original file line number Diff line number Diff line change
@@ -0,0 +1,16 @@
[
{
"dataTrackName": "Genome",
"description": "Reference genome sequence",
"fileName": "placeholder.fasta.gz",
"links": [
{"Download": "#"},
{"Website": "#"},
{"Article": "#"}
],
"accessionOrDOI": "GCA_1234",
"principalInvestigator": "Someone",
"principalInvestigatorAffiliation": "Some university",
"firstDateOnPortal": "15 October 2024"
}
]
Original file line number Diff line number Diff line change
@@ -0,0 +1,7 @@
---
title: "Download"
type: species_bundle
layout: download
weight: 3
lastmod: {{ .Date }}
---
kwentine marked this conversation as resolved.
Show resolved Hide resolved
Loading