Skip to content
This repository was archived by the owner on Jan 10, 2020. It is now read-only.
Open
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
76 commits
Select commit Hold shift + click to select a range
f407b5f
nextgen jekyll
Nov 10, 2016
c394b97
adding gitignore
Nov 10, 2016
f6502a6
removing unneeded files
Nov 10, 2016
c40bf3d
removing dsstore
Nov 10, 2016
eadd621
Delete .DS_Store
Nov 10, 2016
5195b84
Delete .DS_Store
Nov 10, 2016
cb20400
Delete .DS_Store
Nov 10, 2016
7ed88c1
fixing some js errors, fixing some styling
Nov 11, 2016
2f569a7
Merge branch 'nextgen2' of https://github.com/IFRCGo/IFRCGo.github.io…
Nov 11, 2016
5ed9c91
dependecy upgrades, working appeal importer, new humans.txt template
Nov 22, 2016
d8a538e
adding travis support
Nov 22, 2016
4fc6667
dep minor update
Nov 22, 2016
06aab15
added basic css for appeals pages, stubing out layouts, travis, clean…
Nov 22, 2016
7b9634e
adding stream-replace dependency
Nov 22, 2016
cc6ff2c
Added to the README.md, fixed the isotope filtering and changed some …
kathicks Nov 24, 2016
423c6ff
Changed the title and sub-title
kathicks Nov 24, 2016
e30b4b5
Reformatted isotope buttons
kathicks Nov 25, 2016
b93d218
Reformatted boxes
kathicks Nov 25, 2016
34af715
Added new banner image
kathicks Nov 25, 2016
49e5460
Attempted to fix broken links
kathicks Nov 25, 2016
f2569dd
Merge branch 'nextgen2' of https://github.com/KatHicks/IFRCGo.github.…
kathicks Nov 25, 2016
b619a90
Create jekyll-pages-directory.rb
kathicks Nov 25, 2016
86a2ca2
Continuting with restyling
kathicks Nov 25, 2016
a1eb3c3
Merge branch 'nextgen2' of https://github.com/KatHicks/IFRCGo.github.…
kathicks Nov 25, 2016
0486579
Added first grid image
kathicks Nov 25, 2016
edd14b4
Added images for grid items
kathicks Nov 25, 2016
ca827f3
Adding further images
kathicks Nov 25, 2016
70d539e
Moved Cloud9 instructions to new README.md
kathicks Dec 1, 2016
e66a217
Made changes related to specific pull request comments.
kathicks Dec 1, 2016
d9b15a1
Merge pull request #5 from KatHicks/nextgen2
Dec 2, 2016
595b225
typo
Dec 2, 2016
ab2ab6a
using bower to install js dependencies
Dec 4, 2016
865bf32
setting different default folder for bower components, allows for gul…
Dec 4, 2016
8863fd8
removing bower..for now
Dec 5, 2016
84e8928
removing grid graphics
Dec 5, 2016
fcb6af6
refactor index page
Dec 5, 2016
c0cf4f5
index refactor
Dec 5, 2016
e913cb6
finishing refactor for newhomepage
Dec 5, 2016
c04278e
comment
Dec 6, 2016
270d753
allow offline builds to not fail
Dec 10, 2016
a3d476b
adding old simon pages
Dec 10, 2016
1775985
adding vendor js, should eventually replace with bower_components
Dec 10, 2016
e06430d
begining jekyllization
Dec 10, 2016
d5e37a2
sorta working bower + other improvements
Jan 19, 2017
7505891
new homepage
Jan 31, 2017
5eca41a
upgrading foundation to 6.3, switched to card interface for core data…
Jan 31, 2017
c46aa78
making cards the default on the landing page
Jan 31, 2017
0d7f67c
removing unneeded leaflet basemap
Jan 31, 2017
8302af9
adding bower to npm install
Jan 31, 2017
17ace30
updating js route
Jan 31, 2017
55ffd58
updating npm dependencies
Jan 31, 2017
c0b983f
fixing node version issue with travis
Jan 31, 2017
b2c9b58
adding bluebird
Jan 31, 2017
4c5dd62
switching back to latest node version
Jan 31, 2017
fa91525
adding bower
Jan 31, 2017
3b78e0d
updating install procedure
Feb 1, 2017
f591128
fixing compass + sass
Feb 1, 2017
d8c9f62
adding hover effect for regions
Feb 1, 2017
6737aa6
adding labs section, changing header
Feb 1, 2017
bb0fbeb
fixed header
Feb 1, 2017
a54b8d4
fixing deps
Feb 1, 2017
120f8bd
moving foundation
Feb 1, 2017
074be07
foundation settings change
Feb 1, 2017
6288cf6
color fixes
Feb 1, 2017
9006de4
removing giant red scroll bar
Feb 1, 2017
fd7d459
minor css and html tweaks
Feb 1, 2017
69a375f
adding custom files
Feb 1, 2017
3b7b4e6
adding nav links
Feb 1, 2017
e9f0661
working subpages
Feb 2, 2017
23781fb
various minor edits
guipizzini Feb 2, 2017
bfecbfb
text edits
guipizzini Feb 2, 2017
5b898c6
working pages
Feb 2, 2017
6d93bd2
disable default
humanitariandata Feb 2, 2017
94d968b
fixing windows gulp bug
Feb 3, 2017
5c21b48
landing page changes
Feb 3, 2017
b678222
merging changes
Feb 3, 2017
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
The table of contents is too big for display.
Diff view
Diff view
  •  
  •  
  •  
