Code Monkey home page Code Monkey logo

hpc-carpentry.github.io's Introduction

check, build, deploy hpc-carpentry.org

The HPC Carpentry Website

This is the repository for the HPC Carpentry website (and directly based on the Carpentries website). Please submit additions and fixes as pull requests to our GitHub repository.

Lessons are not stored in this repository. Please see the HPC Carpentry lessons page, for links to the many individual lesson repositories. You can find the official Carpentries lessons at the Software Carpentry lessons page, the Data Carpentry lessons page, or the Library Carpentry lessons page.

HPC Carpentry, like The Carpentries (Software, Data, and Library Carpentry), is an open project, and we welcome contributions of all kinds. By contributing, you are agreeing that The Carpentries may redistribute your work under these licenses, and to abide by our code of conduct.

Setup

The website uses Jekyll, a static website generator written in Ruby. You need to have Version 2.7.1 or higher of Ruby and the package manager Bundler. (The package manager is used to make sure you use exactly the same versions of the Ruby Gems as we do.) After checking out the repository, please install Jekyll and dependencies by running

$ bundle install

You may consult Using Jekyll with Pages for further instructions.

Previewing

Please do not use jekyll build or jekyll serve directly to build or view the website. Instead, you should use the following commands:

  • make or make commands: list available commands.
  • make data: (optionally) generate the dynamic data (see Data Files to see the requirements for this step)
  • make serve: build files locally and run a server at http://0.0.0.0:4000/ for viewing. This is the best way to preview the site.
  • make site: build files locally, but do not serve them dynamically.
  • make clean removes the _site directory and any Emacs editor backup files littering the source directories.

The details describes a few more advanced commands as well.

Development

To write a blog post, create a file called _posts/YYYY/MM/YYYY-MM-DD-some-title.html or _posts/YYYY/MM/YYYY-MM-DD-some-title.md (for HTML and Markdown respectively). YYYY is the 4-digit year of the post, MM the 2-digit month, and DD the 2-digit day; some-title can be any hyphenated string of words that do not include special characters such as quotes. Please do not use underscores or periods in the names. When published, your blog post will appear as https://hpc-carpentry.org/blog/YYYY/MM/some-title.html.

The YAML header of a blog post must look like this:

---
layout: page
authors: ["Your Name"]
title: "A Title-Cased Title for the Post"
date: YYYY-MM-DD
time: "hh:mm:ss"
category: ["Some Category", "Some Other Category"]
---

where YYYY-MM-DD is replaced by the post's date and hh:mm:ss by the post's time. Note that the time must be quoted so that the colons it contains do not confuse Jekyll's YAML parser. Note also that authors is a list. If the post has more than one author, please format the list like this:

...
authors: ["First Author", "Second Author", "Third Author"]
...

rather than running all the authors' names together in one long string.

To create a new page, add a file to the pages directory. This can be written in either Markdown or HTML, and must have the following YAML header:

layout: page-fullwidth
permalink: /some/path/
title: Title in Title Case

You must then also add the page to _data/navigation.yml, which is used to generate the site's pull-down navigation menu.

To add a workshop, fill in the workshop request form online. You should fill in this form even for self-organized workshops in order to get your workshop into the Carpentries database.

The Details

How is the site built and rendered?

The website is built with a GitHub Action, configured in .github/workflows/build-and-deploy.yml. Each time a commit is pushed to the default branch of the repository (main) and every 24 hours, the GitHub Action does the following:

  1. Validate the YAML headers of all the pages and blog posts.
  2. Update the time-dependent content (list of lessons, list of "Help Wanted" issues, etc.). For details on how these data files can be generated see the next section.
  3. Build and deploy the website to https://www.hpc-carpentry.org.

Data Files

The data files for the workshops and the instructors are generated by our GitHub Action using the scripts found in the feeds folder.

To generate these feeds locally,

make data

To successfully execute this step you need an appropriate R environment (with packages colorspace, deplyr, gh, jsonlite, purrr, and tibble โ€” see feeds/README.md) and the environment variable GITHUB_PAT configured with your GitHub Personal Authentication Token so that GitHub does not limit your API usage. When generating this PAT, you should not need to set any scopes (not even "repo"): this process is read-only, and our work is public.

