A Jekyll plugin, brings in data from your Attendease event and allows you to use it in your Jekyll templates for awesome event websites.
Add this line to your application's Gemfile:
gem 'jekyll-attendease'
And then execute:
$ bundle
Or install it yourself as:
$ gem install jekyll-attendease
Next, make sure to require it. Add the following file _plugins/attendease.rb and content:
require "jekyll-attendease"You will need to configure by editing your _config.yml:
#
# Plugin: jekyll-attendease
#
attendease:
# Required
api_host: https://your-event-subdomain.attendease.com/| Key | Default | Description |
|---|---|---|
| base_layout | layout | When generating pages this will be the base layout for your html |
| base_email_layout | When generating an email template this will be the base layout for your html | |
| access_token | none | Your top-secret API access token |
| cache_expiry | 3600 | The number of seconds until we regerenate the data from the api. Otherwise data will be cached for speed. |
| generate_schedule_pages | false | Set to true if you want to generate static schedule pages. |
| show_day_index | false | Set to true if you want an index of days |
| schedule_path_name | schedule | Folder off of the root to put the schedule pages. Setting to blank will disable schedule page generation. |
| presenters_path_name | presenters | Folder off of the root to put the presenters page. Setting to blank will disable presenter page generation. |
| venues_path_name | venues | Folder off of the root to put the venues page. Setting to blank will disable venue page generation. |
| sponsors_path_name | sponsors | Folder off of the root to put the sponsors page. Setting to blank will disable sponsor page generation. |
| schedule_sessions_title | Schedule: Sessions | Override to set the page.title of the sessions listing page |
| schedule_session_page_title | Schedule: %s | %s will be substituted with the session's name |
| presenters_index_title | Presenters | Override to set the page.title of the presenters listing page |
| presenter_page_title | Presenter: %s | %s will be substituted with the session's name |
| venues_index_title | Venues | Override to set the page.title property of the Venues index page |
| venue_page_title | Venue: %s | %s will be substituted with venue's name. Override to set the page.title property of the individual Venue page |
Remember to replace https://your-event-subdomain.attendease.com/ with your actual event url, or crazy things will happen!
Now the event name can easily be used in your site like so:
{{ site.attendease.data.event_name }}
We can also use logical expressions like so:
{% if site.attendease.data.has_registration %}
We have registration!
{% endif %}
Simply add the auth script tag and the auth action and account tags and our system will know if you logged in or out and will be able to link to your account!
The script tag sets up an AJAX callback to the server to determine if we are online or offline.
{% attendease_auth_script %}
This is simple a div with the id attendease-auth-account, maybe more in the future. When used with the attendease_auth_script tag it will populate with the link to the account of the attendee.
{% attendease_auth_account %}
This is simple a div with the id attendease-auth-action, maybe more in the future. When used with the attendease_auth_script tag it will populate with a login or logout action.
{% attendease_auth_action %}
This script tag sets up AJAX actions for scheduling sessions.
{% attendease_scheduler_script %}
This script tag sets up lingo so your event can sound like you want it to sound like.
{% attendease_locales_script %}
A quick way to use our lingo stuff in our jekyll templates.
{% t %}
In your site's Javascript, do something like this:
JekyllAttendease.onLoginCheck(function(e)
{
if (e.data.loggedin)
{
// do some cool stuff!
var account = e.data.account;
// console.log(account);
}
// And we have some URLs for you!
// e.data.loginURL
// e.data.logoutURL
// e.data.accountURL
});In your _config.yml if you add the generate_schedule_pages set to true under attendease it will generate static schedule pages from the Attendease public API.
You can customize the look/structure of each page as well as widgets within the pages. These pages will be automatically generated for you when you build your site.
For Session Day pages:
_layouts/attendease_schedule_day_sessions.html- The layout for the generate session day page. It will list all instances on that day_includes/attendease/session_instance_item.html- The instance item on the page_includes/attendease/filter.html- A filter and its items in the instance_includes/attendease/presenter_item.html- A presenter item in the instance
- Make sure the specs pass!
bundle exec rake spec - Add new specs if you've added new functionality.
- Start with a pre-release version. Adding non-numeric characters achieves
this. (e.g. 0.6.9.pre in
lib/jekyll/attendease_plugin/version.rb) - Update the gem's release date in
jekyll-attendease.gemspec gem build jekyll-attendease.gemspecgem push jekyll-attendease-0.6.9.pre.gem- Update Attendease respectively to test.
- Bump the version
- Tag the release
- Build and push the gem
- Push the tags to the upstream
- Fork it
- Create your feature branch (
git checkout -b my-new-feature) - Commit your changes (
git commit -am 'Added some feature') - Push to the branch (
git push origin my-new-feature) - Create new Pull Request
- log into the jail via the jail's console.
- gem install jekyll-attendease -v x.x.x
During development, you can create and install local builds:
gem build jekyll-attendease.gemspec
And then install it:
gem install jekyll-attendease-`cat jekyll-attendease.gemspec|grep s.version|awk '{print $3}'|sed s/\'//g`.gem
Copyright (C) 2013 Attendease (https://attendease.com/)
The MIT License
Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the "Software"), to deal in the Software without restriction, including without limitation the rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, and to permit persons to whom the Software is furnished to do so, subject to the following conditions:
The above copyright notice and this permission notice shall be included in all copies or substantial portions of the Software.
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.