Hackney Cinema Calendar #219
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
on: | |
workflow_dispatch: | |
inputs: | |
tagSuffix: | |
description: 'Tag Suffix' | |
required: true | |
default: '1' | |
type: choice | |
options: | |
- '1' | |
- '2' | |
- '3' | |
- '4' | |
- '5' | |
schedule: | |
- cron: '0 3 * * *' # every morning at 3am UTC | |
name: Hackney Cinema Calendar | |
jobs: | |
generate_calendar: | |
name: Generate Calendar | |
runs-on: self-hosted | |
permissions: | |
contents: write | |
env: | |
MOVIEDB_API_KEY: ${{ secrets.MOVIEDB_API_KEY }} | |
steps: | |
# Setup | |
- uses: actions/checkout@v3 | |
- uses: actions/setup-node@v3 | |
with: | |
node-version-file: .node-version | |
- run: npm ci | |
- run: npx playwright install --with-deps | |
- name: Get current date and time | |
id: date | |
run: | | |
echo "currentDate=$(TZ=Europe/London date +'%Y-%m-%d')" >> "$GITHUB_OUTPUT" | |
echo "currentTime=$(TZ=Europe/London date +'%H:%M:%S')" >> "$GITHUB_OUTPUT" | |
# Retrieve & cache data from other event sources, which can be used in the | |
# runs below, e.g. events on Eventbrite which are not on the venue site. | |
- run: npm run retrieve:sources | |
# BFI (2) | |
# Needs a full browser to not get caught in connection checks. The pages | |
# are slow to load and can often time out. With heavy caching of responses | |
# between runs, we can leverage this with a high number of retries. | |
- name: npm run generate bfi.org.uk-imax | |
uses: nick-fields/retry@v3 | |
with: | |
timeout_minutes: 30 | |
retry_wait_seconds: 30 | |
max_attempts: 10 | |
command: npm run generate bfi.org.uk-imax | |
- name: npm run generate bfi.org.uk-southbank | |
uses: nick-fields/retry@v3 | |
with: | |
timeout_minutes: 90 | |
retry_wait_seconds: 30 | |
max_attempts: 20 | |
command: npm run generate bfi.org.uk-southbank | |
# Cineworld (12) | |
- run: npm run generate cineworld.co.uk-bexleyheath | |
- run: npm run generate cineworld.co.uk-enfield | |
- run: npm run generate cineworld.co.uk-feltham | |
- run: npm run generate cineworld.co.uk-hounslow | |
- run: npm run generate cineworld.co.uk-ilford | |
- run: npm run generate cineworld.co.uk-leicester-square | |
- run: npm run generate cineworld.co.uk-south-ruislip | |
- run: npm run generate cineworld.co.uk-the-o2-greenwich | |
- run: npm run generate cineworld.co.uk-wandsworth | |
- run: npm run generate cineworld.co.uk-wembley | |
- run: npm run generate cineworld.co.uk-west-india-quay | |
- run: npm run generate cineworld.co.uk-wood-green | |
# Curzon (9) | |
- run: npm run generate curzon.com-aldgate | |
- run: npm run generate curzon.com-bloomsbury | |
- run: npm run generate curzon.com-camden | |
- run: npm run generate curzon.com-hoxton | |
- run: npm run generate curzon.com-kingston | |
- run: npm run generate curzon.com-mayfair | |
- run: npm run generate curzon.com-soho | |
- run: npm run generate curzon.com-victoria | |
- run: npm run generate curzon.com-wimbledon | |
# Electric Cinema (2) | |
- run: npm run generate electriccinema.co.uk-portobello | |
- run: npm run generate electriccinema.co.uk-white-city | |
# Everyman (14) | |
- run: npm run generate everymancinema.com-baker-street | |
- run: npm run generate everymancinema.com-barnet | |
- run: npm run generate everymancinema.com-belsize-park | |
- run: npm run generate everymancinema.com-borough-yards | |
- run: npm run generate everymancinema.com-broadgate | |
- run: npm run generate everymancinema.com-canary-wharf | |
- run: npm run generate everymancinema.com-chelsea | |
- run: npm run generate everymancinema.com-crystal-palace | |
- run: npm run generate everymancinema.com-hampstead | |
- run: npm run generate everymancinema.com-kings-cross | |
- run: npm run generate everymancinema.com-maida-vale | |
- run: npm run generate everymancinema.com-muswell-hill | |
- run: npm run generate everymancinema.com-screen-on-the-green | |
- run: npm run generate everymancinema.com-stratford-international | |
# Vue (9) | |
- run: npm run generate myvue.com-finchley-road | |
- run: npm run generate myvue.com-fulham-broadway | |
- run: npm run generate myvue.com-islington | |
- run: npm run generate myvue.com-leicester-square | |
- run: npm run generate myvue.com-north-finchley | |
- run: npm run generate myvue.com-piccadilly | |
- run: npm run generate myvue.com-shepherds-bush | |
- run: npm run generate myvue.com-westfield | |
- run: npm run generate myvue.com-westfield-stratford-city | |
# ODEON (19) | |
- run: npm run generate odeon.co.uk-acton | |
- run: npm run generate odeon.co.uk-beckenham | |
- run: npm run generate odeon.co.uk-camden | |
- run: npm run generate odeon.co.uk-greenwich | |
- run: npm run generate odeon.co.uk-haymarket | |
- run: npm run generate odeon.co.uk-holloway | |
- run: npm run generate odeon.co.uk-islington | |
- run: npm run generate odeon.co.uk-kingston | |
- run: npm run generate odeon.co.uk-lee-valley | |
- run: npm run generate odeon.co.uk-leicester-square | |
- run: npm run generate odeon.co.uk-putney | |
- run: npm run generate odeon.co.uk-richmond | |
- run: npm run generate odeon.co.uk-south-woodford | |
- run: npm run generate odeon.co.uk-streatham | |
- run: npm run generate odeon.co.uk-swiss-cottage | |
- run: npm run generate odeon.co.uk-tottenham-court-road | |
- run: npm run generate odeon.co.uk-uxbridge | |
- run: npm run generate odeon.co.uk-west-end | |
- run: npm run generate odeon.co.uk-wimbledon | |
# Picturehouses (11) | |
- run: npm run generate picturehouses.com-central | |
- run: npm run generate picturehouses.com-clapham | |
- run: npm run generate picturehouses.com-crouch-end | |
- run: npm run generate picturehouses.com-ealing | |
- run: npm run generate picturehouses.com-east-dulwich | |
- run: npm run generate picturehouses.com-greenwich | |
- run: npm run generate picturehouses.com-finsbury-park | |
- run: npm run generate picturehouses.com-hackney | |
- run: npm run generate picturehouses.com-the-gate | |
- run: npm run generate picturehouses.com-the-ritzy | |
- run: npm run generate picturehouses.com-west-norwood | |
# Indy Cinema Group (3) | |
- run: npm run generate riocinema.org.uk | |
- run: npm run generate regentstreetcinema.com | |
- run: npm run generate phoenixcinema.co.uk | |
# Remaining cinemas (3) | |
- run: npm run generate princecharlescinema.com | |
- run: npm run generate genesiscinema.co.uk | |
- run: npm run generate thecastlecinema.com | |
- name: Save any test failure artifacts | |
if: failure() | |
uses: actions/upload-artifact@v4 | |
with: | |
name: playwright-failures | |
path: ./playwright-failures | |
if-no-files-found: ignore | |
retention-days: 7 | |
# Run post-data scripts | |
- run: npm run output:highlight-hydration-misses-for-review | |
# Create release with assets | |
- uses: ncipollo/release-action@v1 | |
id: release | |
with: | |
allowUpdates: false | |
artifactErrorsFailBuild: true | |
artifacts: "output/*.ics,output/*.json,schema.json" | |
makeLatest: true | |
tag: ${{ steps.date.outputs.currentDate }}.${{ inputs.tagSuffix || '0' }} | |
commit: main | |
body: | | |
Calendar and data files generated at ${{ steps.date.outputs.currentTime }} on ${{ steps.date.outputs.currentDate }} | |
Created by job ${{ github.server_url }}/${{ github.repository }}/actions/runs/${{ github.run_id }} | |
- name: Output summary | |
run: | | |
echo "📆 Calendar generated at ${{ steps.date.outputs.currentTime }} on ${{ steps.date.outputs.currentDate }}" >> $GITHUB_STEP_SUMMARY | |
echo "🔖 New release - ${{ steps.release.outputs.html_url }}" >> $GITHUB_STEP_SUMMARY |