Skip to content

Commit

Permalink
Line wrap README.md
Browse files Browse the repository at this point in the history
  • Loading branch information
davidchang-gov committed Jan 19, 2017
1 parent 4f6770a commit 725fbff
Showing 1 changed file with 61 additions and 18 deletions.
79 changes: 61 additions & 18 deletions README.md
Original file line number Diff line number Diff line change
@@ -1,34 +1,57 @@
US Digital Service Website
==========================

This repo is for our public-facing site, which is hosted on usds.gov. This site is the main funnel for USDS recruiting and outreach.
This repo is for our public-facing site, which is hosted on usds.gov. This
site is the main funnel for USDS recruiting and outreach.

Soon, this repo will also contain our assets on [whitehouse.gov](https://www.whitehouse.gov/digital/united-states-digital-service).
Soon, this repo will also contain our assets on
[whitehouse.gov](https://www.whitehouse.gov/digital/united-states-digital-service).

The site is built on the [U.S. Web Design Standards](https://playbook.cio.gov/designstandards/) and uses Jekyll to generate static pages.
The site is built on the [U.S. Web Design
Standards](https://playbook.cio.gov/designstandards/) and uses Jekyll to
generate static pages.

Setup
---
1. If you're using a Mac, install homebrew (see http://brew.sh/)
2. After installing git (`brew install git`), `cd` to the directory where you want to check-out the site, and then clone it (`git clone https://github.com/usds/website.git`)
3. Install rvm (`\curl -sSL https://get.rvm.io | sudo bash -s stable`), make your current user a member of the rvm group, and then install a new version of ruby (`rvm install 2.3.1`)
4. Install the `bundler` gem, then use bundler to install other project dependencies (`gem install bundler && bundle install`)
2. After installing git (`brew install git`), `cd` to the directory where you
want to check-out the site, and then clone it (`git clone
https://github.com/usds/website.git`)
3. Install rvm (`\curl -sSL https://get.rvm.io | sudo bash -s stable`), make
your current user a member of the rvm group, and then install a new version
of ruby (`rvm install 2.3.1`)
4. Install the `bundler` gem, then use bundler to install other project
dependencies (`gem install bundler && bundle install`)

Running
---
1. In the directory you checked out the website into, run `jekyll serve` to start the webserver
1. In the directory you checked out the website into, run `jekyll serve` to
start the webserver
2. Navigate to http://localhost:4000 in your browser to see your changes

Blogging
---
The U.S. Digital Service blog is currently maintained on Medium. This website provides summaries of the most recent posts. When we publish a new post, we must also create a new blog summary. The `Blog` summary page is automatically generated from individual blog summary Markdown files in the `_blog_summaries` folder.
The U.S. Digital Service blog is currently maintained on Medium. This website
provides summaries of the most recent posts. When we publish a new post, we
must also create a new blog summary. The `Blog` summary page is automatically
generated from individual blog summary Markdown files in the `_blog_summaries`
folder.

To create a new blog summary:
----

Create a new file in the `_blog_summaries` folder. Follow the file naming convention of starting the file name with the date of the blog post in the `YYYY-MM-DD` format, followed by a short description of the post, separated by an underscore. For example, to create a summary of a post about penguins published on April 1, 2016, you would create a file named `2016-04-01_penguins.md`.
Create a new file in the `_blog_summaries` folder. Follow the file naming
convention of starting the file name with the date of the blog post in the
`YYYY-MM-DD` format, followed by a short description of the post, separated by
an underscore. For example, to create a summary of a post about penguins
published on April 1, 2016, you would create a file named
`2016-04-01_penguins.md`.

Each blog post summary file must start with front-matter, in the YML format. This sets some variables that are used to build the blog summary page. After the front-matter, the remaining content in the markdown file will be used to generate the post summary. This content can be supplied in markdown format. Raw HTML can also be used.
Each blog post summary file must start with front-matter, in the YML format.
This sets some variables that are used to build the blog summary page. After
the front-matter, the remaining content in the markdown file will be used to
generate the post summary. This content can be supplied in markdown format.
Raw HTML can also be used.

An example post file is shown below:

Expand All @@ -41,18 +64,38 @@ image_description: Natalie Kates
date: 2016-03-23
---

Another week, another set of new smiling faces here at the U.S. Digital Service. This edition of “Meet the Team” adds a new twist. Fresh recruits shared their answers to a few question from the famous [Proust Questionnaire](https://en.wikipedia.org/wiki/Proust_Questionnaire). We know, we’re really earning that “Peace Corps for nerds” nickname.
Another week, another set of new smiling faces here at the U.S. Digital
Service. This edition of “Meet the Team” adds a new twist. Fresh recruits
shared their answers to a few question from the famous [Proust
Questionnaire](https://en.wikipedia.org/wiki/Proust_Questionnaire). We know,
we’re really earning that “Peace Corps for nerds” nickname.

```

A few notes on the above fields:

- `title`: The clickable headline of the blog post. Ordinarily, this should match the title of the post itself.
- `title`: The clickable headline of the blog post. Ordinarily, this should
match the title of the post itself.
- `medium_url`: The full link, including `https://` to the full post.
- `image_url`: A link to an image representing the post. You should choose an image that is wider than it is tall (i.e. 16:9 aspect ratio). If there is an image in the Medium post, we can link to it on Medium directly. Note that Medium's image link allows us to specify the size of the image, in the `max/xxx` part of the URL. Ordinarily, we should set this to `600`, as shown in the above example.
- `image_url`: A link to an image representing the post. You should choose an
image that is wider than it is tall (i.e. 16:9 aspect ratio). If there is an
image in the Medium post, we can link to it on Medium directly. Note that
Medium's image link allows us to specify the size of the image, in the
`max/xxx` part of the URL. Ordinarily, we should set this to `600`, as shown
in the above example.
- `image_description`: A short textual description of the image.
- `date`: The date the post was published, in `YYYY-MM-DD` format. This field is used to determine which post summaries are shown on the blog summary page.

Below the front matter (i.e. after the `---`) is the text that will appear as the summary of the blog. Ordinarily, this can be directly copied from the lede in our Medium post. Generally, this should be one single paragraph, without formatting. It can include links where appropriate. Links can be specified using the Markdown linking format, or by writing `<a>` tags directly.

Once a file matching this specification is saved into the `_blog_summaries` folder, the `/blog` page will be automatically re-generated to display the most recent summaries, with the most recent post appearing first. If this change is merged to the `gh-pages` branch of the site, the blog page will be updated.
- `date`: The date the post was published, in `YYYY-MM-DD` format. This field
is used to determine which post summaries are shown on the blog summary
page.

Below the front matter (i.e. after the `---`) is the text that will appear as
the summary of the blog. Ordinarily, this can be directly copied from the lede
in our Medium post. Generally, this should be one single paragraph, without
formatting. It can include links where appropriate. Links can be specified
using the Markdown linking format, or by writing `<a>` tags directly.

Once a file matching this specification is saved into the `_blog_summaries`
folder, the `/blog` page will be automatically re-generated to display the
most recent summaries, with the most recent post appearing first. If this
change is merged to the `gh-pages` branch of the site, the blog page will be
updated.

0 comments on commit 725fbff

Please sign in to comment.