Skip to content

Commit

Permalink
Hugo yaml
Browse files Browse the repository at this point in the history
  • Loading branch information
subdavis committed Sep 10, 2024
1 parent de599a2 commit e6df380
Show file tree
Hide file tree
Showing 6 changed files with 65 additions and 85 deletions.
2 changes: 1 addition & 1 deletion archive/meeting_cache.json

Large diffs are not rendered by default.

Empty file added blog/content/posts/_index.md
Empty file.
75 changes: 0 additions & 75 deletions blog/hugo.toml

This file was deleted.

55 changes: 55 additions & 0 deletions blog/hugo.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,55 @@
baseURL: 'https://city-journal-mpls.subdavis.com'
languageCode: en-us
title: Minneapolis Open City Journal
theme: typo
params:
description: An AI Generated Journal of City Council meetings
theme: light
colorPalette: default
hideHeader: false
readTime: true
homeIntroContent: >
This is an AI generated newsletter-style summary of what's going on at City
Hall.
Council meetings are sometimes important and often **very boring**. AI is a
splendid tool for separating
all that procedural jargon and finding the parts that residents might care
to know about.
homeCollectionTitle: Posts
homeCollection: posts
paginationSize: 100
listSummaries: false
listDateFormat: 2 Jan 2006
breadcrumbs: true
social:
- name: github
url: 'https://github.com/subdavis/mpls-ai'
- name: rss
url: /index.xml
menu:
- name: home
url: /
- name: posts
url: /posts
- name: about
url: /about
giscus:
enable: false
repo: user/repo
repoid: repoId
category: General
categoryid: categoryId
mapping: pathname
theme: preferred_color_scheme
umami:
enable: true
websiteId: 422aade2-6acc-474e-bb7f-d4c631b83a20
jsLocation: 'https://umami.subdavis.com/script.js'
markup:
highlight:
style: algol
services:
rss:
limit: 20
10 changes: 5 additions & 5 deletions blog/layouts/_default/rss.xml
Original file line number Diff line number Diff line change
Expand Up @@ -34,14 +34,14 @@
{{- if .IsHome }}{{ $pctx = .Site }}{{ end }}
{{- $pages := slice }}
{{- if or $.IsHome $.IsSection }}
{{- $pages = $pctx.RegularPages }}
{{- $pages = $pctx.RegularPages }}
{{- else }}
{{- $pages = $pctx.Pages }}
{{- $pages = $pctx.Pages }}
{{- end }}
{{- $limit := .Site.Config.Services.RSS.Limit }}
{{- if ge $limit 1 }}
{{- $pages = $pages | first $limit }}
{{- end }}

{{- $pages = (where $pages ".Section" "posts") | first $limit }}

{{- printf "<?xml version=\"1.0\" encoding=\"utf-8\" standalone=\"yes\"?>" | safeHTML }}
<rss version="2.0" xmlns:atom="http://www.w3.org/2005/Atom">
<channel>
Expand Down
8 changes: 4 additions & 4 deletions lims_utils/scripts.py
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@
from time import sleep

from lims_utils.claude import generate_summary
from lims_utils.meetings import update_meeting_cache
from lims_utils.meetings import update_meeting_cache, load_meeting_cache
from lims_utils.transcript import formatSummaryForHugo
load_dotenv()

Expand All @@ -13,13 +13,13 @@ def updateCache():


def generate():
cachedMeetings, newMeetings = update_meeting_cache("2024-01-01")
cacheList = load_meeting_cache()
# Get cached meetings sorted by date
cachedMeetings = sorted(
cachedMeetings, key=lambda x: date_parse(x["meetingTime"]), reverse=True
cacheList, key=lambda x: date_parse(x["meetingTime"]), reverse=True
)

for meeting in cachedMeetings[:8]:
for meeting in (cachedMeetings[:8]):
filename, text, isNewContent = generate_summary(meeting)
formatSummaryForHugo(meeting, text)
if isNewContent:
Expand Down

0 comments on commit e6df380

Please sign in to comment.