3 changes: 3 additions & 0 deletions .bowerrc
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
{
"directory": "app/assets/scripts/vendor"
}
16 changes: 16 additions & 0 deletions .build_scripts/deploy.sh
Original file line number Diff line number Diff line change
@@ -0,0 +1,16 @@
#!/usr/bin/env bash
set -e # halt script on error

# If this is the deploy branch, push it up to gh-pages
if [ $TRAVIS_PULL_REQUEST = "false" ] && [ $TRAVIS_BRANCH = ${DEPLOY_BRANCH} ]; then
echo "Get ready, we're pushing to gh-pages!"
cd _site
git init
git config user.name "Travis-CI"
git config user.email "travis@somewhere.com"
git add .
git commit -m "CI deploy to gh-pages"
git push --force --quiet "https://${GH_TOKEN}@${GH_REF}" master:master
else
echo "Not a publishable branch so we're all done here"
fi
8 changes: 8 additions & 0 deletions .build_scripts/lint.sh
Original file line number Diff line number Diff line change
@@ -0,0 +1,8 @@
#!/usr/bin/env bash
set -e # halt script on error
# If deploying, don't balk on lint errors
if [ $TRAVIS_PULL_REQUEST = "false" ] && [ $TRAVIS_BRANCH = ${DEPLOY_BRANCH} ]; then
npm run lint || true
else
npm run lint
fi
21 changes: 21 additions & 0 deletions .gitignore
Original file line number Diff line number Diff line change
@@ -0,0 +1,21 @@
# System files
.project
.DS_Store
.sass-cache
.bundle
bundle

# Local
node_modules
_site
.tmp
_config-dev.yml
npm-debug.log
app/assets/scripts/config/local.js
app/assets/scripts/vendor/
app/_data/temp
appealsplus.json

#Foundation additions
.sass-cache
config
28 changes: 28 additions & 0 deletions .travis.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,28 @@
language: node_js
node_js:
- "6.1"

language: ruby
rvm:
- 2.3.1

env:
global:
- GH_REF=github.com/IFRCGo/ifrc.github.io
- DEPLOY_BRANCH=publish

cache:
directories:
- node_modules

before_install:
- chmod +x ./.build_scripts/deploy.sh

before_script:
- npm install -g bower
- npm install
- bower install
script: gulp prod

after_success:
- ./.build_scripts/deploy.sh
9 changes: 9 additions & 0 deletions Gemfile
Original file line number Diff line number Diff line change
@@ -0,0 +1,9 @@

source 'https://rubygems.org'

