https://github.com/batoolmm/nf-co.re
Code and files for the main nf-core website.
Science Score: 18.0%
This score indicates how likely this project is to be science-related based on various indicators:
-
✓CITATION.cff file
Found CITATION.cff file -
○codemeta.json file
-
○.zenodo.json file
-
○DOI references
-
○Academic publication links
-
○Academic email domains
-
○Institutional organization owner
-
○JOSS paper metadata
-
○Scientific vocabulary similarity
Low similarity (13.3%) to scientific vocabulary
Repository
Code and files for the main nf-core website.
Basic Info
- Host: GitHub
- Owner: BatoolMM
- License: mit
- Language: PHP
- Default Branch: master
- Homepage: https://nf-co.re
- Size: 94.2 MB
Statistics
- Stars: 1
- Watchers: 0
- Forks: 0
- Open Issues: 0
- Releases: 0
Metadata Files
README.md

nf-co.re
This repository contains code for the nf-core website: http://nf-co.re/
Packages used
Here's how the website is built:
- Language: PHP
- HTML / CSS / JS framework: Bootstrap v5
- JavaScript libraries:
- jQuery
- Popper.js (used for bootstrap tooltips)
- highlightjs (syntax highlighting)
- Leaflet (contributor map)
- Moment.js (time and date parsing)
- Chart.js (statistics plots)
- hammer.js (mobile touch interaction handling)
- chartjs-plugin-zoom (Zoom and pan plugin for Chart.js)
- Canvas2Svg.js (SVG exports of Chart.JS plots)
- FileSaver.js (Trigger browser downloads from in-page data, used to save plot SVGs to files)
- jQuery table sorter (sorting tables)
- PHP Markdown parsing: Parsedown and Parsedown Extra
- SVG icons: http://www.flaticon.com, https://worldvectorlogo.com/
Development
Getting the code
To make edits to the website, fork the repository to your own user on GitHub and then clone to your local system.
bash
git clone git@github.com:[USERNAME]/nf-co.re.git
cd nf-co.re/
Running a local server
Ok, you're ready! To run the website locally, just start the apache-php server with:
bash
docker compose up
NB: If you are using a Mac with Apple silicon, you need to run:
bash docker compose -f m1-docker-compose.yml up
You should then be able to access the website in your browser at http://localhost:8888/.
If you prefer, you can also use a tool such as MAMP - if so,
set the base directory to /path/to/nf-co.re/public_html in Preferences > Web-Server > Document Root and then hit Start Servers.
Most of the hand-written text is in /markdown, to make it easier to write. The PHP files in /public_html then parse this into HTML dynamically, if supplied with a filename.
Note that the .htaccess file is set up to remove the .php file extensions in URLs.
First-run
Much of the site is powered by a pipelines.json file.
The webserver does this automatically when GitHub events trigger an update, but you'll need to run the script manually.
Access tokens
First you'll need a config.ini text file with values for github_username and github_access_token.
See instructions on how to get a GitHub OAuth token (the token only needs the public_repo permission).
This file is ignored in .gitignore for security reasons.
For the MySQL database you should also add the following values:
ini
host = 'db'
port = '3306';
dbname = 'nfcore';
username = 'nfcore_admin';
password = 'PEBBLY8exhibit_mead1cilium6despise'
Running PHP scripts
It's easiest to run these first manual update scripts on the command line. If you have PHP available
then you may be able to do this directly. Alternatively, if you are using Docker as above then you can
open a shell inside the running container. The container is typically named web (you can check this
with the docker ps command), so you can open an interactive shell using the following command:
bash
docker exec -it web /bin/bash
cd var/www/
Update scripts
The following command will create public_html/pipelines.json, which is used by the website.
bash
php update_pipeline_details.php
To update the modules database (from within the docker container) run:
bash
docker exec -it nf-core-web /usr/local/bin/php /var/www/update_module_details.php
Note that this is also ignored in the .gitignore file and will not be tracked in git history.
Optionally, once you've done that, you can grab the pipeline traffic, issue statistics and font awesome icons:
bash
php update_issue_stats.php
php update_stats.php
php update_fontawesome_icons.php
Note that your GitHub account needs push rights for the nf-core permission for the update_stats.php to work.
This creates nfcore_stats.json, nfcore_issue_stats.json and public_html/assets/js/fa-icons.json,
all also ignored in .gitignore.
Production Server Setup
Deployment
The website is deployed via GitHub Actions (.github/workflows/web-deploy.yml).
This script runs PHP composer and npm, then syncs the required files to the web server via FTP.
Tools API docs
Tools docs are built using GitHub Actions on the nf-core/tools repo using Sphinx. These actions sync the built HTML files via FTP.
GitHub web hooks
There is a GitHub web hook at the nf-core organisation level which triggers the pipeline update script whenever a repo is created, or has a release etc.
This pings the deploy_pipelines.php script.
Stats cronjob
The web server needs the following cronjobs running to scrape statistics and udates:
cron
0 0 * * * /usr/local/bin/php /path/to/deployment/update_stats.php >> /home/nfcore/update.log 2>&1
0 2 * * * /usr/local/bin/php /path/to/deployment/update_issue_stats.php >> /home/nfcore/update.log 2>&1
0 0 * * 0 /usr/local/bin/php /path/to/deployment/update_fontawesome_icons.php >> /home/nfcore/update.log 2>&
Remember to replace /path/to/deployment/ with your actual deployment directory.
The update_issue_stats.php script can use a lot of GitHub API calls, so should run at least one hour after the update_stats.php script last finished.
This is not because the script takes an hour to run, but because the GitHub API rate-limiting counts the number of calls within an hour.
Contribution guidelines
If you are looking forward to contribute to the website or add your institution to the official list of contributors, please have a look at the CONTRIBUTING.md.
Community
If you have any questions or issues please send us a message on Slack.
Credits
Phil Ewels (@ewels) built the website, but there have been many contributors to the content and documentation. More recently, @mashehu has done a great deal of work with the code. See the repo contributors for more.
Kudos to the excellent npm website, which provided inspiration for the design of the pipeline pages.
Owner
- Name: Batool Almarzouq
- Login: BatoolMM
- Kind: user
- Company: University of Liverpool, Alan Turing Institute
- Website: https://batool-almarzouq.netlify.app/
- Twitter: batool664
- Repositories: 48
- Profile: https://github.com/BatoolMM
Ph.D. in Biochemistry. Experience in cancer bioinformatics, RNA-Seq, network biology, pathway enrichment, and integrated –omics analyses, Docker, HPC (She/her).
Citation (CITATION.cff)
cff-version: 1.2.0
message: 'If you use `nf-core tools` in your work, please cite the `nf-core` publication'
authors:
- family-names: Ewels
given-names: Philip
- family-names: Peltzer
given-names: Alexander
- family-names: Fillinger
given-names: Sven
- family-names: Patel
given-names: Harshil
- family-names: Alneberg
given-names: Johannes
- family-names: Wilm
given-names: Andreas
- family-names: Garcia
given-names: Maxime Ulysse
- family-names: Di Tommaso
given-names: Paolo
- family-names: Nahnsen
given-names: Sven
title: 'The nf-core framework for community-curated bioinformatics pipelines.'
version: 2.4.1
doi: 10.1038/s41587-020-0439-x
date-released: 2022-05-16
url: https://github.com/nf-core/tools
prefered-citation:
type: article
authors:
- family-names: Ewels
given-names: Philip
- family-names: Peltzer
given-names: Alexander
- family-names: Fillinger
given-names: Sven
- family-names: Patel
given-names: Harshil
- family-names: Alneberg
given-names: Johannes
- family-names: Wilm
given-names: Andreas
- family-names: Garcia
given-names: Maxime Ulysse
- family-names: Di Tommaso
given-names: Paolo
- family-names: Nahnsen
given-names: Sven
doi: 10.1038/s41587-020-0439-x
journal: nature biotechnology
start: 276
end: 278
title: 'The nf-core framework for community-curated bioinformatics pipelines.'
issue: 3
volume: 38
year: 2020
url: https://dx.doi.org/10.1038/s41587-020-0439-x
GitHub Events
Total
Last Year
Dependencies
- actions/checkout v3 composite
- actions/setup-node v2 composite
- actions/checkout v3 composite
- actions/setup-node v2 composite
- actions/checkout v3 composite
- actions/setup-python v3 composite
- ewels/rich-codex main composite
- nf-core/setup-nextflow v1 composite
- SamKirkland/FTP-Deploy-Action 4.1.0 composite
- actions/checkout v3 composite
- actions/setup-node v1 composite
- composer 2.1
- mysql 8.0
- node 16-alpine3.12
- webdevops/php-apache 7.4
- composer 2.1
- mariadb latest
- node 16-alpine3.12
- 152 dependencies
- @prettier/plugin-php ^0.18.4 development
- bootstrap 5.1.1 development
- bootstrap-dark-5 1.1.1 development
- bootstrap-print-css ^1.0.1 development
- prettier ^2.6.1 development
- @highlightjs/cdn-assets ^11.6.0
- autoprefixer ^10.0.2
- aws-sdk ^2.994.0
- chart.js ^2.9.4
- chartjs-plugin-zoom ^0.7.7
- datatables.net ^1.11.3
- datatables.net-bs5 ^1.11.2
- file-saver ^2.0.5
- hammerjs ^2.0.8
- jquery ^3.6.0
- jquery-ui-dist ^1.12.1
- leaflet ^1.7.1
- moment ^2.29.4
- moment-timezone ^0.5.35
- postcss-cli ^8.2.0
- sass ^1.29.0
- showdown ^1.9.1
- tablesorter ^2.31.3
- abraham/twitteroauth ^2.0
- erusev/parsedown 1.8.0-beta-7
- erusev/parsedown-extra 0.8.0-beta-1
- mustangostang/spyc =0.6.2
- spatie/calendar-links 1.8
- symfony/yaml ^5.3
- abraham/twitteroauth 2.0.2
- composer/ca-bundle 1.2.10
- erusev/parsedown 1.8.0-beta-7
- erusev/parsedown-extra 0.8.0-beta-1
- mustangostang/spyc 0.6.2
- spatie/calendar-links 1.8.0
- symfony/deprecation-contracts v2.4.0
- symfony/polyfill-ctype v1.23.0
- symfony/yaml v5.3.6