Skip to content

Commit

Permalink
feat: extra image overrides
Browse files Browse the repository at this point in the history
  • Loading branch information
mavi0 committed Oct 8, 2023
1 parent 3ec4016 commit 072f103
Show file tree
Hide file tree
Showing 4 changed files with 25 additions and 2 deletions.
18 changes: 17 additions & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -23,7 +23,7 @@ If you're submitting an effect, please make sure it follows these rules:
For obvious reasons, PRs containing effects that violate these restrictions will
be rejected.

# Current effects
## Current effects

| Author | Effect | Description |
| ---------------------------------------------------------- | ----------------------------------------------------------------------- | ---------------------------------------------------------------------------------------------------------------------------- |
Expand All @@ -43,3 +43,19 @@ be rejected.
| [@lcjb360](https://github.com/lcjb360) | [Bad Chess](web/priv/js_effects/bad_chess.js) | Google en passant |
| [@james1236](https://github.com/james1236) | [Word Game](web/priv/js_effects/word_game.js) | Word game animation |
| [@DOmBuRnAdOwl](https://github.com/DOmBuRnAdOwl) | [Cellular Automata](web/priv/js_effects/cellularAutomata.js) | Wolframs rule 30 feeding into Conways Game of Life |

## Image Overrides

Open a pull request with an edit to [web/config/config.exs](https://github.com/lancaster-university/infolab-lights/blob/master/web/config/config.exs) to add an override for your needs, and place the image in `.png` format (or animated `.gif`) in `/web/priv/`.

Can't code? No problem, open an [issue](https://github.com/lancaster-university/infolab-lights/issues) and a maintainer will help you.

### Current Override Schedule:

| Override | Schedule |
| ----------------- | ----------- |
| Pride Month | June Yearly |
| Halloween | 31st October Yearly |
| LU LGBT+ Society | Monday Evening 17:00 - 20:00 |
| LU Hack Society | Friday Evening 17:00 - 19:00 |
| Baby Loss Awareness Week (dates varies yearly) | 09/10/23 - 15/10/23 |
9 changes: 8 additions & 1 deletion web/config/config.exs
Original file line number Diff line number Diff line change
Expand Up @@ -17,12 +17,19 @@ config :infolab_light_games, InfolabLightGamesWeb.Endpoint,

config :infolab_light_games, Screen, dims: {120, 80}

# See table in the repo README
config :infolab_light_games, Scheduler,
jobs: [
{"0 17 * * FRI",
{Utils.StaticLoader, :display_static, ["luhack.png", {Timex.Duration, :from_hours, [2]}]}},
{"0 17 * * MON",
{Utils.StaticLoader, :display_static, ["pide.png", {Timex.Duration, :from_hours, [3]}]}},
{"*/30 */1 * 6 *",
{Utils.StaticLoader, :display_static, ["pride.png", {Timex.Duration, :from_minutes, [10]}]}}
{Utils.StaticLoader, :display_static, ["pride.png", {Timex.Duration, :from_minutes, [10]}]}},
{"0 */1 9-15 10 *",
{Utils.StaticLoader, :display_static, ["infolab-babyloss.gif", {Timex.Duration, :from_hours, [1]}]}},
{"0 */1 31 10 *",
{Utils.StaticLoader, :display_static, ["halloween_pumpkin.gif", {Timex.Duration, :from_hours, [1]}]}}
]

# Configures Elixir's Logger
Expand Down
Binary file added web/priv/static_images/halloween_pumpkin.gif
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added web/priv/static_images/infolab-babyloss.gif
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.

0 comments on commit 072f103

Please sign in to comment.