Code4Newark / codefornewark.org

New Jekyll site for Code for Newark based on Open Savannah brigade site
https://codefornewark.org
MIT License
1 stars 8 forks source link

codefornewark.org

Code for Newark is a platform for civic innovation. As an open source organization, you can fork our code including our website. Help us make the site better by forking it, adding new content or features, and submitting a pull request!

Note: This site is hosted with GitHub pages and, as such, any changes you make to the repository will immediately be reflected on codefornewark.org.

Updating content

Most minor content updates can be made simply by making changes on your forked copy of this repository, then submitting a pull request. For example, following every event, the file _layouts/home/cta.html should always be updated to reflect the date of the next event.

Note: If you have admin privileges to this GH org, you may committ your updates directly to the repository without forking your own copy, but do so with vigilance.

Updating Call-to-Action for upcoming events

The CTA block just below the hero image can be quickly updated fairly easily:

  1. Fork this repository to your own account if you haven't already.
  2. Navigate to the file _includes/home/cta.html
  3. Edit the file on your forked copy of the repository to reflect the updated text that needs to appear in the Call-to-Action.
  4. Commit your changes.
  5. Come back to this repository, select Pull Requests and issue a Pull Request to merge your changes into the main repository.
  6. The changes then should automatically appear on the site in a few minutes!

Finding pages to update -- structure of site

Everything starts with index.md at the root level of the project structure. The layout of the home page (and other pages) is pulled in from the _layouts folder, and content is pulled in from _includes with {% include <file-to-include> %} statements. More information about how this works can be found in the Jekyll documentation.

Some more tips for exploring the layout of the website:

MORE TK


Local Development

If you want to make significant changes to the site, it's recommended you do so on your local machine first so as to speed up the development process. Here's how to do that.

Requirements

Installation

Notes: https://help.github.com/articles/setting-up-your-github-pages-site-locally-with-jekyll/

Clone the Repository

git clone https://github.com/code4newark/codefornewark.org.git

Install Dependencies

bundle

If it asks for your password, there should be a message recommending to instead run

bundle install --path vendor/bundle

Do that instead.

Build the Pages

jekyll build

or if you did the bundle install command with the path option

bundle exec jekyll build

Serve the Pages

jekyll serve --watch

Or if you did the bundle install command with the path option

bundle exec jekyll serve --watch

Hack Away

With jekyll serve --watch running, you should be able to access the site on http://localhost:4000! Thanks to the --watch flag, any changes you make to the markdown (md) files will update automatically!

For reference, here's an awesome markdown cheatsheet.

Contribute, change things, submit a pull request! We will all contribute.