Styles

The files in the _sass and assets directories control the appearance of this site.

hpc-carpentry.github.io's People

Contributors

anelda avatar carpentries-bot avatar elizabethwilliams8 avatar elletjies avatar erinbecker avatar fmichonneau avatar jduckles avatar k8hertweck avatar karenword avatar kariljordan avatar katrintirok avatar kmomar avatar maneesha avatar nerk avatar npalopoli avatar ocaisa avatar orchid00 avatar phlow avatar raynamharris avatar reid-a avatar rgaiacs avatar serahkiburu avatar sheraaronhurt avatar talishask avatar tkphd avatar tobyhodges avatar tracykteal avatar twisterrob avatar weaverbel avatar zkamvar avatar

Stargazers

 avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar

hpc-carpentry.github.io's Issues

Broken "contact us" link

On line 63 of pages/community-lessons.md, there's a "contact us" link that uses the site.contact variable as a target -- it looks like it's meant to be a mailto: link, maybe? But it resolves to https://www.hpc-carpentry.org/community-lessons/[email protected], which starts out looking like a web URL, but turns into an e-mail at the end.

This was spotted by Victor Eijkhout when he tried to reach out to us.

I'm creating this issue instead of fixing it because I'm not immediately familiar with the variable structure of the site -- I probably should be, and I may come back to it later, but if someone who is more current on the site wants to jump in and fix it, I certainly won't stop them!

Clarify Teach Menu

Entire menu links to, or duplicates verbatim, Carpentries pages.
Need to create customized versions, or drop over-reaching entries.

Anyone know some R?

Our CI to build the site is currently failing due to

`%<<%` <- function(x, y) {
if (identical(length(x), 0L)) return(y)
if (is.null(x) || identical(x, "") ||
is.na(x)) return(y)
x
}

which is now problematic with more recent versions of R. From https://stackoverflow.com/questions/72848442/r-warning-lengthx-2-1-in-coercion-to-logical1 this should be fixable but I'm wary of my ability to do this given how little I know of R

Accessibility issue with web site

Hello

I have just visited the HPC-Carpentry web site. I have some significant vision issues (I have sight just very poor). There are two issues with the font used in the paragraphs that make them unreadable to me. I was not able to see/find a maintainer email address but did find a link to the various carpentries repos. I opened an issue in one of them and they directed me here.

The problems are that the paragraph font color appears to be maybe mid-or light grey. and that the font is very thin. The grey text sinks into the white background and the thinness of the font type makes that worse.

Can you please change the font color to black on white background... actually black against all light/translucent backgrounds? Also please use "normal" weight fonts please.

Thank you

Document the site-building process

The website is built by a fairly complicated set of functions that search for tags across github repositories to build the various lists of content, and also ingests a Google sheets sheet for additional content. Probably this will all change in the near term as the site gets more attention. We should document how it all works once it's stabilized.

Creating our own feeds for our repos

The Carpentries code for generating their feeds is at https://github.com/carpentries/feeds.carpentries.org. We could use this code ourselves to generate feeds related to our own repos that we automatically pull into our website. With our current build process we wouldn't need to do that as a separate step, we can run it as part of the process.

We could then create a cron Action to automatically build the page once every so often.

branch protection

The branches in this repo are not protected.

  • The main branch should require at least one approving review.
  • If possible, the gh-pages branch should only be writable by Netlify.

testimonials

Get permission and create a page (under /pages/testimonials.md) for learner testimonials.
The following template may come in handy:

---
layout: page-fullwidth
permalink: /testimonials/
title: Testimonials from Workshop Attendees
excerpt: testimonials about The Carpentries from our community
---
{:auto_ids}
Anonymous scientist from the field of Magnetohydrodynamics
:    Well explained and thanks a lot for answering all my
     stupid questions. I had to work with a script (on the
     cluster) in the past without understanding what I did
     - now I know and can improve even more.

---

*Have a story of your own you'd like to share? Please [let us know](mailto:{{site.contact}}?subject=testimonial).*

Clarify Main Page

Delete logos & links to sister programs. Replace subscription box with Slack info, maybe calendar link.

Clarify core curriculum

