GithubHelp home page GithubHelp logo

isabella232 / grass-website Goto Github PK

View Code? Open in Web Editor NEW

This project forked from osgeo/grass-website

0.0 0.0 0.0 230 MB

Web site of GRASS GIS project (deployed from this repo twice a day)

Home Page: https://grass.osgeo.org/

License: GNU General Public License v3.0

JavaScript 1.66% CSS 50.89% TeX 4.41% HTML 43.04%

grass-website's Introduction

Hugo theme for GRASS GIS website

This repository contains the code of the upcoming Web site of the GRASS GIS project. It is deployed every 15 min at: https://grass.osgeo.org/

Mailing list for discussions: https://lists.osgeo.org/mailman/listinfo/grass-web

Below some instructions how to contribute by running a local instance for testing prior to commit changes as pull requests.

How to build your own local web server

git clone https://github.com/OSGeo/grass-website.git

Install Hugo

apt-get update

apt install hugo

Build pages locally

cd grass-website

hugo

Output HTML generated in the /public directory at the root of the grass-website directory

Run server locally

Run hugo development server from the grass-website root directory:

cd grass-website

hugo server

View the website running at http://localhost:1313

How to add content

Content must be created in .md files using markdown syntax. HTML markup can also be mixed with markdown for more advanced content presentation.

Useful resources:

Add a news item

  • Head to the news directory cd /grass-website/content/news

  • Create new md file sudo nano mynewsitem.md

  • Add the basic header information for Hugo, at least title, date, layout

  • Write content in mardown bellow

  • Rebuild if needed

    cd ../../
    
    hugo
    
  • Check result at http://localhost:1313/news/

Create a new content page

  • Head to a content subdirectory, for example the one used for the About section cd /grass-website/content/about

  • Create a new md file using the basic hugo header and markdown syntax (more info coming soon)

  • Create a specific template if advance page presentation is needed (see /themes/grass/layouts/) (more info coming soon)

  • Edit config.toml and add the new page as a new menu item as a children of the About section, as follows

        [[Languages.en.menu.main]]
        parent = "About"
        name = "My new page"
        URL = "/about/mypage"
        weight = 1
    
  • Rebuild if needed

    cd ../../
    
    hugo
    
  • Check result at http://localhost:1313/about/mypage

Mind SEO

Search engine optimization works like this:

If the md file used for generating the page has a summary, its value is used as page meta description, otherwise the general description defined in config.toml is used by default.

Add new event

  • Head to the news directory cd /grass-website/content/events

  • Create new md file sudo nano EVENT_NAME.md

  • Use the following header information template for Hugo

    title: "CONFERENCE NAME" event: start: START-DATE end: END-DATE where: CITY website: URL layout: "event" logo: images/conferences_logos/YOUR_LOGO.png

  • Add your logo to /grass-website/images/conferences_logos folder

  • Rebuild if needed

    cd ../../
    
    hugo
    
  • Check result at http://localhost:1313/news/ in the Next Events section in the right sidebar. Your event will show up only if it is one in the top three from today.

Submit your changes

Like it? Then please submit your improvements as a new pull request.

grass-website's People

Contributors

neteler avatar veroandreo avatar lucadelu avatar mlennert avatar ninsbl avatar landam avatar nbozon avatar carlosgrohmann avatar wenzeslaus avatar ecodiv avatar hellik avatar baharmon avatar florisvdh avatar echoix avatar huidaecho avatar isaacullah avatar jef-n avatar cmbarton avatar nilason avatar smathermather avatar kikislater avatar tmszi avatar larafaelivrin avatar

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.