Plugin per Jekill che recupera gli eventi in arrivo per una lista di gruppi in una data istanza di mobilizon. Anche le immagini sono recuperate e miniaturizzate. Puoi visualizzare tutti gli eventi del gruppo e tutti gli eventi con un tag https://mobilizon.it
Go to file
Marc-AntoineA f785b1bf42 Fix bug with long mobilizon image names. 2021-03-21 14:57:04 +01:00
mobilizon-agenda.rb Fix bug with long mobilizon image names. 2021-03-21 14:57:04 +01:00
readme.md Initial commit. 2021-02-20 00:31:13 +01:00

readme.md

Script to include Mobilizon into Jekyll-website

This plugin fetches incoming events for a list of groups in a given mobilizon instance (through graphql api). Images are fetched too and thumbnailed with minimagick. It means that no requests are made to mobilizon except during website compilations.

You can create many agendas based on groups and tags through the mobilizonAgenda Jekyll-tag

Example You want to display all events from group my-group and all events with tag my-tag and all events with tag my_awesome_tag :

{% assign options="my-group,my_tag,my_awesome_tag" %}
{% mobilizonAgenda options %}

{% if forloop.length == 0 %}
<p>We did not find any event.</p>
{% else %}
{% include event.html
	title=event.title
	location=event.location
	start_time=event.beginsOn
	end_time=event.endsOn
	description=event.description
	url=event.url
	thumbnail=event.thumbnailurl
	organizerAvatar=event.organizerAvatar
	organizer=event.organizer
	groupUrl=event.groupUrl
	%}
{% endif %}
{% endmobilizonAgenda %}

How to use it?

Add these lines into your _config.yml

mobilizon_fetch: true # false if you want to deactivate it
mobilizon_url: "https://mobilizon.fr"
mobilizon_cachedir: "mobilizon" # the name of the local folder used to cache the results
mobilizon_timezone: "Europe/Paris" # used to convert the dates
mobilizon_whitelist: # list of the mobilizon groups you want to display on your website
  - my_group
  - my_second_group

Add mobilizon-agenda.rb into your _plugins folder.