gem 'jekyll'
gem 'sass'
gem 'compass'
gem 'sass-css-importer'
gem "i18n", "0.7.0"
gem 'jekyll-feed'
71 changes: 71 additions & 0 deletions Gemfile.lock
Original file line number Diff line number Diff line change
@@ -0,0 +1,71 @@
GEM
remote: https://rubygems.org/
specs:
addressable (2.5.0)
public_suffix (~> 2.0, >= 2.0.2)
chunky_png (1.3.8)
colorator (1.1.0)
compass (1.0.3)
chunky_png (~> 1.2)
compass-core (~> 1.0.2)
compass-import-once (~> 1.0.5)
rb-fsevent (>= 0.9.3)
rb-inotify (>= 0.9)
sass (>= 3.3.13, < 3.5)
compass-core (1.0.3)
multi_json (~> 1.0)
sass (>= 3.3.0, < 3.5)
compass-import-once (1.0.5)
sass (>= 3.2, < 3.5)
ffi (1.9.14)
forwardable-extended (2.6.0)
i18n (0.7.0)
jekyll (3.3.1)
addressable (~> 2.4)
colorator (~> 1.0)
jekyll-sass-converter (~> 1.0)
jekyll-watch (~> 1.1)
kramdown (~> 1.3)
liquid (~> 3.0)
mercenary (~> 0.3.3)
pathutil (~> 0.9)
rouge (~> 1.7)
safe_yaml (~> 1.0)
jekyll-feed (0.8.0)
jekyll (~> 3.3)
jekyll-sass-converter (1.5.0)
sass (~> 3.4)
jekyll-watch (1.5.0)
listen (~> 3.0, < 3.1)
kramdown (1.13.0)
liquid (3.0.6)
listen (3.0.8)
rb-fsevent (~> 0.9, >= 0.9.4)
rb-inotify (~> 0.9, >= 0.9.7)
mercenary (0.3.6)
multi_json (1.12.1)
pathutil (0.14.0)
forwardable-extended (~> 2.6)
public_suffix (2.0.4)
rb-fsevent (0.9.8)
rb-inotify (0.9.7)
ffi (>= 0.5.0)
rouge (1.11.1)
safe_yaml (1.0.4)
sass (3.4.22)
sass-css-importer (1.0.0.beta.0)
sass (>= 3.1)

PLATFORMS
ruby

DEPENDENCIES
compass
i18n (= 0.7.0)
jekyll
jekyll-feed
sass
sass-css-importer

BUNDLED WITH
1.13.6
87 changes: 87 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,87 @@
## [IFRC GO LABS](http://ifrcgo.github.io)

### Adding Language support

The site is configured to support 2-letter core language codes. So english is 'en' not 'en-US' and/or 'en-GB'. Using a longer code will not function.

There are four main steps in incorporating a language:

