{"id":17472992,"url":"https://github.com/llvm/www-template","last_synced_at":"2025-10-19T03:19:49.365Z","repository":{"id":258108394,"uuid":"844368037","full_name":"llvm/www-template","owner":"llvm","description":null,"archived":false,"fork":false,"pushed_at":"2024-11-25T17:00:39.000Z","size":422,"stargazers_count":2,"open_issues_count":0,"forks_count":2,"subscribers_count":3,"default_branch":"main","last_synced_at":"2025-04-22T10:35:25.485Z","etag":null,"topics":[],"latest_commit_sha":null,"homepage":null,"language":"HTML","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"mit","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/llvm.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null}},"created_at":"2024-08-19T05:39:01.000Z","updated_at":"2025-04-14T03:46:16.000Z","dependencies_parsed_at":"2024-10-26T09:09:33.642Z","dependency_job_id":"84d7387f-56e2-4be5-96c6-7eb8cfbb16de","html_url":"https://github.com/llvm/www-template","commit_stats":{"total_commits":43,"total_committers":1,"mean_commits":43.0,"dds":0.0,"last_synced_commit":"887689dbcd695d1ef50de71166accc32e9e86c12"},"previous_names":["llvm/www-template"],"tags_count":0,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/llvm%2Fwww-template","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/llvm%2Fwww-template/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/llvm%2Fwww-template/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/llvm%2Fwww-template/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/llvm","download_url":"https://codeload.github.com/llvm/www-template/tar.gz/refs/heads/main","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":250221573,"owners_count":21394732,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":[],"created_at":"2024-10-18T18:00:17.555Z","updated_at":"2025-10-19T03:19:44.309Z","avatar_url":"https://github.com/llvm.png","language":"HTML","funding_links":[],"categories":[],"sub_categories":[],"readme":"# www-template\n\nThis is a Hugo theme for the LLVM Compiler Infrastructure project. It provides a clean and modern design for the LLVM website.\n\n## Table of contents\n\n- [Features](#features)\n- [Installation](#installation)\n- [Configuration](#configuration)\n- [Creating new website](#creating-new-website)\n- [Creating new pages](#creating-new-pages)\n- [Using YAML data files](#using-yaml-data-files)\n- [Creating new shortcodes](#creating-new-shortcodes-using-yaml-data-files)\n\n## Features\n\n- Clean and modern design\n- Responsive layout\n- Easy configuration via `hugo.toml` or `config.toml`\n\n## Installation\n\n1. Clone the repository into your Hugo site's `themes` directory:\n   ```sh\n   git clone https://github.com/llvm/www-template themes/www-template\n   ```\n2. Update your site's `hugo.toml` or `config.toml` file to use the theme:\n   ```toml\n   theme = \"www-template\"\n   ```\n3. Install Post CSS CLI\n   ```sh\n   npm install postcss-cli \n   ```\n4. Run your site locally with the theme:\n   ```sh\n   hugo server\n   ```\n\n## Configuration\n\n`hugo.toml`\n\nThe `hugo.toml` file contains various configuration options for the theme. Below is an excerpt with explanations for each option:\n\n```toml\nbaseURL = 'https://example.org/'\nlanguageCode = 'en-us'\ntitle = 'The LLVM Compiler Infrastructure'\n\n[markup.goldmark.renderer] \n  unsafe= true\n\n# Navigation Bar Menu\n[[menus.main]]\nname = 'Getting Started'\npageRef = '/'\nweight = 10\n\n[[menus.main]]\nname = 'Docs'\npageRef = '/docs'\nweight = 20\n\n[[menus.main]]\nname = 'Blogs'\npageRef = '/blogs'\nweight = 30\n\n[[menus.main]]\nname = 'Resources'\npageRef = '/resources'\nweight = 40\n\n[[menus.main]]\nname = 'Doxygen '\npageRef = '/'\nweight = 1\nparent = 'Resources'\n\n[[menus.main]]\nname = 'GitHub'\npageRef = '/'\nweight = 2\nparent = 'Resources'\n\n[[menus.main]]\nname = 'Code Review'\npageRef = '/'\nweight = 3\nparent = 'Resources'\n\n[[menus.main]]\nname = 'Downloads'\npageRef = '/downloads'\nweight = 50\n\n[module]\n  [module.hugoVersion]\n    extended = false\n    min = \"0.116.0\"\n\n\n# Hero section links\n\n[params]\n  logo = \"images/logo.png\"\n  navbar_logo = \"images/logo.png\"\n  subtitle = 'The LLVM Project is a collection of modular and reusable compiler and toolchain technologies. Despite its name, LLVM has little to do with traditional virtual machines. The name \"LLVM\" itself is not an acronym; it is the full name of the project.  '\n  no_robots = true\n\n  [params.banner]\n    visible = false\n    description = \"Feedback for this website\"\n    [[params.banner.buttons]]\n      text = \"Feedback Form\"\n      url = \"https://docs.google.com/forms/d/1irmZ1vSHtYUqTFQIUqBxl2rjbW4mpaRdzrpBxsqxrsE/\"\n    [[params.banner.buttons]]\n      text = \"Old Website\"\n      url = \"https://llvm.org\"\n\n\n  [[params.hero_section_buttons]]\n    title = \"Get Started\"\n    url = \"/get-started\"\n    type = \"primary\"\n  [[params.hero_section_buttons]]\n    title = \"Releases\"\n    url = \"https://releases.llvm.org\"\n    type = \"secondary\"\n\n  # only first 4 links will be displayed\n  [[params.hero_section_links]]\n    title = \"Latest Release\"\n    icon = \"ri-hashtag\"\n    url = \"/\"\n  [[params.hero_section_links]]\n    title = \"Upcoming Events\"\n    icon = \"ri-play-large-line\"\n    url = \"#upcoming_events\"\n  [[params.hero_section_links]]\n    title = \"Read the Docs\"\n    icon = \"ri-book-open-line\"\n    url = \"/\"\n  [[params.hero_section_links]]\n    title = \"Explore subprojects\"\n    icon = \"ri-projector-line\"\n    url = \"/\"\n\n# Table of contents config\n\n[markup]\n  [markup.tableOfContents]\n    startLevel = 2\n    endLevel = 4\n\n# Footer config\n\n[params.footer]\ntitle = \"The LLVM Compiler Infrastructure\"\n\n[[params.footer.columns]]\ntitle = \"LLVM\"\nlinks = [\n  { text = \"Features\", url = \"#\" },\n  { text = \"Documentation\", url = \"#\" },\n  { text = \"Blog\", url = \"#\" },\n  { text = \"FAQ\", url = \"#\" },\n  { text = \"Resources\", url = \"#\" },\n  { text = \"Download\", url = \"#\" }\n]\n\n[[params.footer.columns]]\ntitle = \"Dev. Resources\"\nlinks = [\n  { text = \"Doxygen\", url = \"#\" },\n  { text = \"Sources (GitHub)\", url = \"#\" },\n  { text = \"Code Review\", url = \"#\" },\n  { text = \"Bug Tracker\", url = \"#\" },\n  { text = \"Green Dragon\", url = \"#\" },\n  { text = \"LNT\", url = \"#\" },\n  { text = \"Scan Build\", url = \"#\" },\n  { text = \"llvm-cov\", url = \"#\" },\n  { text = \"Compile-time tracker\", url = \"#\" }\n]\n\n[[params.footer.columns]]\ntitle = \"About LLVM\"\nlinks = [\n  { text = \"Mission\", url = \"#\" },\n  { text = \"Community\", url = \"#\" },\n  { text = \"Events\", url = \"#\" },\n  { text = \"Sponsors\", url = \"#\" },\n  { text = \"Contact\", url = \"#\" }\n]\n\n\n```\n\n### Configuration Options\n\n- `baseURL`: The base URL for the site.\n- `languageCode`: The language code for the site.\n- `title`: The title of the site.\n- `markup.goldmark.renderer.unsafe`: Enable unsafe HTML in markdown.\n- `menus.main`: The main menu items for the site.\n- `params.logo`: The logo for the site.\n- `params.navbar_logo`: The logo for the navbar.\n- `params.subtitle`: The subtitle for the site.\n- `params.banner`: The banner configuration.\n  - `visible`: true or false, whether the banner is visible.\n  - `description`: The description for the banner.\n  - `parqams.banner.buttons`:\n    - `text`: The text for the button in the banner.\n    - `url`: The URL for the button in the banner.\n- `params.hero_section_buttons`: The buttons displayed in the hero section.\n  - `title`: The title of the button.\n  - `url`: The URL for the button.\n  - `type`: The type of the button (primary or secondary).\n- `params.hero_section_links`: The links displayed in the hero section.\n  - `title`: The title of the link.\n  - `icon`: The icon for the link.\n  - `url`: The URL for the link.\n- `markup.tableOfContents`: The table of contents configuration.\n  - `startLevel`: The starting level for the table of contents.\n  - `endLevel`: The ending level for the table of contents.\n- `params.footer`: The footer configuration.\n  - `title`: The title of the footer.\n  - `columns`: The columns in the footer.\n    - `title`: The title of the column.\n    - `links`: The links in the column.\n      - `text`: The text of the link.\n      - `url`: The URL of the link.\n\n\n## Creating New Website\n\nTo create a new website using the theme, follow these steps:\n\n1. Create a new Hugo site:\n   ```sh\n   hugo new site my-site\n   ```\n\n2. Change into the new site directory:\n   ```sh\n    cd my-site\n    ```\n\n3. Clone the theme into the `themes` directory:\n    ```sh\n    git clone\n    ```\n4. Install Post CSS CLI\n    ```sh\n    npm install postcss-cli\n    ```\n5. Update the `config.toml` file to use the theme:\n    ```toml\n    theme = \"www-template\"\n    ```\n6. Run the site locally:\n    ```sh\n    hugo server\n    ```\n7. Open the site in your browser:\n    ```\n    http://localhost:1313\n    ```\n8. Customize the site by updating the configuration options in the `config.toml` file.\n\n\n## Creating New Pages\n\nTo create new pages, use the following command:\n\n```sh\nhugo new \u003cpage-name\u003e/_index.md\n```\n\nFor example, to create a new page named `about`, run the following command:\n\n```sh\nhugo new about/_index.md\n```\n\nFront matter for the new page will be created automatically. Update the front matter with the desired content e.g.:\n\n```markdown\n---\ntitle: Sample Page\ndescription: Markdown tutorial and syntax examples for common elements.\ndate: 2023-01-15T09:00:00-07:00\ndraft: false\ntags: [\"markdown\"]\ntoc: true\n---\n```\n\nYou can find and example page in the `content/sample-page/_index.md` file.\n\n## Using YAML Data Files\n\nThe theme supports YAML data files for defining content. To use YAML data files,\ncreate a new file in the `data` directory, refer to the other data files for the\nstructure.\n\nThen use the `datamap.html` shortcode.\n\n### Usage of `datamap.html` Shortcode\n\n```markdown\n{{\u003c datamap \n    \"data_file_name\" \"data_array\" \n    \"title\" \n    \"description\" \n    \"expected_result\" \n\u003e}}\n```\n\n- `data_file_name`: The name of the data file.\n- `data_array`: The name of the array in the data file.\n- `title`: The title of the data item.\n- other fields: The fields of the data item.\n\n\n## Creating New Shortcodes (using YAML Data Files)\n\nCreate a new shortcode (e.g. `new_short_code.html`) in the `layouts/shortcodes` directory. In the shortcode file, use the `datamap.html` shortcode to display the data. \n\nIt is a `HTML` file, so you can use `HTML` tags to style the data.\n\nMore on shortcodes can be found in the HUGO docs [here](https://gohugo.io/templates/shortcode/).\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fllvm%2Fwww-template","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fllvm%2Fwww-template","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fllvm%2Fwww-template/lists"}