As mentioned in #54 and #74, the lesson page is difficult to parse. This could be improved by outlining the core curriculum for an HPC Carpentry workshop like what's done on the Organization README. I personally like the table format used by the other Carpentries.

I could see two different places to add a table and short description:

  1. To the current lesson page:
    • Pros: Brings structure to the page; keeps the same URL
    • Cons: Adds more to an already dense page; the Software Carpentry shell lesson does not fit into any of the three categories on the community-lessons page
  2. To a new page:
    • Pros: Cleaner; clarifies what's being actively maintained(?)
    • Cons: Duplicates lesson listings

I personally lean towards option 2 for simplicity, but an overhaul of the lesson page could make 1 more attractive. In particular, the Library Carpentry's presentation is pretty clear and something similar could be adapted. I imagine one table with the Core Curriculum and another with the HPC Carpentry lessons as an Extended Curriculum along with "status" tags to clarify retired or no-longer-maintained lessons.

Use Carpentries workshop database

Currently, our Workshop Registration form is our own tool. It would be much more efficient to use The Carpentries' toolchain, which feeds a public database of workshops.

LLNL blog post exists but is a bit sparse

I'm struggling a bit with the long-promised LLNL blog post. A version is on the llnl_blog_post branch of this repo, I'm reaching out especially to @tkphd and @xorJane (who were there) to maybe help punch it up a bit, but input from anyone would be welcome. Thanks!

Rename this repo to hpc-carpentry.github.io

We should archive the existing hpc-carpentry.github.io repo and rename this one to that name. This has the benefit that all our lessons will then appear under hpc-carpentry.org/lesson-title.

Add links to relevant existing lessons

In the coordination repo, there's an issue where a number of interesting resources have been identified that could be linked to from the website.

This issue is for discussion and possibly implementation of the links in the site.

Citations & Publications

http://www.hpc-carpentry.org/citations/ is sparse as can be, and perhaps in the wrong scope. I propose moving it to "publications," and generating a list of resources useful to us as we develop the curriculum, to include the items mentioned on Slack:

Clarify Footer

  • About HPC Carpentry: rephrase to make it clear we operate in the spirit of The Carpentries, but not as an official program. (This is excerpted from the main About Us page, I think.)
  • Links:
    • Create a landing page for our Code of Conduct, with instructions to contact a Steering Committee member to report a breach. Then link out to The Carpentries' policy.
    • Create a landing page for our Handbook, or drop it.
    • Create a landing page for our Privacy Policy, with instructions to contact a Steering Committee member to report a breach. Then link out to The Carpentries' policy.
    • Drop Annual Reports.
    • Create a new section for Carpentries Links to redirect to our sister programs.

mission statement

In about.md:

Mission: We're still working on our mission statement, but when it lands it's going to be amazing!

using `orgs` API to try to access user repositories

The website builds are currently failing, due to the changes made to feeds/other_lessons.R in 13a0ea3.

The problem is that the get_org_topics function used on line 47 of that file

  frobnitzem <- get_org_topics("frobnitzem")

uses the get_list_repos function defined in feeds/utils.R, which makes a call to the GitHub organizations API, to try to get a list of repositories for an organisation. frobnitzem is a user account, so should be queried via the users API. See the difference between the current call that is being made

https://api.github.com/orgs/frobnitzem/repos

and the result of the equivalent call made via the users API

https://api.github.com/users/frobnitzem/repos

I am fairly certain that this is the problem, but less confident about the best solution. I suppose you would need to adjust get_list_repos to accept an optional parameter that tells it to query the users API instead of the orgs API?

weekly build failure

@ocaisa, the weekly site re-build hit this snag:

Lmod has detected the following error: These module(s) or extension(s) exist
but cannot be loaded as requested: "OpenBLAS/0.3.15-GCC-10.3.0"
   Try: "module spider OpenBLAS/0.3.15-GCC-10.3.0" to see how to load the
module(s).

Can you troubleshoot?

Clarify Learn Menu

Workshops:

  • Create a derivative work from The Carpentries' version, cleaned up for the parts relevant to our smaller organization.
  • Create a YAML/JSON file for workshops, from which we can create a list of upcoming & past workshops. Possibly using a web form. Contents: Organizer's Name, Location, Link to Workshop, and Date.
  • Create pre-, post-, and 3-month survey forms

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.