EDIT_THIS ADD_JOURNAL ADD_ISSUE ADD_ARTICLE PUBLISH ?

Content creation via the terminal 👷

article⁄Content creation via the terminal 👷
contributor⁄
abstract⁄(Internal) Guide for creating new content via the terminal.
keywords⁄internalguidejournal management

1. Creating new content via the terminal

The optimal way for creating new content (a new Markdown file) is via the terminal. To do so open a terminal window and navigate to the root directory of the project. The general command pattern for creating new content is:

hugo new <contentType>/filename.md

Where <contentType> corresponds to a predefined type and corresponding folder (article, issue, contributor, editor, and print). When created via the terminal, each newly created item:

Make sure to follow §⁄file naming conventions, and provide adequate commit messages for any additions or modifications.

Note: this workflow requires a local clone of the repository as well as a Hugo installation, in addition to repository credentials.

2. File naming conventions, Hugo commands, and instructions for creating new entries

File naming:

Examples, Hugo commands, and instructions, per entry type:

Type Filename convention Hugo command Instructions template
contributor name-surname.md hugo new contributor/name-surname.md article⁄New contributor archetype
editor name-surname.md hugo new editor/name-surname.md article⁄New editor archetype
issue (x is number) issue-x.md hugo new issue/issue-x.md article⁄New issue archetype
article article-short-title.md hugo new article/article-short-title.md article⁄New article archetype
print (issue) p-issue-x.md hugo new print/p-issue-x.md article⁄New print archetype
print (article) p-article-short-title.md hugo new print/p-article-short-title.md
Table 1: File naming conventions, Hugo commands, and instructions per content type.

Note: Creating a new print file can break the site if (a) the print: target points to an inexistent file, or if (b) a public print item points to a non-published target.

3. Archetypes

New content is generated following archetypes (see root/archetypes/). Archetypes are Markdown files and can be thought of as templates that pertain to specific content types, and dictate the content to be included upon creating a new file.

Currently, archetypes will be generated with a set of instructions for their creator to follow in the form of a to-do list.

4. Steps for creating, editing, and publishing new content

  1. Create a new file, named according to §⁄file naming conventions.
  2. Open the new file, and follow the included instructions to fill in the metadata fields:
    1. add your name in the author field
    2. edit header information (title, keywords, abstract, etc.)
  3. Edit file content.
  4. Commit changes via Git when necessary.
  5. When editing is done and the new entry is ready for publishing, change draft: true to draft: false.
  6. Commit changes via Git.
  7. To recompile the site and include these changes include the keyword !publish! in your commit message.