switch to ics files; make calendars work; fix some minor issues
This commit is contained in:
parent
5368e75240
commit
c28f04c6e8
19 changed files with 318 additions and 259 deletions
13
flake.nix
13
flake.nix
|
|
@ -2,7 +2,7 @@
|
|||
description = "A flake containing a development environment for the CCCB website.";
|
||||
|
||||
inputs = {
|
||||
nixpkgs.url = "github:nixos/nixpkgs/nixos-24.11";
|
||||
nixpkgs.url = "github:nixos/nixpkgs/nixos-26.05";
|
||||
};
|
||||
|
||||
outputs =
|
||||
|
|
@ -34,7 +34,7 @@
|
|||
|
||||
devShells = forAllSystems (import ./devShells.nix);
|
||||
|
||||
formatter = forAllSystems ({ pkgs, ... }: pkgs.nixfmt-rfc-style);
|
||||
formatter = forAllSystems ({ pkgs, ... }: pkgs.nixfmt-tree);
|
||||
|
||||
lib.mkWwwContent =
|
||||
{ domain, system }:
|
||||
|
|
@ -50,10 +50,6 @@
|
|||
nativeBuildInputs = [
|
||||
pkgs.hugo
|
||||
pkgs.glibcLocales
|
||||
(pkgs.python3.withPackages (python-pkgs: [
|
||||
python-pkgs.icalendar
|
||||
python-pkgs.pytz
|
||||
]))
|
||||
];
|
||||
|
||||
# LOCALE_ARCHIVE = builtins.trace pkgs.glibcLocales "${pkgs.glibcLocales}/lib/locale/locale-archive";
|
||||
|
|
@ -62,11 +58,6 @@
|
|||
buildPhase = ''
|
||||
mkdir -p public
|
||||
hugo --baseURL=https://${domain}/
|
||||
|
||||
python3 ./tools/merge_cals.py
|
||||
upcoming="$(python3 tools/gen_upcoming.py static/all.ics 20 5 | tr '\n' ' ')"
|
||||
cp static/all.ics public/all.ics
|
||||
sed -i "s#CALENDAR#$upcoming#g" public/index.html
|
||||
'';
|
||||
|
||||
# Install phase - copy the public directory to the output
|
||||
|
|
|
|||
Loading…
Reference in a new issue