1. tell app config the language exists
1. add 2-letter language code to ```authorized_locales``` array in \_config.yml
2. include locale file (to support date/time localization)
1. several already in place (in \_locales dir), otherwise get from [here](https://github.com/svenfuchs/rails-i18n/tree/master/rails/locale)
3. include \_data/```2-letter code```.yml to support site content translations
1. copy \_data/en.yml, then update text values
2. note that the url for the nav items can be updates for your language. this needs to align with the permalink in the page frontmatter (see item 4.2 below)
4. create folder of page templates
1. copy 'en' dir, rename copy as your 2-letter language code
2. in frontmatter for all templates there within, you need to add the language code and pagename to the ```permalink``` (i.e. /about/ becomes /fr/apropos/ for the french translation)
5. create folder of blog posts
1. copy the \_posts/en dir, rename folder as your 2-letter language code
2. in frontmatter for all templates there within, you need to change the ```language``` to the correct code and add the language code to the ```permalink``` (i.e. /blog/:year/:month/:day/:title/ becomes /fr/blog/:year/:month/:day/:title/ for the french translation)
6. (OPTIONAL) Add translations of pdf assets
1. add documents to assets/downloads
2. update \_data/```2-letter code```.yml host.materials_list.asset(s) with the filename you created

## Development

### Environment
To set up the development environment for this website, you'll need to install the following on your system:

- [Node and npm](http://nodejs.org/)
- Ruby and [Bundler](http://bundler.io/), preferably through something like [rvm](https://rvm.io/)
- Gulp ( $ npm install -g gulp )

After these basic requirements are met, run the following commands in the website's folder:

##### Command #1

```
$ npm install
```

##### Command #2: Installing Bundler

```
$ bundle install
```

##### Command #3: Installing Bundler

```
$ bower install
```

### Getting started

```
$ gulp serve
```
Compiles the compass files, javascript, and launches the server making the site available at `http://localhost:3000/`
The system will watch files and execute tasks whenever one of them changes.
The site will automatically refresh since it is bundled with livereload.

The `_config-dev.yml` file will be loaded alongside `_config.yml`.


### Other commands
Clean the compiled site. I.e. the `_site` folder
```
$ gulp clean
```

Compile the compass files, javascripts, and builds the jekyll site using `_config-dev.yml`.
Use this instead of ```gulp serve``` if you don't want to watch.
```
$ gulp
```

Compiles the site loading the `_config-stage.yml` alongside `_config.yml`. The javascript files will be minified.
```
$ gulp stage
```

Compiles the site loading the `_config-prod.yml` alongside `_config.yml`. The javascript files will be minified.
```
$ gulp prod
```
29 changes: 29 additions & 0 deletions USING_CLOUD9.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,29 @@
##### Running on Cloud9 IDE:

You need to change the IP and port for it to run on a cloud IDE: <https://docs.c9.io/docs/run-an-application>.
> If you're developing a server application, please note that you need to listen to 0.0.0.0 ($IP) and 8080 ($PORT).

Follow these instructions to change the port and IP for gulp serve: <https://github.com/Swiip/generator-gulp-angular/issues/848>

###### Step #1
Changed the port in the gulpfile.js on line 107 as follows:
```
gulp.task('serve', ['build'], function () {
browserSync({
port: 8080,
server: {
baseDir: ['.tmp', '_site']
}
});
```
###### Step #2
Click on the local host link in the terminal
```
[16:58:31] Finished 'serve' after 246 ms
[BS] Access URLs:
-------------------------------------
Local: http://localhost:8080
External: http://172.17.0.154:8080
-------------------------------------
```
You will need to open it in a new tab to view.
2 changes: 2 additions & 0 deletions _config-dev.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,2 @@
domain: http://localhost:3000
path_prefix:
35 changes: 35 additions & 0 deletions _config.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,35 @@
# Site settings
title: Go Project Lab
safe: false
source: app
exclude:
- assets/scripts
- assets/vendor
- assets/styles
- README.md
timezone: America/New_York
highlighter: false

baseurl: ""

permalink: pretty

collections:
events:
output: true

# locale settings
default_locale: "en"
authorized_locales: ["en"]

# add support for an atom feed
gems:
- jekyll-feed

#page generator for appeals
# page_gen-dirs: true
page_gen:
- data: 'appealsplus'
template: 'build/appeals'
name: 'meta_id'
dir: 'appeals'
41 changes: 41 additions & 0 deletions app/_data/en.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,41 @@
#####################
## NAV CONTENT ##
#####################
nav:
home: "Home"
coredatasets: "Core Datasets"
ifrcregions: "IFRC Regions"
about: "About"
ifrclink: "IFRC.org"
fednet: "FedNet"
dmis: "DMIS"

#####################
## LANDING CONTENT ##
#####################
landing:
title: "Go Project Lab"
tagline: "Go to the data"
welcome: "Welcome to the IFRC Go Project Website"

####################
## Appeals CONTENT ##
####################
appeals:
title: "Appeals"
description: "Below is a directory of the current appeal pages and appeal plus pages. Appeal plus pages have extra information provided by those working in the operation such as key figures, contacts and useful links. If you want an appeal page upgraded to an appeal plus page please contact <a href=\"mailto:ifrcgoproject@gmail.com\">ifrcgoproject@gmail.com</a> with the request."
plus: "Current Appeal Plus pages"
normal: "All Appeal Pages"

###################
## ABOUT CONTENT ##
###################
about:
title: "About"

#####################
## 404 ##
#####################
lost:
title: "This page is missing."
message: "This is kind of embarrasing. You seem to be somewhere that we haven't visualized the data yet."
1 change: 1 addition & 0 deletions app/_data/map/worldcountries.json

Large diffs are not rendered by default.

35 changes: 35 additions & 0 deletions app/_includes/404.html
Original file line number Diff line number Diff line change
@@ -0,0 +1,35 @@
<script>
document.querySelector("header").style.display = 'inline-block';
</script>

<div id="site-canvas">
<div class="header-image header-404">
<div class="dark-overlay center-text">
<h1 class="title feature-header">{{site.data[locale].lost.title}}</h1>
</div>
</div>
<div class="row">
<div class="large-12 columns">
<div class="about-container">
<div class="about-textbox">
<h3 style="text-align: center">{{site.data[locale].lost.message}}</h3>
<br />
<h3 style="text-align: center"><a href="{{site.data[locale].nav.url[0]}}">{{site.data[locale].lost.link}}</h3>
</div>
</div>
</div>
</div>
<div class="row contribute-options">
<div class="large-12, large-centered" style="text-align: center">
<a href="http://tasks.hotosm.org/?sort_by=priority&direction=asc&search=missing+maps">
<img src="{{ site.baseurl }}/assets/graphics/content/process/Learn-MapNow.svg"></img>
<p>
<div class="btn btn-grn arw">{{site.data[locale].contribute.map_btn}}
<img src="{{ site.baseurl }}/assets/graphics/meta/Arrow.svg"></img>
</a>
</div>
</div>

</div>
</div>
</div>
Loading